Created
February 20, 2013 06:30
-
-
Save k1LoW/4993416 to your computer and use it in GitHub Desktop.
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
| function fluent-allow () { | |
| if [ "`id -u`" == "0" ] ; then | |
| iptables -A INPUT -m state --state NEW -s $1 -m tcp -p tcp --dport 24224 -j ACCEPT | |
| iptables -A INPUT -m state --state NEW -s $1 -m udp -p udp --dport 24224 -j ACCEPT | |
| else | |
| sudo /sbin/iptables -A INPUT -m state --state NEW -s $1 -m tcp -p tcp --dport 24224 -j ACCEPT | |
| sudo /sbin/iptables -A INPUT -m state --state NEW -s $1 -m udp -p udp --dport 24224 -j ACCEPT | |
| fi | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment