Last active
August 29, 2015 14:27
-
-
Save zedsec390/5c1503a271a8e4e96088 to your computer and use it in GitHub Desktop.
Patch for 2.7.6 Python (rocket ported tools) pty.py - allows for spawning shell via python
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
--- pty.py.old 2015-08-21 12:29:10.000000000 -0500 | |
+++ pty.py 2015-08-21 12:29:10.000000000 -0500 | |
@@ -61,6 +61,7 @@ | |
return master_fd, tty_name | |
for x in 'pqrstuvwxyzPQRST': | |
for y in '0123456789abcdef': | |
+ y='000' + y | |
pty_name = '/dev/pty' + x + y | |
try: | |
fd = os.open(pty_name, os.O_RDWR) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment