butterknife - strange directory permissions #17
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Hi Drew,
first of all, I was extremely happy when I found Butterknife. I’ve wanted a Debian installer like this for a long time. I really like Debian, but getting a proper BTRFS setup with subvolumes, Timeshift and GRUB rollback working nicely has always involved a lot of manual work. Having an installer that takes care of all of this is exactly what I was looking for.
I’ve been testing Butterknife in a VM and noticed something with the directory permissions that I wanted to report.
GUFW gave me a warning about
/libbeing writable. I checked a few directories afterwards and found that several system directories are 775 instead of the 755 I normally see on Debian.For example, directly after a fresh install:
At first I thought this might have happened because I had upgraded the system or changed something myself.
So I made another fresh installation and checked the permissions before doing any updates. They were already like this.
I then tried again with the newer Butterknife 0.3.2 ISO on a fresh virtual disk and got the same result immediately after installation.
I compared the same directories with a normal Debian installation and they are 755 there.
Maybe there is a reason for the 775 permissions that I’m not aware of, but since GUFW complained about
/libit seemed worth mentioning.No hurry at all. I just wanted to let you know because I really like the idea behind Butterknife and hope to use it for my Debian systems.
Thanks for your work on it!
And I hope I haven't reported something as a bug here that is actually intentional. :-)
Best regards
Oliver
Thanks Oliver, this is a real bug and not intentional. Good catch, and thanks for doing the second clean install to rule yourself out.
Cause: the installer copies its overlay files onto the new system with cp -a, and cp -a stamps the source directory modes onto directories that already exist on the target. The checkout the ISO is built from has group-writable directories, so /usr/lib, /etc/systemd and the rest of the list you posted came out 775. Only /, /etc and /usr were being reset afterwards, which is why those three looked right.
It is 775 root:root, so on a stock install nobody but root can write there. Still wrong, and it should not be shipping. Fixed on dev; the overlay now goes through tar with modes normalised and existing directories left alone. It will be in 0.3.3, which I am building now.
For your existing install, this puts the affected directories back to stock. Package upgrades will not do it for you, since dpkg does not change the mode of a directory that already exists: