java.lang.NoClassDefFoundError: javax/crypto/SunJCE_b

java.lang.NoClassDefFoundError: javax/crypto/SunJCE_b
at javax.crypto.KeyGenerator.a(DashoA13*..)
at javax.crypto.KeyGenerator.<init>(DashoA13*..)
at javax.crypto.KeyGenerator.getInstance(DashoA13*..)
at org.hexun.wangchong.admin.filters.Sercuri.getKey(Sercuri.java:86)
at org.hexun.wangchong.admin.filters.Sercuri.<init>(Sercuri.java:22)
at org.hexun.wangchong.admin.filters.Sercuri.getSercuriInstancesObjectTime(Sercuri.java:35)

此类异常和jdk的版有点关系.解决办法:

1.换个高版本的JDK.(未试过)

2.将tomcat的虚拟机(指向jre目录)指向JDK目录. 如:tomcat原来的虚拟机是指向:C:\Program Files\Java\jre1.6.0_02\bin\client\jvm.dll 则指向C:\Program Files\Java\jdk1.6.0_02\jre\bin\client\jvm.dll

(本人已测试通过)

3.将\jdk1.6.0_02\jre\lib(注意目录是指向jdk的目录)目录下的jce.jar和jsse.jar拷呗到tomcat的lib目录下即可.(本人已测试通过)

你可能感兴趣的:(java,jvm,jdk,tomcat,虚拟机)