From owner-freebsd-questions@FreeBSD.ORG Tue Nov 11 11:10:34 2003 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id AEDA816A4CE for ; Tue, 11 Nov 2003 11:10:34 -0800 (PST) Received: from mail.caraldi.com (caraldi.com [62.212.102.95]) by mx1.FreeBSD.org (Postfix) with ESMTP id 1899243F3F for ; Tue, 11 Nov 2003 11:10:33 -0800 (PST) (envelope-from jbq@mail.caraldi.com) Received: by mail.caraldi.com (Postfix, from userid 1001) id 3AA05220E; Tue, 11 Nov 2003 20:10:31 +0100 (CET) Date: Tue, 11 Nov 2003 20:10:31 +0100 From: Jean-Baptiste Quenot To: freebsd-questions@freebsd.org Message-ID: <20031111191029.GB59651@flower.intra.caraldi.com> Mail-Followup-To: freebsd-questions@freebsd.org References: <200310111243.08231.jason@dictos.com> <035501c3909c$3d1dd8d0$a4b826cb@goo> <001c01c3a082$afab7d30$0100000a@Biggie> <200311021458.49682.malcolm.kay@internode.on.net> <1067814513.825.497.camel@verdammt.falcotronic.net> <44ad7dimrc.fsf@be-well.ilk.org> <1067898777.825.714.camel@verdammt.falcotronic.net> <001701c3a864$408415e0$fa65a8c0@ocfl061> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <001701c3a864$408415e0$fa65a8c0@ocfl061> User-Agent: Mutt/1.5.4i Subject: Re: owner of dir/files X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 11 Nov 2003 19:10:34 -0000 * M.D. DeWar: > I just noticed that when I d/led a program and un-tarred it and set it > up that the directory in the apache web root has as owner something > like 501:www . I also noticed some others that were mysql:mysql or > 500:100 for the user/group. > > I am not sure what happens if left that way. Since there is no > user/group for those does it mean the files won't run or be served ? Whether the files will be served or not depends on the file mode, not the file owner. Apache runs as user www, so www must be able to read those files. When files have mode 644 and dirs 755, it is always possible to serve a website, whatever the owner (user/group) is. > In my web root should all directories and files be nobody:nobody ? The files and directories should be owned by their actual author, to be able to change them. > what if some are root:wheel ? Then only root will be able to gain the user mode, and only users in the wheel group will be able to gain the group mode. For example if the mode is 640, root can write to the file, and users in wheel can read the file. But Apache won't be able to read it. See chmod(1) for more details. Cheers, -- Jean-Baptiste Quenot http://caraldi.com/jbq/