Bob Mottram пре 11 година
родитељ
комит
7c4484c313
1 измењених фајлова са 12 додато и 2 уклоњено
  1. 12
    2
      beaglebone.txt

+ 12
- 2
beaglebone.txt Прегледај датотеку

502
 # First of all delete any existing rules.
502
 # First of all delete any existing rules.
503
 # This means you're back to a known state:
503
 # This means you're back to a known state:
504
 iptables -P INPUT ACCEPT
504
 iptables -P INPUT ACCEPT
505
+ip6tables -P INPUT ACCEPT
505
 iptables -F
506
 iptables -F
506
 iptables -X
507
 iptables -X
507
 
508
 
509
+# Drop any IPv6 traffic
510
+ip6tables -A INPUT -p tcp -j DROP
511
+ip6tables -A INPUT -p udp -j DROP
512
+
508
 # Drop access to unused ports
513
 # Drop access to unused ports
509
 iptables -A INPUT -p tcp --destination-port 1 -j DROP
514
 iptables -A INPUT -p tcp --destination-port 1 -j DROP
510
 iptables -A INPUT -p tcp --destination-port 7 -j DROP
515
 iptables -A INPUT -p tcp --destination-port 7 -j DROP
615
 chmod +x /etc/network/if-up.d/iptables
620
 chmod +x /etc/network/if-up.d/iptables
616
 #+END_SRC
621
 #+END_SRC
617
 
622
 
618
-Save and exit
623
+Save and exit.
624
+
625
+Note that this will disable IP version 6.  At the time of writing it is expected that the average internet user is running on IP version 4.
619
 
626
 
620
 #+BEGIN_SRC: bash
627
 #+BEGIN_SRC: bash
621
 chmod +x /tmp/firewall.sh
628
 chmod +x /tmp/firewall.sh
646
 #+BEGIN_SRC: bash
653
 #+BEGIN_SRC: bash
647
 # ignore pings
654
 # ignore pings
648
 net.ipv4.icmp_echo_ignore_all = 1
655
 net.ipv4.icmp_echo_ignore_all = 1
656
+
657
+# disable ipv6
658
+net.ipv6.conf.all.disable_ipv6 = 1
649
 #+END_SRC
659
 #+END_SRC
650
 
660
 
651
 Save and exit.  It may be a good idea to reboot at this point and then log back into the BBB using ssh.  You can do a safe reboot of the system by typing:
661
 Save and exit.  It may be a good idea to reboot at this point and then log back into the BBB using ssh.  You can do a safe reboot of the system by typing:
1210
 
1220
 
1211
 *** Rules for specific email addresses
1221
 *** Rules for specific email addresses
1212
 
1222
 
1213
-You can also make a script which will allow you to add specific email addresses to a folder.
1223
+You can also make a script which will allow you to move mail from specific email addresses to a folder.
1214
 
1224
 
1215
 #+BEGIN_SRC: bash
1225
 #+BEGIN_SRC: bash
1216
 emacs /usr/bin/emailrule
1226
 emacs /usr/bin/emailrule