Solved

Servlet XML Output Problem

Posted on 2001-08-06
4
248 Views
Last Modified: 2013-11-24
I am working on a class that will allow me to write XML documents to standard text output. I have a class with a method PostDoc() that performs the following...

try {
 TransformerFactory tFactory = TransformerFactory.newInstance();
 Transformer t = tFactory.newTransformer();
 t.transform(new DOMSource(document),new StreamResult(new File(strFileName)));
   } catch(Exception e) {...}

When I run this from a test command line application the classes perform properly but when I try and load this via a servlet on Tomcat I get the error
 "java.lang.SecurityException: sealing violation"

I am at a loss. Is this a java problem or a tomcat configuration problem? Any idea on how I correct the problem?

TIA
John
0
Comment
Question by:jkb2
4 Comments
 

Accepted Solution

by:
jasonbrome earned 100 total points
ID: 6357538
Tomcat contains a portion of the classes found in  Xalan.jar.  

To resolve this issue, all you need to do is ensure that the JAXP jars (xalan.jar, jaxp.jar and crimson.jar) are defined first, before the Tomcat jars, in the classpath.
0
 
LVL 1

Author Comment

by:jkb2
ID: 6359348
Beautiful. I was beating my head against the wall on this one. Thanks
0
 
LVL 5

Expert Comment

by:lwinkenb
ID: 8937307
No comment has been added lately, so it's time to clean up this TA.
I will leave a recommendation in the Cleanup topic area that this question is:
Accept comment by jasonbrome as answer.
Please leave any comments here within the next seven days.
 
PLEASE DO NOT ACCEPT THIS COMMENT AS AN ANSWER!
 
lwinkenb
EE Cleanup Volunteer
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

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

Suggested Solutions

Title # Comments Views Activity
Setting strict transport security header in header not working 1 78
for i loop in grovy 1 44
bitbucket vs gitbucket 3 57
Java SE 8u111  Lot of stuff broke 11 54
For beginner Java programmers or at least those new to the Eclipse IDE, the following tutorial will show some (four) ways in which you can import your Java projects to your Eclipse workbench. Introduction While learning Java can be done with…
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…
Viewers learn how to read error messages and identify possible mistakes that could cause hours of frustration. Coding is as much about debugging your code as it is about writing it. Define Error Message: Line Numbers: Type of Error: Break Down…
This theoretical tutorial explains exceptions, reasons for exceptions, different categories of exception and exception hierarchy.

911 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

16 Experts available now in Live!

Get 1:1 Help Now