- Timestamp:
- 01/16/15 17:28:35 (10 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/dns-rpc.cgi
r675 r676 87 87 #sub downconvert { 88 88 'dnsdb.addOrUpdateRevRec' => \&addOrUpdateRevRec, 89 'dnsdb.updateRevSet' => \&updateRevSet, 89 90 'dnsdb.delRec' => \&delRec, 90 91 'dnsdb.delByCIDR' => \&delByCIDR, … … 596 597 } # iterate zones within $cidr 597 598 } # done $cidr-contains-zones 598 } 599 ##fixme: what about errors? what about warnings? 600 } # done addOrUpdateRevRec() 601 602 # Update rDNS on a whole batch of IP addresses. Presented as a separate sub via RPC 603 # since RPC calls can be s...l...o...w.... 604 sub updateRevSet { 605 my %args = @_; 606 607 _commoncheck(\%args, 'y'); 608 609 my @ret; 610 # loop over passed IP/hostname pairs 611 foreach my $key (keys %args) { 612 next unless $key =~ /^host_([\d.]+|[\da-f:]+)$/; 613 my $ip = $1; 614 push @ret, addOrUpdateRevRec(cidr => $ip, name => $args{$key}, %args); 615 } 616 ##fixme: what about errors? what about warnings? 617 return \@ret; 618 } # done updateRevSet() 599 619 600 620 sub delRec {
Note:
See TracChangeset
for help on using the changeset viewer.