Want to win a PS4? Go Premium and enter to win our High-Tech Treats giveaway. Enter to Win

x
?
Solved

Xerces XML parser in applet.

Posted on 2001-07-03
4
Medium Priority
?
454 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_
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 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 200 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

VIDEO: THE CONCERTO CLOUD FOR HEALTHCARE

Modern healthcare requires a modern cloud. View this brief video to understand how the Concerto Cloud for Healthcare can help your organization.

Question has a verified solution.

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

An old method to applying the Singleton pattern in your Java code is to check if a static instance, defined in the same class that needs to be instantiated once and only once, is null and then create a new instance; otherwise, the pre-existing insta…
In this post we will learn different types of Android Layout and some basics of an Android App.
Viewers will learn about basic arrays, how to declare them, and how to use them. Introduction and definition: Declare an array and cover the syntax of declaring them: Initialize every index in the created array: Example/Features of a basic arr…
Viewers will learn how to properly install Eclipse with the necessary JDK, and will take a look at an introductory Java program. Download Eclipse installation zip file: Extract files from zip file: Download and install JDK 8: Open Eclipse and …
Suggested Courses

636 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