From owner-freebsd-questions@freebsd.org Sun Jan 21 00:31:44 2018 Return-Path: Delivered-To: freebsd-questions@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 8912FED0A07 for ; Sun, 21 Jan 2018 00:31:44 +0000 (UTC) (envelope-from freebsd@edvax.de) Received: from mout.kundenserver.de (mout.kundenserver.de [212.227.126.130]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "mout.kundenserver.de", Issuer "TeleSec ServerPass DE-2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 0C304720E9 for ; Sun, 21 Jan 2018 00:31:43 +0000 (UTC) (envelope-from freebsd@edvax.de) Received: from r56.edvax.de ([92.195.18.98]) by mrelayeu.kundenserver.de (mreue007 [212.227.15.167]) with ESMTPA (Nemesis) id 0LavRV-1f5Gc50HMH-00kfNz; Sun, 21 Jan 2018 01:31:36 +0100 Date: Sun, 21 Jan 2018 01:31:36 +0100 From: Polytropon To: Ralf Mardorf Cc: Ralf Mardorf via freebsd-questions Subject: Re: xfce4 reverts to mirrored dislays Message-Id: <20180121013136.3bf3440a.freebsd@edvax.de> In-Reply-To: <20180120202134.7e20734b@archlinux.localdomain> References: <20180120125636.6ad88128.freebsd@edvax.de> <20180120134001.65ddb697@archlinux.localdomain> <20180120141518.7a85ed99@planb.netng.org> <2c24a50e-c7d1-0841-bee6-9f015d48a927@nethead.se> <20180120170942.532834dd.freebsd@edvax.de> <20180120190647.01b163d0@archlinux.localdomain> <20180120200846.e0925689.freebsd@edvax.de> <20180120202134.7e20734b@archlinux.localdomain> Reply-To: Polytropon Organization: EDVAX X-Mailer: Sylpheed 3.1.1 (GTK+ 2.24.5; i386-portbld-freebsd8.2) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-Provags-ID: V03:K0:mgK5HbwhLhv3JcY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d-questions@freebsd.org X-Mailman-Version: 2.1.25 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 21 Jan 2018 00:31:44 -0000 On Sat, 20 Jan 2018 20:21:34 +0100, Ralf Mardorf via freebsd-questions wrote: > On Sat, 20 Jan 2018 20:08:46 +0100, Polytropon wrote: > >As it seems, the immutable flag is not set. > > Indeed, this makes sense, while my second guess is idiotic, see on Sat, > > 20 Jan 2018 19:23:02 +0100, Ralf Mardorf wrote: > >On Sat, 20 Jan 2018 19:06:47 +0100, Ralf Mardorf wrote: > >>actually it's impossible to change permissions of an immutable file. > > > >Perhaps I'm mistaken regarding "permissions",however, what ever the > >permissions should be, the file remains immutable, > >un-over{ride,write}able ;). > > Somebody needs to have permission to set or clear the immutable flag ;). Being able to change the permissions or ownership would first require "chflags noschg", which usually only root can perform. So even though my suggestion doesn't deserve the name "solution", it _should_ actually prevent any file changes, even if the process which changes the file is UID 0. # touch /tmp/testfile # ll -o /tmp/testfile -rw-r--r-- 1 root wheel - 0 2018-01-21 01:27:49 /tmp/testfile # chmod -w /tmp/testfile # ll -o /tmp/testfile -r--r--r-- 1 root wheel - 0 2018-01-21 01:27:49 /tmp/testfile ^ Writing flag is gone. # chflags schg /tmp/testfile # ll -o /tmp/testfile -r--r--r-- 1 root wheel schg 0 2018-01-21 01:27:49 /tmp/testfile The file is now locked / immutable. # chown ftp:ftp /tmp/testfile chown: /tmp/testfile: Operation not permitted # chmod +w /tmp/testfile chmod: /tmp/testfile: Operation not permitted # rm /tmp/testfile override r--r--r-- root/wheel schg for /tmp/testfile? y rm: /tmp/testfile: Operation not permitted Without a "chflags noschg" issued by root, the file will stay as it is (content, ownership, permissions). -- Polytropon Magdeburg, Germany Happy FreeBSD user since 4.0 Andra moi ennepe, Mousa, ...