Created
April 23, 2024 06:19
-
-
Save gedsic/fba2d256be9b7a984e38303fce0cdbfb to your computer and use it in GitHub Desktop.
Get all open TCP ports from an nmap scan, comma separated (quick and dirty)
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
| cat portscan.nmap | grep "^[0-9]*/tcp" | grep "open" | cut -d '/' -f 1 | sort -h | uniq | tr '\n' ',' | head -c -1 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment