To delete a file in Linux,
You need to have x-permissions and w-permissions on the directory (and of course x-permissions on all parents), that is all.
mkdir foo
touch foo/bar
chmod 300 foo
chmod 000 foo/bar
rm -f foo/bar
But when testing you might stumble into thinking that you need more (e. g. r-permissions for the directory or whatever). This will be only due to false testing ;-)
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With