I read that IBM's cryptography modules are incompatible with Sun modules, but I don't know how to force IBM WebSphere (WAS7) to use Sun modules.
java.lang.ClassCastException: com.ibm.crypto.provider.TDCNP incompatible with javax.crypto.CipherSpi
at javax.crypto.Cipher.getInstance(Unknown Source)
at javax.crypto.Cipher.getInstance(Unknown Source)
I have a JAR file called iaik_jce_full.jar
which should supposedly work (it works elsewhere but not in WAS).
I tried to work around this by adding the Sun libraries to my project, but it seems WebSphere loads its own java classes before the application's, even if the class loader
PARENT_LAST
setting is used.
This is from the first link. I have tried the same and I am using the "parent last" setting already.
The Websphere installation comes with a ibmjceprovider.jar
file which contains the offending class TDCNP
.
How do I fix this problem?