diff options
| author | Mitch Riedstra <mitch@riedstra.us> | 2019-02-14 21:12:09 -0500 |
|---|---|---|
| committer | Mitch Riedstra <mitch@riedstra.us> | 2019-02-14 21:12:09 -0500 |
| commit | 9bd432b5de3592f89d885deaff953418822acaa9 (patch) | |
| tree | 2dabf2f58dae9e79a4abced904d1734b4ae1d6b6 /lib/spawn | |
| parent | bd13ba3f12da9721ae9e0a81af788a3f9d9bb8f8 (diff) | |
| download | rshsh-9bd432b5de3592f89d885deaff953418822acaa9.tar.gz rshsh-9bd432b5de3592f89d885deaff953418822acaa9.tar.xz | |
Add a readme and allocate a pty for the reverse shell
Diffstat (limited to 'lib/spawn')
| -rwxr-xr-x | lib/spawn | 7 |
1 files changed, 3 insertions, 4 deletions
@@ -5,13 +5,12 @@ SOCKDIR=$(mktemp -d) SOCKF=${SOCKDIR}/usock # Start tmux, if needed -if ! tmux ls | grep -q rshell; then - tmux new -s rshell -d +if ! tmux ls | grep -q rshsh; then + tmux new -s rshsh -d fi # Create window -# Let's just see it works -tmux new-window -t rshell "socat UNIX-LISTEN:${SOCKF},umask=0077 STDIO" +tmux new-window -t rshsh "socat UNIX-LISTEN:${SOCKF},umask=0077 file:\$(tty),raw,echo=0" # Wait for socket while test ! -e ${SOCKF} ; do sleep 1 ; done |
