From: Mark Wooding Date: Mon, 21 Apr 2014 21:21:48 +0000 (+0100) Subject: local.m4: Move VPN hosts to ...:1. X-Git-Url: https://git.distorted.org.uk/~mdw/firewall/commitdiff_plain/eec061c0c560e9bee479a34620b3a399b09d9d3d local.m4: Move VPN hosts to ...:1. Linux thinks that host addresses which coincide with network base addresses are `anycast', and that this means that it shouldn't send ICMP errors to them. This is obviously ridiculous. so move hosts to address ...:1 to prevent this stupidity. --- diff --git a/local.m4 b/local.m4 index c617520..e486605 100644 --- a/local.m4 +++ b/local.m4 @@ -243,9 +243,9 @@ defnet sgo noloop defnet vpn safe addr 172.29.199.128/27 2001:ba8:1d9:6000::/64 via househub colohub - host crybaby 1 ::1:0 - host terror 2 ::2:0 - host orange 3 ::3:0 + host crybaby 1 ::1:1 + host terror 2 ::2:1 + host orange 3 ::3:1 defnet anycast trusted addr 172.29.199.224/27 2001:ba8:1d9:0::/64 via dmz unsafe safe untrusted jump colo vpn diff --git a/radius.m4 b/radius.m4 index 090249c..0db7c51 100644 --- a/radius.m4 +++ b/radius.m4 @@ -76,6 +76,16 @@ run iptables -t nat -A outbound -j RETURN ! -o ppp0 run iptables -t nat -A outbound -j RETURN ! -s 172.29.198.0/23 run iptables -t nat -A outbound -j RETURN -d 62.49.204.144/28 run iptables -t nat -A outbound -j RETURN -d 172.29.198.0/23 + +## An awful hack. +##run iptables -t nat -A outbound -j DNETMAP --reuse \ +## -s 172.29.199.44 --prefix 62.49.204.157 +##run iptables -t nat -A outbound -j DNETMAP --reuse \ +## -s 172.29.198.34 --prefix 62.49.204.157 +##run iptables -t nat -A outbound -j DNETMAP --reuse \ +## -s 172.29.198.11 --prefix 62.49.204.157 +##run iptables -t nat -A PREROUTING -j DNETMAP + run iptables -t nat -A outbound -j SNAT --to-source 62.49.204.158 run iptables -t nat -A POSTROUTING -j outbound