Created
July 13, 2016 12:45
-
-
Save kkroesch/1ed7cd5956dd5ec020751ca59725be50 to your computer and use it in GitHub Desktop.
Figure out if your computer is behind NATing firewall.
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
INTERFACE=$(ifconfig en0 | grep 'inet ' | cut -f2 | awk '{ print $2}') | |
PUBLIC=$(curl -s http://ifconfig.co) | |
[ $INTERFACE = $PUBLIC ] || echo NAT |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment