Created
September 9, 2019 10:07
-
-
Save olgac/0146febe941c2f7d145fb0b777e8ebe0 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
FILE="/tmp/telnet-scan-$(date '+%Y%m%d%H%M%S')"; | |
IPS="10.10.10.10 10.10.10.11 10.10.10.12"; | |
PORTS="8091 8092 8093 11207 11210 11211 18091 18092"; | |
for ip in $IPS; | |
do | |
for port in $PORTS; | |
do echo "----------------------- SCANNING > " $ip $port; | |
echo "-----------------------" $ip $port >> $FILE; | |
echo -e '\x1dclose\x0d' | telnet $ip $port >> $FILE | |
done; | |
done; | |
echo $FILE; | |
cat $FILE; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment