openssh - run as another user

Phillip Wu Phillip.Wu at lpma.nsw.gov.au
Fri Aug 27 09:36:53 EST 2010


For security, many systems are configured so you cannot log directly as root via the initial authentication in openssh.

What is usually done is that you log onto as your normal login and once you get a interactive shell you su to root to
run the command that requires root.

Does openssh have a more elegant way of exec'ing a command as root so I can run the command
non-interactively?  I know:
Normal userid
Normal userid password
Root's password

***************************************************************
This message is intended for the addressee named and may contain confidential information. If you are not the intended recipient, please delete it and notify the sender. Views expressed in this message are those of the individual sender, and are not necessarily the views of the Land and Property Management Authority. This email message has been swept by MIMEsweeper for the presence of computer viruses.
***************************************************************
Please consider the environment before printing this email.


More information about the openssh-unix-dev mailing list