Build the situation: a 644 file inside a 730 directory owned by another user
Build the situation: a 644 file inside a 730 directory owned by another user
Answer
mkdir /srv/shared chgrp staff /srv/shared chmod 730 /srv/shared printf 'v1 approved\n' > /srv/shared/report.txt chmod 644 /srv/shared/report.txt ls -ld /srv/shared /srv/shared/report.txt
The final `ls -ld` prints `drwx-wx---` for the directory and `-rw-r--r--` for the file. Nothing here is unusual: 730 is what you get when you want a group to be able to drop files in without reading each other's, and 644 is the default mode of almost every file on the system.
Stallings & Brown, Computer Security 5e, ch4 §4.4–§4.5