THINK CYBER CYBERIUM ARENA SIMULATOR TRAINING
NX201 - NETWORK RESEARCH
PROJECT TITLE: REMOTE CONTROL
(OLALEKAN ILORI – S4)
#! /bin/bash
TITLE: --A bash script to automatically execute commands on a remote server anonymously from my
local system
#---------------------------------------------#
#STUDENT NAME; Olalekan Ilori
#STUDENT CODE; s4
#CLASS CODE; Unit 0722
#LECTURER'S NAME; David Shiffman
#---------------------------------------------#
#Code for Checking if my system is anonymous
echo "$(geoiplookup $(curl -s [Link]))" > myIPadd #checks the geolocation of systems ipaddress
cat myIPadd|awk '{print $5}' > myCountry
for i in $(cat myCountry) #takes ip in the
file
do
echo "Your Ip address is from $i "
done
if [ "$i" == "Nigeria" ] #checks if my ip
still from Nigeria
then
cd /home/kali/nipe #if ip
still Nigeria, it changes directory to Nipe folder to access Nipe tool
perl [Link] restart #starts the nipe
tool to make ip anonymous
cd /home/kali
#changes directory back to current directory
echo "You're Not Anonymous, relaunch this script to become anonymous..."
echo "$(cat myCountry)"
else
echo "You're in Anonymous State Already......"
fi
#2---In section below, after achieving anonymous IP, script Automatically connect to a remote VPS
server ([Link]) via ssh and executing commands to a Target server
#---the one-liner script below Enables bypassing fingerprint with "sshpass -p" and Stores the result
locally into the file [Link] in current directory
sshpass -p MjsbBaU30OtuZEh ssh -o StrictHostKeyChecking=off root@[Link] 'whois
[Link] && nmap -F [Link]' > [Link]
echo " [+} The result of your scan has been stored in the file [Link] inside current directory"