Hi,

Try :

keytool -genkey -alias test -keystore test.keystore -keyalg RSA

You cna specify the key algo with the -keyalg option

- Ruchith

On 8/19/05, Shital Joshi <[EMAIL PROTECTED]> wrote:
> I am running my service using tomcat axis. My client and service are runing
> on the same machine. 
>  I used following command to generate the key.
>  
>  C:\axis-1_2_1\samples\userguide\example3>keytool -genkey
> -alias test -keystore test.keystore
>  
>  and my crypto.properties file looks like this:
>  
> org.apache.ws.security.crypto.provider=org.apache.ws.security.components.crypto.Merlin
>  org.apache.ws.security.crypto.merlin.keystore.type=jks
> org.apache.ws.security.crypto.merlin.keystore.password=security
>  org.apache.ws.security.crypto.merlin.keystore.alias=test
> org.apache.ws.security.crypto.merlin.alias.password=security
>  org.apache.ws.security.crypto.merlin.file=test.keystore
>  
>  I have the same test.keystore and crypto.properties in $TOMCAT_HOME/bin
> folder and $TOMCAT_HOME/webapss/axis/WEB-INF/classes
> folder. 
>  
>  My client_deploy.wsdd file looks like this:
>  
>  <deployment xmlns="http://xml.apache.org/axis/wsdd/";
> xmlns:java="http://xml.apache.org/axis/wsdd/providers/java";
> >
>   <transport name="http"
> pivot="java:org.apache.axis.transport.http.HTTPSender"/>
>    <globalConfiguration >
>     
>      <requestFlow>
>        <handler
> type="java:org.apache.ws.axis.security.WSDoAllSender" >
>         <parameter name="action" value="UsernameToken Encrypt"/>
>         <parameter name="user" value="wss4j"/>
>         <parameter name="passwordCallbackClass" value="com.PWCallback"/>
>         <parameter name="passwordType" value="PasswordText" />
>         <parameter name="addUTElement" value="Nonce Created" />
>         <parameter name="encryptionPropFile" value="crypto.properties" />
>         <parameter name="encryptionKeyIdentifier" value="X509KeyIdentifier"
> />
>         <parameter name="encryptionUser" value="test" />
>         <parameter name="encryptionParts" 
>          
> value="{Element}{http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd}UsernameToken";
> />  
>        </handler>
>    </requestFlow>  
>       
>    </globalConfiguration >
>  </deployment>
>  
>  
>  When I try to run my client like this:
>  
>  java -Daxis.ClientConfigFile=client_deploy.wsdd
> com.MyServiceClient IB
>  
>  It gives me following error:
>  
>  AxisFault
>   faultCode:
> {http://schemas.xmlsoap.org/soap/envelope/}Server.userException
>   faultSubcode:
>   faultString: java.lang.IllegalArgumentException: not an
> RSA key!
>   faultActor:
>   faultNode:
>   faultDetail:
>         
> {http://xml.apache.org/axis/}stackTrace:java.lang.IllegalArgumentExcepti
>  on: not an RSA key!
>  
>  I think I am quite close. Any help is appreciated.
>  
>  Thanks
>  
>  
>  
>  
>  
>  
> 
> -- 
> Progress isn't made by early risers. It's made by lazy men trying to find
> easier ways to do something.
>

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to