Thanks for responding.
My code attached:
> Logging.java is the servlet
> Runner.java is a utility class
> also web.xml

Thanks in advance, Wout Perquin

-----Original Message-----
From: Shapira, Yoav [mailto:[EMAIL PROTECTED]
Sent: November 18, 2004 1:34 PM
To: Tomcat Users List
Subject: RE: write and read problem



Hi,
Post your code and we might be able to help more.  In general, the
server admin may run with restrictive permissions for security at the OS
level, so it wouldn't matter whether the Java Security Manager is
running or not.  This is usually a good idea.  And writing files to a
random directory from a webapp is usually a bad idea.

Yoav Shapira http://www.yoavshapira.com


>-----Original Message-----
>From: Wout Perquin [mailto:[EMAIL PROTECTED]
>Sent: Friday, November 19, 2004 1:38 AM
>To: Tomcat Users List
>Subject: write and read problem
>
>Hi All,
>I run Tomcat4 on Linux Red Hat 7.1
>From within the init() of a servlet I try to read and write to the
local
>filesystem.
>The SecurityManager is not enabled because System.getSecurityManager()
>returns null.
>
>When I try to read/write something then log catalina.out tells me:
>java.io.FileNotFoundException: <path/filename> (Permission denied)
>
>I am not sure what to do next:
>> I believe it is not java security related because there is no
security
>manager active
>> In $CATALINA_HOME/conf/catalina.policy I have granted all permissions
>> Maybe I have to give user-id tomcat4 special rights ?
>
>Any suggestions ?
>
>Many thanks,
>
>Wout Perquin
>
>
>
>
>
>---------------------------------------------------------------------
>To unsubscribe, e-mail: [EMAIL PROTECTED]
>For additional commands, e-mail: [EMAIL PROTECTED]




This e-mail, including any attachments, is a confidential business
communication, and may contain information that is confidential, proprietary
and/or privileged.  This e-mail is intended only for the individual(s) to
whom it is addressed, and may not be saved, copied, printed, disclosed or
used by anyone else.  If you are not the(an) intended recipient, please
immediately delete this e-mail from your computer system and notify the
sender.  Thank you.


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


<?xml version="1.0" encoding="ISO-8859-1"?>

<!DOCTYPE web-app
    PUBLIC "-//Sun Microsystems, Inc.//DTD Web Application 2.3//EN"
    "http://java.sun.com/dtd/web-app_2_3.dtd";>

<web-app>
    <display-name>Servlet Logging Test hedres.org</display-name>
    <description>
      Some tests to understand basic servlet functionalities
    </description>
	<servlet>
		<servlet-name>Logging</servlet-name>
		<servlet-class>hedres.servlets.Logging</servlet-class>
		<init-param>
			<param-name>properties</param-name>
			<param-value>/hedres/conf/servlets/Logging</param-value>
		</init-param>

		<init-param>
			<param-name>java.security.policy</param-name>
			<param-value>http://linuxg:8088/java.policy.all</param-value>
		</init-param>
		<init-param>
			<param-name>net.jini.discovery.interface</param-name>
			<param-value>linuxg</param-value>
		</init-param>
		<init-param>
			<param-name>java.rmi.activation.port</param-name>
			<param-value>1099</param-value>
		</init-param>
		<init-param>
			<param-name>java.rmi.server.codebase</param-name>
			<param-value>http://linuxg:8088/</param-value>
		</init-param>

	</servlet>

	<servlet-mapping>
        <servlet-name>Logging</servlet-name>
        <url-pattern>/grapje</url-pattern>
    </servlet-mapping>

</web-app>

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to