Linux Bash Nmap Netmask Notation Examples

View previous topic View next topic Go down

Linux Bash Nmap Netmask Notation Examples

Post by jamied_uk on 3rd January 2018, 22:16

Example 1


Find ip with /24 notation example
Code:
ip addr show | grep eth1 | grep inet | awk '{print $2}' | cut -d "/" -f 2


Example 2 (For NMAP)


Find ip with /24 notation example 2
Code:
nmap -sP $(ip addr show | grep eth1 | grep inet | awk '{print $2}' | cut -d "/" -f 1) /$
ip addr show | grep eth1 | grep inet | awk '{print $2}' | cut -d "/" -f 2)
avatar
jamied_uk
Admin

Posts : 2305
Join date : 2010-05-09
Age : 35
Location : UK

http://address-shortner.co.uk

Back to top Go down

View previous topic View next topic Back to top

- Similar topics

 
Permissions in this forum:
You cannot reply to topics in this forum