Mailing List Archive

Support open source code!


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Article on basic secure shell-script programming



I was under the impression that some flavors of the linux kernel actually 
ignores the suid bit on a script file automatically, NetBSD does. 
As he noted it is more or less impossible to write a secure script, 
but one posibility that he didn't cover is the case where the called 
program allows you to escape to shell:
ie
#!/bin/sh
vi /bin/passwd

once inside vi you can just shell escape and boom root shell.
I imagine this would effect any interactive program inside an
suid script via ctl-z though I can't say without testing.

I guess the moral is avoid suid as much as possible, and never use it
for a shell script.

//Matt


Home | Main Index | Thread Index

Home Page Mailing List Linux and Japan TLUG Members Links