Forum Discussion

jacinto's avatar
jacinto
Occasional Contributor
12 years ago

Using x509 signing and encryption request message

Hi,

I'm trying to make a request to a service using x509 authentication and mesage protection, but all the info I've found is old or isn't working with my configurations, this what I have:

- X509 Authentication and protection
- Self Private Key to sing
- Destination Public Key to encrypt
- Send encrypted key in the message of the recipient

The service is an OSB configured in weblogic, and I've set this config:

http://blog.thilinamb.com/2011/02/invok ... -with.html

but I get an error in the service saying that the EncryptedKey isn't p+resent (I assume its the recipient key in the message): 'WSM-00092 : The <EncryptedKey> element is missing in the request.'

The only question is that I'm new to this and I don't know How to configure it to mactch the exact way:

This is my client in JDev:

        
new SecurityPoliciesFeature(new String[]{ "oracle/wss11_x509_token_with_message_protection_client_policy" });
reqContext.put(ClientConstants.WSSEC_KEYSTORE_TYPE, "JKS");
reqContext.put(ClientConstants.WSSEC_KEYSTORE_LOCATION, "C:/Keystores/ClientStore.jks");

reqContext.put(ClientConstants.WSSEC_ENC_KEY_ALIAS, "serverkey");
reqContext.put(ClientConstants.WSSEC_RECIPIENT_KEY_ALIAS, "serverkey");
reqContext.put(ClientConstants.WSSEC_SIG_KEY_ALIAS, "clientkey");


and this is what I want to recreate,

Thanks for any help on this
No RepliesBe the first to reply