tags:

views:

133

answers:

3

Hello, I am using IcePDF component to view pdf in JApplet on my web page. But for some reason i get this error. Can anybody tell why is this happening and how to solve it?

Exception in thread "thread applet-applet.KitKitApplet.class-1" java.lang.StackOverflowError
    at java.util.PropertyPermissionCollection.implies(Unknown Source)
    at java.security.Permissions.implies(Unknown Source)
    at sun.security.provider.PolicyFile.implies(Unknown Source)
    at java.security.ProtectionDomain.implies(Unknown Source)
    at java.security.AccessControlContext.checkPermission(Unknown Source)
    at java.security.AccessController.checkPermission(Unknown Source)
    at java.lang.SecurityManager.checkPermission(Unknown Source)
    at java.lang.SecurityManager.checkPropertyAccess(Unknown Source)
    at java.lang.System.getProperty(Unknown Source)
    at org.icepdf.core.util.Defs.property(Defs.java:59)
    at org.icepdf.core.util.Defs.property(Defs.java:63)
    at org.icepdf.core.util.Defs.property(Defs.java:63)
    at org.icepdf.core.util.Defs.property(Defs.java:63)
    at org.icepdf.core.util.Defs.property(Defs.java:63)
    at org.icepdf.core.util.Defs.property(Defs.java:63)
    at org.icepdf.core.util.Defs.property(Defs.java:63)
+7  A: 

Looks like you've run into this bug. The program is trying to read a system property that the applet sandbox won't allow it to read, and the ensuing SecurityException is not handled correctly by IcePDF.

Michael Borgwardt
Hi Michael,But i have downloaded the latest version 4.0.1. Should i just quit using this component? or is there some alternative available?
Ankit Rathod
@Nitesh: Unfirtunately, the bug has not been fixed yet. See if the bug report leads you to information about how to work around this problem in your particular case; you could also use a debugger to find out which system property the program is trying to access and how to avoid this.
Michael Borgwardt
A: 

you have something compiled without debug symbols that is why you see Unknown Source everywhere. The main thing is pretty self evident, your SecurityManager isn't setup with the correct permissions to do java.lang.System.getProperty(). You need to configure the applet security permissions to let that library access whatever property it is trying to get. You will probably have to Sign your Applet for your code to work.

fuzzy lollipop
+1  A: 

This exception is caused when the current thread has exhausted it's stack space. This can happen when a function has recursed too many times, typically as a result if a non-terminating recurson.

mdma