Martin Desruisseaux a écrit :

> Laurent Cuzon a écrit :
>
>> I try to use geotools in an applet and it causes the following exception:
>> So, my applet is signed and I answer yes to the question: "Do you want
to trust the signed applet...?"
>> I don't understand the problem, could you help me?
>>
>> java.security.AccessControlException: access denied
(java.util.PropertyPermission com.sun.media.imageio.disableCodecLib
read)
>>    at java.security.AccessControlContext.checkPermission(Unknown Source)
>>    [...snip...]
>
>
> According the stack trace, the error appears completly in the Java and
JAI code (no Geotools code seems involved here). I have an hypothesis,
but I'm not sure and would like to know if it work or not:
>
> I guess that a jai_imageio.jar file is bundled in yours geotools
download, and maybe this jai_imageio.jar file is included in the
classpath? This jar is usually put in the jre/lib/ext directory by a
Sun's installation program. We included it as part of the download in
the 2.1 branch (not in the 2.2 trunk) in order to avoid this
installation step on the user side. I guess that a JAR file in an Applet
classpath has less permission than a JAR file in the jre/lib/ext
directory, and that jai_imageio.jar was not designed for such restricted
environment (lets remind that the normal installation path is through
Sun's installation program).
>
> I suggest to remove jai_imageio.jar from the Applet classpath (as well
as all JAI jar) and install them through the normal installation program
instead, and try again. If it solve the problem, I would be very
interrested to know.
>
> An alternative is to investigage if you really need jai_imageio.jar. I
yours applet don't load any raster in format other than PNG, GIF and
JPEG, maybe you don't need it (it is worth a try).
>
> We plan to remove completly JAI dependency in the main module, and keep
JAI dependency only for the coverage module and its plugins:
>
>     http://jira.codehaus.org/browse/GEOT-746
>
>         Martin.

Hi,

For a question of time, we had to give up the problem of the applet. Now
we can display our image via an OutputStream in a jsf page.
Thanks for your answer.

Laurent Cuzon




-------------------------------------------------------
SF.Net email is sponsored by:
Tame your development challenges with Apache's Geronimo App Server. Download
it for free - -and be entered to win a 42" plasma tv or your very own
Sony(tm)PSP.  Click here to play: http://sourceforge.net/geronimo.php
_______________________________________________
Geotools-gt2-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/geotools-gt2-users

Reply via email to