Solved

Xerces XML parser in applet.

Posted on 2001-07-03
4
434 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
ID: 6248870
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_
ID: 6249131
"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
ID: 6249243
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_
ID: 6258565
Ok, thanks. It's working!
0

Featured Post

Live: Real-Time Solutions, Start Here

Receive instant 1:1 support from technology experts, using our real-time conversation and whiteboard interface. Your first 5 minutes are always free.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Java Flight Recorder and Java Mission Control together create a complete tool chain to continuously collect low level and detailed runtime information enabling after-the-fact incident analysis. Java Flight Recorder is a profiling and event collectio…
Introduction This article is the first of three articles that explain why and how the Experts Exchange QA Team does test automation for our web site. This article explains our test automation goals. Then rationale is given for the tools we use to a…
Viewers learn about the “for” loop and how it works in Java. By comparing it to the while loop learned before, viewers can make the transition easily. You will learn about the formatting of the for loop as we write a program that prints even numbers…
Viewers will learn about arithmetic and Boolean expressions in Java and the logical operators used to create Boolean expressions. We will cover the symbols used for arithmetic expressions and define each logical operator and how to use them in Boole…

776 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