dcsimg
Applet & JAXP security Exception
1 posts in topic
Flat View  Flat View
TOPIC ACTIONS:
 

Posted By:   Franco_Minutiello
Posted On:   Tuesday, July 17, 2001 03:29 AM

Hello everyone, I have a problem using JAXP in an Applet. The problem appears only with IE. Calling method DocumentBuilderFactory.newInstance() a com.ms.security.securityExceptionEx is thrown. The applet isn't signed. Here is the java console dump com.ms.security.SecurityExceptionEx[javax/xml/parsers/DocumentBuilderFactory .findFactory]: Unable to access system property: java.home at com/ms/security/permissions/PropertyPermission.check (PropertyPermission.java) at com/ms/security/PolicyEngine.shallowCheck (PolicyEngine.java) at com/ms/security/PolicyEngine.checkCallersPermission (PolicyEngine.java) at com/ms/security/StandardSecurityManager.chk    More>>

Hello everyone,


I have a problem using JAXP in an Applet. The problem appears only with IE. Calling method DocumentBuilderFactory.newInstance() a com.ms.security.securityExceptionEx is thrown. The applet isn't signed.

Here is the java console dump

			
com.ms.security.SecurityExceptionEx[javax/xml/parsers/DocumentBuilderFactory
.findFactory]: Unable to access system property: java.home
at com/ms/security/permissions/PropertyPermission.check
(PropertyPermission.java)
at com/ms/security/PolicyEngine.shallowCheck (PolicyEngine.java)
at com/ms/security/PolicyEngine.checkCallersPermission (PolicyEngine.java)
at com/ms/security/StandardSecurityManager.chk
(StandardSecurityManager.java)
at com/ms/security/StandardSecurityManager.checkPropertyAccess
(StandardSecurityManager.java)
at java/lang/System.getProperty (System.java)
at javax/xml/parsers/DocumentBuilderFactory.findFactory
(DocumentBuilderFactory.java:370)
at javax/xml/parsers/DocumentBuilderFactory.newInstance
(DocumentBuilderFactory.java:104)
at RevXMLParser. (RevXMLParser.java:41)
at RevMap.init (RevMap.java:56)
at com/ms/applet/AppletPanel.securedCall0 (AppletPanel.java)
at com/ms/applet/AppletPanel.securedCall (AppletPanel.java)
at com/ms/applet/AppletPanel.processSentEvent (AppletPanel.java)
at com/ms/applet/AppletPanel.processSentEvent (AppletPanel.java)
at com/ms/applet/AppletPanel.run (AppletPanel.java)
at java/lang/Thread.run (Thread.java)


Is it possible to avoid the call to System.getProperty()?

Any help will be appreciated    <<Less

Re: Applet & JAXP security Exception

Posted By:   Oscar_Gomez  
Posted On:   Friday, August 17, 2001 03:57 PM

I had the same problem, try using:


DocumentBuilderFactory factory = new com.sun.xml.parser.DocumentBuilderFactoryImpl();




or (for a SAX parser)




SAXParserFactory factory = new com.sun.xml.parser.SAXParserFactoryImpl();




instead of just calling the newInstance(); method
About | Sitemap | Contact