The UNIX and Linux Forums  

Go Back   The UNIX and Linux Forums > Special Forums > Security
Google UNIX.COM



Thread: Script Security
View Single Post in UNIX Forums - Click on the Thread or Permalink to View Entire Thread -->
  #5 (permalink)  
Old 12-05-2007
porter porter is offline
Registered User
 

Join Date: Jan 2007
Posts: 2,965
Quote:
Originally Posted by idoukas View Post
Is there a way that I can overcome this?
You shouldn't be seeing the script with ps but you will see command line arguments and environment variables as they are used.

Alas, for "sh" to execute your script it needs to be able to read it.

However you could set up your own shell where all the scripts are owned by some obscure user, and the shell is a set-uid process that flips to that user. But then that user would not have the same rights as the current user.

But you would still need little wrappers...

Code:
#!/bin/sh
exec /my/magic/shell /some/hidden/shell/script.sh $@
Reply With Quote