Return-Path: Delivered-To: apmail-jakarta-tomcat-user-archive@www.apache.org Received: (qmail 65205 invoked from network); 15 Sep 2004 19:53:30 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (209.237.227.199) by minotaur-2.apache.org with SMTP; 15 Sep 2004 19:53:30 -0000 Received: (qmail 50171 invoked by uid 500); 15 Sep 2004 19:52:57 -0000 Delivered-To: apmail-jakarta-tomcat-user-archive@jakarta.apache.org Received: (qmail 50150 invoked by uid 500); 15 Sep 2004 19:52:56 -0000 Mailing-List: contact tomcat-user-help@jakarta.apache.org; run by ezmlm Precedence: bulk List-Unsubscribe: List-Subscribe: List-Help: List-Post: List-Id: "Tomcat Users List" Reply-To: "Tomcat Users List" Delivered-To: mailing list tomcat-user@jakarta.apache.org Received: (qmail 50137 invoked by uid 99); 15 Sep 2004 19:52:56 -0000 X-ASF-Spam-Status: No, hits=0.0 required=10.0 tests= X-Spam-Check-By: apache.org Received-SPF: pass (hermes.apache.org: local policy) Received: from [207.103.101.5] (HELO neptune.bristle.com) (207.103.101.5) by apache.org (qpsmtpd/0.28) with ESMTP; Wed, 15 Sep 2004 12:52:55 -0700 Received: from bristle.com ([207.103.101.3]) by neptune.bristle.com (8.11.2/8.11.2) with ESMTP id i8FJDb721146; Wed, 15 Sep 2004 15:13:37 -0400 Message-ID: <41489D0C.99FC7B9F@bristle.com> Date: Wed, 15 Sep 2004 15:50:36 -0400 From: Fred Stluka Organization: Bristle Software, Inc. X-Mailer: Mozilla 4.79 [en] (Windows NT 5.0; U) X-Accept-Language: en MIME-Version: 1.0 To: Tomcat Users List Subject: Re: Why does startup of Tomcat 5.0.28 server make tomcat-users.xml world-readable?... References: <9C5166762F311146951505C6790A9CF80229C149@US-VS1.corp.mpi.com> Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Virus-Checked: Checked X-Spam-Rating: minotaur-2.apache.org 1.6.2 0/1000/N OK. Thanks! --Fred -------------------------------------------------------------------------- Fred Stluka -- mailto:fred@bristle.com -- http://bristle.com/~fred/ Bristle Software, Inc -- http://bristle.com -- "Glad to be of service!" -------------------------------------------------------------------------- "Shapira, Yoav" wrote: > Hi, > > >However, I still wonder: > >1. Why does Tomcat re-write the tomcat-users.xml file at > > startup? > > This I already answered: Tomcat rewrites the tomcat-users.xml at startup > to ensure it has permissions on it, because the admin webapp must have > these permissions to allow editing of user information. > > >2. Why does it use the umask value instead of just leaving > > the protections as they were before it updated the file? > > This is the java.io.File default behavior: we don't modify anything and > don't want to have platform-specific or native code in Tomcat. If you > look at the java.io.File JavaDoc, you'll see there's no portable way to > control this. > > >3. Isn't this a problem for most Tomcat installations, since > > without the umask I had applied to my tomcat user, the > > default umask is 002, not 022, so the tomcat-users.xml > > file would be changed to 664, not merely 644, at each > > startup? Seems like the default Tomcat behavior > > introduces a security risk. > > Judging by the fact this is raised about once a year on the mailing > list, I'd say the majority of people don't care. Secure installations > take care with their umasks from the beginning, so for them this is not > an issue. > > Yoav > > 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: tomcat-user-unsubscribe@jakarta.apache.org > For additional commands, e-mail: tomcat-user-help@jakarta.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org For additional commands, e-mail: tomcat-user-help@jakarta.apache.org