in reply to Re: why does perl-suid not mount
in thread why does perl-suid not mount
setcap was worth a try.
# install -o root -g users -m 750 /home/lh/prog/hmount/hmount.pl /home +/lh/prog/hmount/hmount # setcap cap_dac_override,cap_sys_admin+ep /home/lh/prog/hmount/hmount
I'm not proficient with the capability system, but these caps were proposed for the mount command in the link that you supplied. The effect was similar and still mount denies its service:
~/prog/hmount$ ./hmount --usb= ~/mnt Real uid: 1000 Effective uid: 1000 whoami> lh INFO: Attached sda: (sda1 sda2 sda3) on USB bus 17:0:0:0 mount: only root can do that
sudo on the other hand does not transport the real uid to the program, does it? So the program cannot determine what the $home of the real user may be, i.e. where mounting is deemed to be allowed.
Anyhow, thanks for theese ideas.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^3: why does perl-suid not mount
by Anonymous Monk on Nov 10, 2010 at 13:46 UTC | |
by Anonymous Monk on Nov 10, 2010 at 14:33 UTC |