-
-
Save Airdawg5571/1a8c49ca5dd97af55ab9 to your computer and use it in GitHub Desktop.
More organized (pretty-printed) iptables output.
This file contains 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 | |
# Written and tested on CentOS 7 | |
iptables -nvL |cut -f -9|column -t| sed 's/^Chain/\n&/g'|sed '/^Chain/ s/[ \t]\{1,\}/ /g'|sed '/^[0-9]/ s/[ \t]\{1,\}/ /10g' |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment