Thread
:
Switch User
View Single Post
Jan 28th, 2008, 6:35 PM
#
1
kruptof
Professional Programmer
Join Date: May 2006
Location: UK - London
Posts: 329
Rep Power:
3
Switch User
I need to switch users while performing a task, I am trying to do this with the following:
(
Toggle Plain Text
)
echo "pass" | sudo -u user | ls
echo "pass" | sudo -u user | ls
However I can't seem to escape the prompt for the password, is there a way for this prompt not show up?
__________________
Quote:
When I was young it seemed that life was so wonderful,a miracle, oh it was beautiful, magical.
Now watch what you say or they'll be calling you a radical,a liberal, oh fanatical, criminal. Oh won't you sign up your name,we'd like to feel you're acceptable, respectable, oh presentable, a vegetable
kruptof
View Public Profile
Find More Posts by kruptof