shell() and sudo
Alex Rice
alrice at ARCplanning.com
Wed May 14 15:11:02 EDT 2003
On Wednesday, May 14, 2003, at 11:53 AM, Yennie at aol.com wrote:
> I think this may be what you are looking for:
>
> echo "password" | sudo -S ls
>
> This pipes your password to the "sudo" command. The -S option to sudo
> reads the password from stdin.
On a multiuser machine that would be a security risk. Any user could
see the password in cleartext if they happened to run "ps" while the
command above was executing. On a single user machine it wouldn't
really matter, but a better solution would be to wrap the sudo command
using open/read/write process.
Alex Rice, Software Developer
Architectural Research Consultants, Inc.
alrice at ARCplanning.com
alrice at swcp.com
More information about the use-livecode
mailing list