From owner-freebsd-questions Sun May 4 12:04:57 1997 Return-Path: Received: (from root@localhost) by hub.freebsd.org (8.8.5/8.8.5) id MAA10936 for questions-outgoing; Sun, 4 May 1997 12:04:57 -0700 (PDT) Received: from iceberg.anchorage.net. (root@iceberg.anchorage.net [207.14.72.150]) by hub.freebsd.org (8.8.5/8.8.5) with SMTP id MAA10928 for ; Sun, 4 May 1997 12:04:54 -0700 (PDT) Received: from aak.anchorage.net (ai-129 [207.14.72.129]) by iceberg.anchorage.net. (8.6.11/8.7.3) with SMTP id KAA09001; Sun, 4 May 1997 10:01:25 -0800 Date: Sun, 4 May 1997 01:58:26 -0800 (AKDT) From: Steve Howe X-Sender: abc@aak.anchorage.net To: Wolfgang Helbig cc: The Devil Himself , un_x@anchorage.net, questions@FreeBSD.ORG Subject: Re: permissions In-Reply-To: <199705041510.RAA00702@helbig.informatik.ba-stuttgart.de> Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: owner-questions@FreeBSD.ORG X-Loop: FreeBSD.org Precedence: bulk > The file permissions are enforced by the kernel, i. e. even if some > userland software ignores the permissions, the kernel won't let > you write, read or execute in violation of the permission rules. > If you are root -- more precisely if your UID is 0 -- the permission > rules allow you to read and write regardless of the permission > flags and owner of the file in question. > To protect a file from root, you have to set the immutable flag > with the chflags(1) command. E. g. this is done by the install > target of the kernel Makefile to prevent root from hosing the kernel > by changing or deleting it accidently. > An > $ ls -ol /kernel /kernel.old > shows the setting of this flag: > > -r-xr-xr-x 1 root wheel schg 793551 2 Mai 21:37 /kernel > -r-xr-xr-x 1 root wheel - 788710 26 Apr 19:36 /kernel.old what's the purpose of the "uchg" flag for users then ... ? i can't write to a r--r--r-- file (owner=user, group=user) as a user ... -------------------------------------------------------------------------