using "su" without keying in the password

Rick Orr orr at neptune.UUCP
Thu Mar 15 06:27:40 AEST 1990


Question:

 Is there a way to use the "su" command in a script and have the
 script supply the password, without it having to be typed. 
 I have tried several ways without any success.

 I've tried:
 ---------------------------------------------------------------------
 #! /bin/csh -f

 su xyz
 password
 .
 .
 .
 end

 ----------------------------------------------------------------------

 file: 

     su xyz
     password


 $ csh < file

 ----------------------------------------------------------------------


 Thanks in advance.
-- 
Rick Orr                            
                                   



More information about the Comp.unix.wizards mailing list