Quick Scan Linux Script Security TUT
Page 1 of 1
Quick Scan Linux Script Security TUT
Code:
- Code:
#!/bin/bash
#
# (c) J~Net 2017
#
# jnet.forumotion.com/t1477-quick-scan-linux-script-security-tut#2157
#
# Kali Linux
# chmod +x *.sh
#
# Non Kali
# sudo chmod +x *.sh
#
# Example:
# ./Run.sh enp0s3 or wlan0 or eth0
#
#apt update && apt upgrade -y
#apt install -y ettercap
var="$1"
# Non Kali Install
sudo apt install arp-scan
# Kali Install
# apt install arp-scan
clear
ifconfig
echo "Choose An Adapter & Type It In"
# Check if user put in any adapter
if [ -z "$1" ] && [ -z "$2" ]
then
read var
fi
# Kali Run
#arp-scan --interface=$var --localnet
# Non kali Run
sudo arp-scan --interface=$var --localnet
Re: Quick Scan Linux Script Security TUT
Scan Function
- Code:
sudo gedit .bashrc
- Code:
function Scan(){
var="$1"
# Non Kali Install
sudo apt install arp-scan
# Kali Install
# apt install arp-scan
clear
ifconfig
echo "Choose An Adapter & Type It In"
# Check if user put in any adapter
if [ -z "$1" ] && [ -z "$2" ]
then
read var
fi
# Kali Run
#arp-scan --interface=$var --localnet
# Non kali Run
sudo arp-scan --interface=$var --localnet
}
Re: Quick Scan Linux Script Security TUT
Also Check Out
jnet.forumotion.com/t1506-linux-bash-mass-scanning-the-whole-internet-web-cams#2223
https://jnet.forumotion.com/t1506-linux-bash-mass-scanning-the-whole-internet-web-cams#2223
jnet.forumotion.com/t1506-linux-bash-mass-scanning-the-whole-internet-web-cams#2223
https://jnet.forumotion.com/t1506-linux-bash-mass-scanning-the-whole-internet-web-cams#2223
Re: Quick Scan Linux Script Security TUT
Updated Quick Scan With Comparison For Security Checking
- Code:
#!/bin/bash
#
# (c) J~Net 2017
#
# jnet.forumotion.com/t1477-quick-scan-linux-script-security-tut#2157
#
# Kali Linux
# chmod +x *.sh
#
# Non Kali
# sudo chmod +x *.sh
#
# Example:
# ./Run.sh enp0s3 or wlan0 or eth0
#
# Check old scan file exists and backup if it does for comparison
#
#apt update && apt upgrade -y
#apt install -y ettercap
var="$1"
# Non Kali Install
sudo apt install arp-scan
# Kali Install
# apt install arp-scan
#
# Check if old log file exists!...
if [ -f "output.txt" ]; then
echo "backing Up Old Log File For Comparison, Please Wait...";
# Instead of copying we sort here to save time later!...
cat output.txt | sort > old_output.txt
#
fi
clear
ifconfig
echo "Choose An Adapter & Type It In"
# Check if user put in any adapter
if [ -z "$1" ] && [ -z "$2" ]
then
read var
fi
# Kali Run
#arp-scan --interface=$var --localnet
# Non kali Run
sudo arp-scan --interface=$var --localnet > output.txt
head -n -3 output.txt > tempoutput.txt ; mv tempoutput.txt output.txt
clear
cat output.txt
# Now compare with old scan data
if [ -f "old_output.txt" ]; then
echo "Comparing Log Files, Please Wait..."
cat output.txt | sort > tmp_output.txt
mv tmp_output.txt output.txt
echo "Differences Are Listed Below"
echo ""
grep -f old_output.txt output.txt
#
# var1 contains size of file1
var1=$(stat -c%s old_output.txt)
# var2 contains size of file2
var2=$(stat -c%s output.txt)
#same as above
if [[ "$var1" -lt "$var2" ]]; then
echo ""
echo ""
echo 'New Devices Maybe On Youre Network'
elif [[ "$var1" -gt "$var2" ]]; then
echo ""
echo ""
echo 'Everything Seems Normal'
elif [[ "$var1" -eq "$var2" ]]; then
echo ""
echo ""
echo 'Everything Seems Normal'
fi
fi
Similar topics
» Free Security Check Script For Linux
» Scan a whole network with nmap script example
» how to scan from a printer using linux
» Quick & Easy Old Usful Encrypt & Decrypt Methods for linux
» Using Nmap On Linux To Scan For Open Ports On Remote Host
» Scan a whole network with nmap script example
» how to scan from a printer using linux
» Quick & Easy Old Usful Encrypt & Decrypt Methods for linux
» Using Nmap On Linux To Scan For Open Ports On Remote Host
Page 1 of 1
Permissions in this forum:
You cannot reply to topics in this forum