Skip to content

Instantly share code, notes, and snippets.

Created May 9, 2011 16:01
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save anonymous/962782 to your computer and use it in GitHub Desktop.
Save anonymous/962782 to your computer and use it in GitHub Desktop.
map.sh - quickly see what's up
#!/bin/bash
# map.sh
IP_RANGE=$(ifconfig | grep "inet " | grep -v "127.0.0.1" | awk '{print $2}' | awk -F. '{print $1"."$2"."$3".1-254"}')
echo
echo "Scanning $IP_RANGE..."
nmap -sP $IP_RANGE
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment