Changeset 43
- Timestamp:
- 12/05/14 18:03:52 (10 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/dnsbl/export-dnsbl
r40 r43 70 70 ($config{bladmin} ? $config{bladmin} : 'systems.company.com')." 0 1200 600 600 900\n". 71 71 "\$NS 3600 127.0.0.1\n". 72 "\$TTL 900\n";72 "\$TTL ".($config{ttl} ? $config{ttl} : '900')."\n"; 73 73 74 74 # more or less raw CIDR block-and-IP info. rbldnsd format for convenience. 75 75 foreach (sort ipcmp keys %iplist) { 76 76 my $entry; 77 if ($iplist{$_} > 256) {78 if ($iplist{$_} > 65536) {77 if ($iplist{$_} >= 256) { 78 if ($iplist{$_} >= 65536) { 79 79 $entry .= int($iplist{$_}/65536)."."; 80 80 $iplist{$_} = $iplist{$_} % 65536; … … 97 97 } 98 98 } else { 99 # default "mode"; tinyDNS data format 99 100 foreach (sort ipcmp keys %iplist) { 100 101 my $entry; … … 114 115 my ($o1,$o2,$o3,$o4) = (/^(\d+)\.([\d*]+)(?:\.([\d*]+)(?:\.([\d*]+))?)?$/); 115 116 print "+".(defined($o4) ? "$o4." : '').(defined($o3) ? "$o3." : '').(defined($o2) ? "$o2." : ''). 116 "$o1.spamhosts.company.com:127.0.0.$entry:900:::\n"; 117 "$o1.".($config{blzone} ? $config{blzone} : 'spamhosts.company.dnsbl').":127.0.0.$entry:" 118 ($config{ttl} ? $config{ttl} : '900').":::\n"; 117 119 } 118 120 }
Note:
See TracChangeset
for help on using the changeset viewer.