更新 Java 导致小程序停止工作 - 未找到 testJava2_1/TestVMApplet.class

声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow 原文地址: http://stackoverflow.com/questions/10803577/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me): StackOverFlow

提示:将鼠标放在中文语句上可以显示对应的英文。显示中英文
时间:2020-10-31 02:39:09  来源:igfitidea点击:

Updating Java causes applets to stop working - testJava2_1/TestVMApplet.class not found

javaapplet

提问by Richard

Hei,

嘿,

After I updated my java version from 6u31 to 7u4 on a windows 7-64 bits, applets stopped working. I use java-32 bits and the browsers are also 32 bits(tried IE9 and Firefox 12.0) , and the only cause was updating the java. I used the test from http://www.java.com/en/download/testjava.jsp, and got this as result:

在 Windows 7-64 位上将 Java 版本从 6u31 更新为 7u4 后,小程序停止工作。我使用 java-32 位,浏览器也是 32 位(尝试过 IE9 和 Firefox 12.0),唯一的原因是更新 java.lang. 我使用了来自http://www.java.com/en/download/testjava.jsp的测试,结果如下:

 security: property package.access value sun.,com.sun.xml.internal.ws.,com.sun.xml.internal.bind.,com.sun.imageio.,com.sun.org.apache.xerces.internal.utils.,com.sun.org.apache.xalan.internal.utils.
 security: property package.access new value sun.,com.sun.xml.internal.ws.,com.sun.xml.internal.bind.,com.sun.imageio.,com.sun.org.apache.xerces.internal.utils.,com.sun.org.apache.xalan.internal.utils.,com.sun.javaws
 security: property package.access value sun.,com.sun.xml.internal.ws.,com.sun.xml.internal.bind.,com.sun.imageio.,com.sun.org.apache.xerces.internal.utils.,com.sun.org.apache.xalan.internal.utils.,com.sun.javaws
 security: property package.access new value sun.,com.sun.xml.internal.ws.,com.sun.xml.internal.bind.,com.sun.imageio.,com.sun.org.apache.xerces.internal.utils.,com.sun.org.apache.xalan.internal.utils.,com.sun.javaws,com.sun.deploy
 security: property package.access value sun.,com.sun.xml.internal.ws.,com.sun.xml.internal.bind.,com.sun.imageio.,com.sun.org.apache.xerces.internal.utils.,com.sun.org.apache.xalan.internal.utils.,com.sun.javaws,com.sun.deploy
 security: property package.access new value sun.,com.sun.xml.internal.ws.,com.sun.xml.internal.bind.,com.sun.imageio.,com.sun.org.apache.xerces.internal.utils.,com.sun.org.apache.xalan.internal.utils.,com.sun.javaws,com.sun.deploy,com.sun.jnlp
 security: property package.definition value null
 security: property package.definition new value com.sun.javaws
 security: property package.definition value com.sun.javaws
 security: property package.definition new value com.sun.javaws,com.sun.deploy
 security: property package.definition value com.sun.javaws,com.sun.deploy
 security: property package.definition new value com.sun.javaws,com.sun.deploy,com.sun.jnlp
 security: property package.access value sun.,com.sun.xml.internal.ws.,com.sun.xml.internal.bind.,com.sun.imageio.,com.sun.org.apache.xerces.internal.utils.,com.sun.org.apache.xalan.internal.utils.,com.sun.javaws,com.sun.deploy,com.sun.jnlp
 security: property package.access new value sun.,com.sun.xml.internal.ws.,com.sun.xml.internal.bind.,com.sun.imageio.,com.sun.org.apache.xerces.internal.utils.,com.sun.org.apache.xalan.internal.utils.,com.sun.javaws,com.sun.deploy,com.sun.jnlp,org.mozilla.jss
 security: property package.definition value com.sun.javaws,com.sun.deploy,com.sun.jnlp
 security: property package.definition new value com.sun.javaws,com.sun.deploy,com.sun.jnlp,org.mozilla.jss
 basic: Added progress listener: sun.plugin.util.ProgressMonitorAdapter@1cc55fb
 basic: Plugin2ClassLoader.addURL parent called for http://www.java.com/applet/TestVM2-test.jar
 network: Cache entry not found [url: http://www.java.com/applet/TestVM2-test.jar, version: null]
 network: Connecting http://www.java.com/applet/TestVM2-test.jar with proxy=DIRECT
 network: Connecting http://www.java.com:80/ with proxy=DIRECT
 network: Cache entry not found [url: http://www.java.com/applet/TestVM2-test.jar, version: null]
 network: Cache entry not found [url: http://www.java.com/applet/TestVM2-test.jar, version: null]
 network: Connecting http://www.java.com/applet/TestVM2-test.jar with proxy=DIRECT
 network: Connecting http://www.java.com:80/ with proxy=DIRECT
 network: Connecting http://www.java.com/applet/TestVM2-test.jar with proxy=DIRECT
 network: Connecting http://www.java.com:80/ with proxy=DIRECT
 java.net.SocketException: Permission denied: connect

 bla bla bla

network: Cache entry not found [url: http://www.java.com/applet/TestVM2-test.jar, version: null]
network: Connecting http://www.java.com/applet/TestVM2-test.jar with proxy=DIRECT
network: Connecting http://www.java.com:80/ with proxy=DIRECT
network: Cache entry not found [url: http://www.java.com/applet/TestVM2-test.jar, version: null]
network: Cache entry not found [url: http://www.java.com/applet/TestVM2-test.jar, version: null]
network: Connecting http://www.java.com/applet/TestVM2-test.jar with proxy=DIRECT
network: Connecting http://www.java.com:80/ with proxy=DIRECT
network: Connecting http://www.java.com/applet/TestVM2-test.jar with proxy=DIRECT
network: Connecting http://www.java.com:80/ with proxy=DIRECT
java.net.SocketException: Permission denied: connect

bla bla bla

network: Cache entry not found [url: http://www.java.com/applet/, version: null]
network: Cache entry not found [url: http://www.java.com/applet/testJava2_1/TestVMApplet.class, version: null]
network: Connecting http://www.java.com/applet/testJava2_1/TestVMApplet.class with proxy=DIRECT
network: Connecting http://www.java.com:80/ with proxy=DIRECT
network: Cache entry not found [url: http://www.java.com/applet/testJava2_1/TestVMApplet/class.class, version: null]
network: Connecting http://www.java.com/applet/testJava2_1/TestVMApplet/class.class with proxy=DIRECT
network: Connecting http://www.java.com:80/ with proxy=DIRECT
java.lang.ClassNotFoundException: testJava2_1.TestVMApplet.class

bla bla bla

basic: load: class testJava2_1/TestVMApplet.class not found.
java.lang.ClassNotFoundException: testJava2_1.TestVMApplet.class

bla bla bla

Ignored exception: java.lang.ClassNotFoundException: testJava2_1.TestVMApplet.class
basic: Dialog type is not candidate for embedding
basic: Removed progress listener: sun.plugin.util.ProgressMonitorAdapter@1cc55fb
basic: Loading Java Applet Failed...
security: Reset deny session certificate store

I already tried a lot of different alternatives like disabling the firewall, disabling the next generation plug-in on Java Control Panel, clearing the cache, uninstalling and re-installing (both JRE and JDK), playing with mixed mode security verification, and maybe some more I don't remember. I have no idea what else I could try to make it work.. Anyone experienced the same and solved it?

我已经尝试了很多不同的替代方法,例如禁用防火墙、禁用 Java 控制面板上的下一代插件、清除缓存、卸载和重新安装(JRE 和 JDK)、使用混合模式安全验证,也许还有一些我不记得了。我不知道还有什么我可以尝试让它工作的..有没有人经历过同样的事情并解决了它?

Ah, as company policy we have to stick with the latest version if possible due to security updates.

啊,作为公司政策,由于安全更新,我们必须尽可能坚持使用最新版本。

采纳答案by Richard

Ok, the problem was that I was connected on VPN (CISCO) while accessing pages with java. Since Java 7, there is a problem due to Ipv6 (http://jonathangiles.net/blog/?p=1126). So I disabled it from the VPN connection and added this line to the java runtime parameters: -Djava.net.preferIPv4Stack=true

好的,问题是我在使用java访问页面时连接了VPN(CISCO)。从 Java 7 开始,由于 Ipv6 (http://jonathangiles.net/blog/?p=1126) 存在问题。所以我从 VPN 连接中禁用了它,并将这一行添加到 java 运行时参数中:-Djava.net.preferIPv4Stack=true

Now it's working fine.

现在它工作正常。