0

The following rules were working for ipv4 addresses in iptables but using the same rules in ip6tables is not working. Currently all ipv6 addresses are being blocked. This rule set should allow https access from the single ip 2500:1017:b91a:97e5:53e8:7700:b09b:b93

Chain INPUT (policy DROP 0 packets, 0 bytes)
 pkts bytes target     prot opt in     out     source               destination         
    0     0 ACCEPT     tcp      any    any     anywhere             anywhere             tcp dpt:ssh
    0     0 ACCEPT     all      lo     any     anywhere             anywhere            
    0     0 ACCEPT     all      any    any     anywhere             anywhere             state RELATED,ESTABLISHED
    0     0 DROP       tcp      any    any     anywhere             anywhere             tcp dpt:http
    0     0 ACCEPT     tcp      any    any     2500:1017:b91a:97e5:53e8:7700:b09b:b93  anywhere             tcp dpt:https
    0     0 DROP       tcp      any    any     anywhere             anywhere             tcp dpt:https

Chain FORWARD (policy DROP 0 packets, 0 bytes)
 pkts bytes target     prot opt in     out     source               destination         

Chain OUTPUT (policy ACCEPT 0 packets, 0 bytes)
 pkts bytes target     prot opt in     out     source               destination    

Edit:

I have been playing around with this and iptables -A INPUT -p tcp --dport 443 -j DROP in iptables is also affecting IP6 connections, from what I have read I thought iptables would only affect IP4 connections.

8
  • That ruleset looks right. What is the problem you are having? Feb 9, 2017 at 18:25
  • so imagine the same ruleset in iptables but with the single IP line commented out. With both rulesets active the single IP is blocked, I have been allowing access to IP4 addresses in the same way via iptables ok but can only seem to get access from an IP6 address if I remove the block in iptables, which doesn't make sense as that should only affect IP4 addresses. Whatever I do ip6tables just seems to be ignored although I haven't tested any other rules.
    – Kline
    Feb 10, 2017 at 0:57
  • Where are your rules to allow ICMP?! IPv6 will not work properly without this. Feb 10, 2017 at 0:59
  • Where does that need to go ip6tables or iptables?
    – Kline
    Feb 10, 2017 at 1:44
  • Well, is it IPv4 or IPv6? Feb 10, 2017 at 1:47

0

You must log in to answer this question.

Browse other questions tagged .