Hi list,
I am new to this list, so at first greetings to all!
Now my little problem:
I have a web-application developed with Struts to which I added logging
using commons-logging and log4j.
My application is deployed under Tomcat 5.x.
As my webhoster uses a security-manager I am looking for the correct
permissions to set for using logging.
Sure there has to be something allowed as I want to write to a file.
I managed to have it going with the following addition to my catalina.policy
file:
// These permissions apply to the log4j API used by CityExperience
applications
grant codeBase
"file:${catalina.home}/webapps/cxpEditSpike/WEB-INF/lib/log4j-1.2.9.jar" {
permission java.security.AllPermission;
};
// These permissions apply to the log4j API used by CityExperience
applications
grant codeBase
"file:${catalina.home}/webapps/cxpEditSpike/WEB-INF/lib/commons-logging.jar"
{
permission java.security.AllPermission;
};
But I think giving "AllPermission" is a bit too much.
When I try to change this to (for codebase log4j only in the beginning and
leaving commons-logging as it is)
to
permission java.io.FilePermission <<ALL FILES>>, "write"
(which is still too much IMHO)
I always get some error stating that the log file could not be found.
Reading the docs, googling and searching the archives I did not find an
answer to my problem.
Surely someone on this list will know!
Martin
---------------------------------------
cityExperience.net
Dipl. Inf. Martin Kindler
Kaulbachstr. 20a
D-12247 Berlin
Deutschland
eMail [EMAIL PROTECTED]
Tel. +49 (030) 260 78 48 2
Fax +49 (030) 260 78 48 3
GSM +49 (0160) 977 636 14
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]