Advertisement
MertcanGokgoz

host subscan

Dec 20th, 2018
162
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Bash 0.24 KB | None | 0 0
  1. #!/bin/bash
  2. IPPFX=$1
  3. for i in `seq 1 255` ; do LIST="$LIST ${IPPFX}.$i" ; done
  4. for i in $LIST ; do
  5.     ENTRY="`host $i`"
  6.     [ $? -ne 0 ] && continue
  7.     ENTRY=`echo "$ENTRY" l sed -e 's/.* //' -e 's/\.$//'`
  8.     echo -e "$i\t$ENTRY"
  9. done
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement