access denied (java.io.FilePermission

Hi everybody

I have a jsp that using outputstream write a jpeg on the server.I have tried this on my local server and everything was ok.but on the server I have the access denied (java.io.FilePermission /var/chroot/home/..../front.jpg write)

error.I have set the permission of the folder to 777 but still tyhe same error.

Can anyone help me

Thanks

[379 byte] By [Zareha] at [2007-11-27 5:17:02]
# 1
Does the user executing the program own the file? Try chowning the file over to your current user account.Joe
Joe_ha at 2007-7-12 10:39:56 > top of Java-index,Java Essentials,New To Java...
# 2
How can I test it under user's permissions?Its on godaddyI think maybe I have to set java.policy fileam I wrong
Zareha at 2007-7-12 10:39:56 > top of Java-index,Java Essentials,New To Java...
# 3

Add write permission to your web app server policy.

For example, in Tomcat, do to TOMCAT_INSTALL_DIR/conf/catalina.policy, then add something like that:

permission java.io.FilePermission "/var/chroot/home/..../-", "write";

See this http://mail-archives.apache.org/mod_mbox/tomcat-users/200408.mbox/%3CBOEJJFBJBNPOFOBEMFLFAENJCCAA.snalgonda@mypublisher.com%3E for more information.

hth

java_2006a at 2007-7-12 10:39:56 > top of Java-index,Java Essentials,New To Java...
# 4
where should I put the policy fileI dont have access to godaddy's tomcat folder :)in the root folder of my hosting there is no conf fileThans for the help
Zareha at 2007-7-12 10:39:56 > top of Java-index,Java Essentials,New To Java...