小程序加载认证 [英] Applet loading authentication
问题描述
我有一个网站,集成Windows身份验证在IIS 7.5上运行。在 /内容
文件夹(匿名访问)有一个小程序 - MyApplet.jar
。当使用该applet,爪哇显示需要验证弹出(和这个弹出不记得我的密码,即使我选中记住复选框)。
有没有办法消除这个窗口?
这是Java控制台小程序加载之前:
网络:高速缓存条目没有找到[网址: http://192.168.10.136/Web/Examination.mvc/Details/PatientEHR/META-INF/services/org.apache.xerces.xni.parser.XMLParserConfiguration,版本:空]
网络:连接http://192.168.10.136/Web/Examination.mvc/Details/PatientEHR/META-INF/services/org.apache.xerces.xni.parser.XMLParserConfiguration与代理= DIRECT
网络:连接http://192.168.10.136:80/与代理= DIRECT
网络:连接http://192.168.10.136/Web/Examination.mvc/Details/PatientEHR/META-INF/services/org.apache.xerces.xni.parser.XMLParserConfiguration与曲奇JCP店= HDImageStore; JCP键= Inf_WOPass
网络:防火墙认证:网站= / 192.168.10.136:80,协议= HTTP,提示=,=计划NTLM
我看起来像你的小程序做一些XML解析。
如果是这样,发生了什么是Java正在寻找一个XML解析器(带的getClass()。的getResource(...))和你的applet的路径,它会执行一个HTTP请求到服务器。
要prevent它可能要以
定义您的Applet的init方法XML解析器 的Class.forName(com.sun.org.apache.xerces.internal.jaxp.DocumentBuilderFactoryImpl);
System.setProperty(javax.xml.parsers.DocumentBuilderFactory中,com.sun.org.apache.xerces.internal.jaxp.DocumentBuilderFactoryImpl);
由于Java6u10你还必须从classpath中删除您的小程序的路径选择(而不是小程序)以
< APPLET ...>
< PARAM NAME =codebase_lookupVALUE =false的>
< / APPLET>
安东尼
I have a web site running on IIS 7.5 with integrated Windows authentication. In /Content
folder (with anonymous access) there is an applet - MyApplet.jar
. When using this applet, Java shows "Authentication required" popup (and this popup does not remember my password even if I check "remember" check-box).
Is there any way to remove this window?
This is Java console before loading applet:
network: Cache entry not found [url: http://192.168.10.136/Web/Examination.mvc/Details/PatientEHR/META-INF/services/org.apache.xerces.xni.parser.XMLParserConfiguration, version: null]
network: Connecting http://192.168.10.136/Web/Examination.mvc/Details/PatientEHR/META-INF/services/org.apache.xerces.xni.parser.XMLParserConfiguration with proxy=DIRECT
network: Connecting http://192.168.10.136:80/ with proxy=DIRECT
network: Connecting http://192.168.10.136/Web/Examination.mvc/Details/PatientEHR/META-INF/services/org.apache.xerces.xni.parser.XMLParserConfiguration with cookie "JCP-store=HDImageStore; JCP-key=Inf_WOPass"
network: Firewall authentication: site=/192.168.10.136:80, protocol=http, prompt=, scheme=ntlm
I looks like your Applet is doing some XML parsing. If so, what is happening is that Java is looking for a XML parser (with getClass().getResource(...)) and as the path of your applet, it will perform a HTTP request to your server.
To prevent it you may want to define the XML parser in the init method of your applet with
Class.forName("com.sun.org.apache.xerces.internal.jaxp.DocumentBuilderFactoryImpl");
System.setProperty("javax.xml.parsers.DocumentBuilderFactory", "com.sun.org.apache.xerces.internal.jaxp.DocumentBuilderFactoryImpl");
Since Java6u10 you also have the option to remove the path of your Applet from the classpath (but not the Applet) with
<APPLET ...>
<PARAM name="codebase_lookup" value="false">
</APPLET>
Anthony
这篇关于小程序加载认证的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!