Advertisement
RootOfTheNull

Andrew's Code

Apr 19th, 2015
456
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 0.17 KB | None | 0 0
  1. import subprocess
  2.  
  3. a = subprocess.Popen( ['echo','<YOURPASSWORDGOESHERE>'], stdout=subprocess.PIPE )
  4. b = subprocess.Popen( [ 'sudo', '-S', 'date' ], stdin = a.stdout )
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement