Applied easydns.patch, patch 117054

git-svn-id: svn+ssh://svn.code.sf.net/p/ddclient/code/trunk/svn@53 3873ddee-7413-0410-b6c4-c2c57c1ab35a
This commit is contained in:
wimpunk 2007-06-05 21:34:45 +00:00
parent fa31265d6b
commit e8ef4acf5e

View file

@ -365,6 +365,11 @@ my %variables = (
'mx' => setv(T_OFQDN, 0, 1, 1, '', undef),
'backupmx' => setv(T_BOOL, 0, 1, 1, 0, undef),
},
'easydns-common-defaults' => {
'wildcard' => setv(T_BOOL, 0, 1, 1, 0, undef),
'mx' => setv(T_OFQDN, 0, 1, 1, '', undef),
'backupmx' => setv(T_BOOL, 0, 1, 1, 0, undef),
},
'dnspark-common-defaults' => {
'mx' => setv(T_OFQDN, 0, 1, 1, '', undef),
'mxpri' => setv(T_NUMBER, 0, 0, 1, 5, undef),
@ -437,6 +442,7 @@ my %services = (
'variables' => merge(
{ 'server' => setv(T_FQDNP, 1, 0, 1, 'members.easydns.com', undef) },
{ 'min-interval' => setv(T_DELAY, 0, 0, 1, interval('5m'), 0),},
$variables{'easydns-common-defaults'},
$variables{'service-common-defaults'},
),
},
@ -2773,14 +2779,14 @@ sub nic_easydns_update {
info("setting IP address to %s for %s", $ip, $hosts);
verbose("UPDATE:","updating %s", $hosts);
#'http://members.easydns.com:80/dyn/ez-ipupdate.php?action=edit&myip=10.20.30.40&host_id=test.burry.ca&'
#'http://members.easydns.com/dyn/dyndns.php?hostname=test.burry.ca&myip=10.20.30.40&wildcard=ON'
my $url;
$url = "http://$config{$h}{'server'}/dyn/ez-ipupdate.php?action=edit";
$url .= "&host_id=$hosts";
$url = "http://$config{$h}{'server'}/dyn/dyndns.php?";
$url .= "hostname=$hosts";
$url .= "&myip=";
$url .= $ip if $ip;
$url .= "&wildcard=" . ynu($config{$h}{'wildcard'}, 'YES', 'NO', 'NO') if defined $config{$h}{'wildcard'};
$url .= "&wildcard=" . ynu($config{$h}{'wildcard'}, 'ON', 'OFF', 'OFF') if defined $config{$h}{'wildcard'};
if ($config{$h}{'mx'}) {
$url .= "&mx=$config{$h}{'mx'}";