Quote:
Originally Posted by Sylvester
The nub of the problem seems to be I cannot execute a bash script if I am not root. it will generate the error /bin/bash: bad interpreter: permission denied.
|
As I said on irc, this is due to GrSec's Trusted Path Execution (TPE). What I said to you was wrong, though. It's the
directory the executable file is located in, not the executable itself, that must be owned by root, and additionally none other than root should have write permission to it. You can fix this with:
Code:
chown root ~/.kde/Austostart
chmod go-w ~/.kde/Austostart
Quote:
Originally Posted by Sylvester
Oddly enough
/bin/bash -c 'echo foo'
Behaves correctly
|
This isn't strange -- you can run 'echo foo' in a bash shell as the incognito user, right? What I think you meant was that running '/bin/bash ./kde/Austostart/foo.sh' works is weird, but really it's not; in this case what we really execute is /bin/bash (/bin is owned by root and have the nice permissions so TPE won't interfere), but the commands in foo.sh are passed to the bash interpreter. foo.sh isn't executed directly (i.e. running ~/.kde/Austostart/foo.sh) which is the only thing TPE cares about.
Quote:
Originally Posted by Sylvester
Does it matter what group the script belongs to?
|
Not with the standard permissions.