Hi all,

           I am using wss4j for signature and encryption for a web service.

Earlier I used tomcat, j2sdk1.4.2_03, java keytool utility to generate the keystore and certificate.

For this configuration security is working fine.

 

But my deployment environment is weblogic 9.0 express.

For this one weblogic uses jrockit90_150_03 ( jdk 1.5 compliant).

 

For this, I redo all the works under this environment.

I added the following entry

security.provider.3=org.bouncycastle.jce.provider.BouncyCastleProvider

in the java.security file in weblogic.

 

Axis also using axis/lib folder for all the required libraries. (it is not using any of the weblogic ones)

 

 

But I am getting following exception in the server side.

 

org.apache.ws.security.WSSecurityException: Cannot encrypt/decrypt data; nested

exception is:

        org.apache.xml.security.encryption.XMLEncryptionException: pad block cor

rupted

Original Exception was javax.crypto.BadPaddingException: pad block corrupted

        at org.apache.ws.security.processor.EncryptedKeyProcessor.decryptDataRef

(EncryptedKeyProcessor.java:388)

        at org.apache.ws.security.processor.EncryptedKeyProcessor.handleEncrypte

dKey(EncryptedKeyProcessor.java:313)

        at org.apache.ws.security.processor.EncryptedKeyProcessor.handleEncrypte

dKey(EncryptedKeyProcessor.java:81)

        at org.apache.ws.security.processor.EncryptedKeyProcessor.handleToken(En

cryptedKeyProcessor.java:75)

        at org.apache.ws.security.WSSecurityEngine.processSecurityHeader(WSSecur

ityEngine.java:252)

        at org.apache.ws.security.WSSecurityEngine.processSecurityHeader(WSSecur

ityEngine.java:179)

        at org.apache.ws.axis.security.WSDoAllReceiver.invoke(WSDoAllReceiver.ja

va:159)

        at com.affno.ws.handler.AffnoReceiver.invoke(AffnoReceiver.java:67)

       ……………………………………

 

Could anyone please help?

Is this because of jdk1.5 or weblogic 9.0?

How can I overcome this issue?

 

Thanks and best regards,

Elilvannan

 

 

 

Reply via email to