}
@def &SERVICE_RANGE($proto, $port, $srange) = {
- proto $proto mod state state (NEW) dport $port saddr ($srange) ACCEPT;
+ proto $proto mod state state (NEW) dport $port @subchain "$port" { saddr ($srange) ACCEPT; }"
}
@def &TCP_UDP_SERVICE($port) = {
proto (tcp udp) mod state state (NEW) dport $port ACCEPT;
}
+@def $HOST_MAILRELAY_V4 = (<%=
+ mailrelay = []
+ localinfo.keys.sort.each do |node|
+ if localinfo[node]['mailrelay']
+ keyinfo[node]['ipHostNumber'].each do |ip|
+ next if ip =~ /:/
+ mailrelay << ip
+ end
+ end
+ end
+
+ mailrelay.join(' ')
+%>);
+
+@def $HOST_MAILRELAY_V6 = (<%=
+ mailrelay = []
+ localinfo.keys.sort.each do |node|
+ if localinfo[node]['mailrelay']
+ keyinfo[node]['ipHostNumber'].each do |ip|
+ next if ip =~ /\./
+ mailrelay << ip
+ end
+ end
+ end
+
+ mailrelay.join(' ')
+%>);
+
+@def $HOST_MAILRELAY = ( $HOST_MAILRELAY_V4 $HOST_MAILRELAY_V6 );
+
@def $HOST_NAGIOS_V4 = (<%=
nagii = []
localinfo.keys.sort.each do |node|
- if localinfo[node]['nagiosmaster']
- keyinfo[node][0]['ipHostNumber'].each do |ip|
+ if localinfo[node]['nagiosmaster'] or localinfo[node]['extranrpeclient']
+ keyinfo[node]['ipHostNumber'].each do |ip|
next if ip =~ /:/
nagii << ip
end
@def $HOST_NAGIOS_V6 = (<%=
nagii = []
localinfo.keys.sort.each do |node|
- if localinfo[node]['nagiosmaster']
- keyinfo[node][0]['ipHostNumber'].each do |ip|
+ if localinfo[node]['nagiosmaster'] or localinfo[node]['extranrpeclient']
+ keyinfo[node]['ipHostNumber'].each do |ip|
next if ip =~ /\./
nagii << ip
end
munins = []
localinfo.keys.sort.each do |node|
if localinfo[node]['muninmaster']
- keyinfo[node][0]['ipHostNumber'].each do |ip|
+ keyinfo[node]['ipHostNumber'].each do |ip|
next if ip =~ /:/
munins << ip
end
munins = []
localinfo.keys.sort.each do |node|
if localinfo[node]['muninmaster']
- keyinfo[node][0]['ipHostNumber'].each do |ip|
+ keyinfo[node]['ipHostNumber'].each do |ip|
next if ip =~ /\./
munins << ip
end
dbs = []
localinfo.keys.sort.each do |node|
if localinfo[node]['dbmaster']
- keyinfo[node][0]['ipHostNumber'].each do |ip|
+ keyinfo[node]['ipHostNumber'].each do |ip|
next if ip =~ /\./
dbs << ip
end
dbs = []
localinfo.keys.sort.each do |node|
if localinfo[node]['dbmaster']
- keyinfo[node][0]['ipHostNumber'].each do |ip|
+ keyinfo[node]['ipHostNumber'].each do |ip|
next if ip =~ /:/
dbs << ip
end
@def $HOST_DEBIAN_V4 = (<%=
dbs = []
- localinfo.keys.sort.each do |node|
- next unless (keyinfo.has_key?(node) and keyinfo[node].at(0) and keyinfo[node][0].has_key?('ipHostNumber'))
- keyinfo[node][0]['ipHostNumber'].each do |ip|
+ keyinfo.keys.sort.each do |node|
+ next unless keyinfo[node].has_key?('ipHostNumber')
+ keyinfo[node]['ipHostNumber'].each do |ip|
next if ip =~ /:/
dbs << ip
end
@def $HOST_DEBIAN_V6 = (<%=
dbs = []
- localinfo.keys.sort.each do |node|
- next unless (keyinfo.has_key?(node) and keyinfo[node].at(0) and keyinfo[node][0].has_key?('ipHostNumber'))
- keyinfo[node][0]['ipHostNumber'].each do |ip|
+ keyinfo.keys.sort.each do |node|
+ next unless keyinfo[node].has_key?('ipHostNumber')
+ keyinfo[node]['ipHostNumber'].each do |ip|
next if ip =~ /\./
dbs << ip
end
@def $HOST_DEBIAN = ($HOST_DEBIAN_V4 $HOST_DEBIAN_V6);
-@def $sgran = (91.103.132.24/29);
+@def $sgran = (91.103.132.24/29 85.158.45.51/32);
@def $weasel = ();
@def $weasel = ($weasel 86.59.118.144/28); # debian@sil
@def $weasel = ($weasel 86.59.21.32/29); # anguilla1
@def $DSA_IPS = ($sgran $weasel $zobel $luca);
@def $sgran6 = (2001:4b10:100b::/48);
+@def $sgran6 = ($sgran6 2001:4b10:0000:810b::/64);
@def $weasel6 = ();
@def $weasel6 = ($weasel6 2001:826:408:200::/56); # came
@def $weasel6 = ($weasel6 2001:858:10f::/48); # anguilla
@def $zobel6 = ($zobel6 2a01:198:549::/48); # WGS20
@def $luca6 = ();
@def $DSA_V6_IPS = ($sgran6 $weasel6 $zobel6 $luca6);
+
+@def $USER_kibi = ();
+@def $USER_kibi = ($USER_kibi 90.80.97.98); # gruyere.kerlabs.com
+@def $USER_kibi = ($USER_kibi 88.164.242.219); # home.ikibiki.org
+@def $USER_kibi = ($USER_kibi 82.244.158.68); # @parents'
+@def $USER_aurel32 = ();
+@def $USER_aurel32 = ($USER_aurel32 88.191.82.174); # hall.aurel32.net
+@def $USER_aurel32 = ($USER_aurel32 82.232.2.251); # farad.aurel32.net
+@def $FREEBSD_SSH_ACCESS = ($DSA_IPS $USER_kibi $USER_aurel32);