Solved

Xerces XML parser in applet.

Posted on 2001-07-03
4
429 Views
Last Modified: 2013-11-23
Hello!

I have found a problem with using Apache Xerces XML pasrer in applet.

I'm creating a control that uses xerces parser and can work as application or applet. When it works as application all is Ok. But when I try to start it as an applet then java.security.AccessControlException is thrown with the following description

java.security.AccessControlException: access denied ( java.util.PropertyPermission jaxp.debug read)

This error is throw during execution if instruction

javax.xml.parsers.DocumentBuilderFactory.newInstance().

What to do?
0
Comment
Question by:Kit_
  • 2
  • 2
4 Comments
 
LVL 15

Expert Comment

by:ozymandias
Comment Utility
This is tricky.
The DocumentBuilderFactory returns an object whose type is obviously dependent upon some system property. It may be OS dependent or language/locale dependent (I'm not sure).

Applets (as a rule) do not have priviledges to look at these system properties as they are "sandboxed" for security reasons.

I am not sure how to get round it but I am sure I have in the past.

Can you post your code please ?
0
 

Author Comment

by:Kit_
Comment Utility
"jaxp.debug" - may be it is a debug option? As far as I understand I use xerces build with debug info.
0
 
LVL 15

Accepted Solution

by:
ozymandias earned 100 total points
Comment Utility
This is a bug that has been reported in the forums at Sun's java website.

A discussion of the problem and a solution to it are posted here :

http://forums.java.sun.com/thread.jsp?forum=34&thread=68599

0
 

Author Comment

by:Kit_
Comment Utility
Ok, thanks. It's working!
0

Featured Post

Why You Should Analyze Threat Actor TTPs

After years of analyzing threat actor behavior, it’s become clear that at any given time there are specific tactics, techniques, and procedures (TTPs) that are particularly prevalent. By analyzing and understanding these TTPs, you can dramatically enhance your security program.

Join & Write a Comment

Suggested Solutions

Title # Comments Views Activity
noX challenge 17 75
XML Paring  Error - Premature end of file. 7 55
wordlen challenge 3 45
backtracking recursion  code 19 39
This was posted to the Netbeans forum a Feb, 2010 and I also sent it to Verisign. Who didn't help much in my struggles to get my application signed. ------------------------- Start The idea here is to target your cell phones with the correct…
Java functions are among the best things for programmers to work with as Java sites can be very easy to read and prepare. Java especially simplifies many processes in the coding industry as it helps integrate many forms of technology and different d…
Viewers learn about the “while” loop and how to utilize it correctly in Java. Additionally, viewers begin exploring how to include conditional statements within a while loop and avoid an endless loop. Define While Loop: Basic Example: Explanatio…
Viewers will learn about the different types of variables in Java and how to declare them. Decide the type of variable desired: Put the keyword corresponding to the type of variable in front of the variable name: Use the equal sign to assign a v…

728 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

12 Experts available now in Live!

Get 1:1 Help Now