I created a file /home/andrew/lolka123
and granted read
permission to a group named andrew
. (user andrew owns the file and also a parent directory) I also added group permission to the parent directory.
Now I want to grant access to this file to user http.
Both users andrew and http are present in group andrew
.
Now I'm trying to read file from http user but it gives me Permission denied
, why?
getfacl /home/andrew/lol123
:
# file: home/andrew/lol123
# owner: andrew
# group: andrew
user::rw-
group::r--
other::r--
getfacl ~/
:
getfacl: Removing leading '/' from absolute path names
# file: home/andrew/
# owner: andrew
# group: andrew
user::rwx
user:nobody:--x
group::---
mask::rwx
other::---
EDIT 2:
sudo chmod g+rx /home/andrew/
doesn't work. getfacl /home/andrew/
still shows group::---
getenforce
please. What OS are you using? – mrc02_kr Sep 06 '17 at 13:234.11.9-1
kernel.getenforce
command is not available, and it's not available in any packages fromArch
repository. – deathangel908 Sep 06 '17 at 13:25getfacl .
? – user4556274 Sep 06 '17 at 13:40getfacl .
to the question. – deathangel908 Sep 06 '17 at 13:49ls -ldz /home/andrew
showsdrwxrwx--x+ 141 andrew andrew ?
– deathangel908 Sep 06 '17 at 14:01ls -ld /home
to see if the http user can get through there – Jeff Schaller Sep 06 '17 at 14:11group::---
perms on the directory are going to deny access to anyone in the directory's group (aside from the directory's owner). – Mark Plotnick Sep 06 '17 at 14:22chmod g+rw
doesn't work – deathangel908 Sep 07 '17 at 11:55chmod g+rwx
, although giving write access to the http server might not be a good idea, sog=rx
may be better. – Mark Plotnick Sep 10 '17 at 01:30