How to bypass entering password using sudo su - oracle "-c /u sr/l ocal/bin/test/whoisit.ksh"

Trinh, Khai-Vinh khaivinh.trinh at alldata.net
Tue Feb 17 11:25:10 EST 2004


Thank you for your response.  I've tried out as you recommended but it does
not seem to work.  I might of made a mistake somewhere.  I found a way
around this by write a c-program that does the su - parameter and it through
sudo.  This works out very nicely as we can perform error checkings and
filterings.

Thanks again for your help.

K.T.

-----Original Message-----
From: Todd C. Miller [mailto:Todd.Miller at courtesan.com]
Sent: Thursday, February 05, 2004 9:26 PM
To: Trinh, Khai-Vinh
Cc: 'sudo-users at sudo.ws'
Subject: Re: How to bypass entering password using sudo su - oracle "-c
/usr/l ocal/bin/test/whoisit.ksh" 


The problem is that the shell is interpreting the double quotes for
you and so they are not passed to sudo at all.  If you escape the
quotes from the shell it will work.

Ie:
    sudo /usr/bin/su - oracle \"-c /usr/local/bin/test/whoisit.ksh\"

 - todd



More information about the sudo-users mailing list