From: <abe...@us...> - 2017-01-29 16:20:54
|
Revision: 8134 http://sourceforge.net/p/astlinux/code/8134 Author: abelbeck Date: 2017-01-29 16:20:52 +0000 (Sun, 29 Jan 2017) Log Message: ----------- ddclient, add index to patch name Added Paths: ----------- branches/1.0/package/ddclient/ddclient-0001-upstream-HE-warning-messages.patch Removed Paths: ------------- branches/1.0/package/ddclient/ddclient-upstream-HE-warning-messages.patch Copied: branches/1.0/package/ddclient/ddclient-0001-upstream-HE-warning-messages.patch (from rev 8133, branches/1.0/package/ddclient/ddclient-upstream-HE-warning-messages.patch) =================================================================== --- branches/1.0/package/ddclient/ddclient-0001-upstream-HE-warning-messages.patch (rev 0) +++ branches/1.0/package/ddclient/ddclient-0001-upstream-HE-warning-messages.patch 2017-01-29 16:20:52 UTC (rev 8134) @@ -0,0 +1,31 @@ +diff --git a/ddclient b/ddclient +index 2b7599a..7e1eb89 100755 +--- a/ddclient ++++ b/ddclient +@@ -4580,7 +4580,7 @@ sub nic_he_update { + 'interval' => 'The update interval has been exceeded, wait and try again later', + 'noipv4' => 'No DNS "A" record exists, add one and make it dynamic', + 'noipv6' => 'No DNS "AAAA" record exists, add one and make it dynamic', +- 'nochg' => 'No update required; unnecessary attempts to change to the current address are considered abusive', ++ 'nochg' => 'Unnecessary update attempts are considered abusive', + ); + + ## update each set of hosts that had similar configurations +@@ -4624,7 +4624,7 @@ sub nic_he_update { + + } elsif (exists $errors{$status}) { + if (($status eq 'nochg') || ($status eq 'interval')) { +- warning("updating %s: %s: %s", $host, $status, $errors{$status}); ++ warning("updating %s: No DNS 'A' record update required; %s", $host, $errors{$status}); + $config{$host}{'ip'} = $ip; + $config{$host}{'mtime'} = $now; + $config{$host}{'status'} = 'good'; +@@ -4669,7 +4669,7 @@ sub nic_he_update { + + } elsif (exists $errors{$status}) { + if (($status eq 'nochg') || ($status eq 'interval')) { +- warning("updating %s: %s: %s", $host, $status, $errors{$status}); ++ warning("updating %s: No DNS 'AAAA' record update required; %s", $host, $errors{$status}); + $config{$host}{'ipv6'} = $ipv6; + $config{$host}{'mtime'} = $now; + $config{$host}{'status'} = 'good'; Deleted: branches/1.0/package/ddclient/ddclient-upstream-HE-warning-messages.patch =================================================================== --- branches/1.0/package/ddclient/ddclient-upstream-HE-warning-messages.patch 2017-01-29 16:18:04 UTC (rev 8133) +++ branches/1.0/package/ddclient/ddclient-upstream-HE-warning-messages.patch 2017-01-29 16:20:52 UTC (rev 8134) @@ -1,31 +0,0 @@ -diff --git a/ddclient b/ddclient -index 2b7599a..7e1eb89 100755 ---- a/ddclient -+++ b/ddclient -@@ -4580,7 +4580,7 @@ sub nic_he_update { - 'interval' => 'The update interval has been exceeded, wait and try again later', - 'noipv4' => 'No DNS "A" record exists, add one and make it dynamic', - 'noipv6' => 'No DNS "AAAA" record exists, add one and make it dynamic', -- 'nochg' => 'No update required; unnecessary attempts to change to the current address are considered abusive', -+ 'nochg' => 'Unnecessary update attempts are considered abusive', - ); - - ## update each set of hosts that had similar configurations -@@ -4624,7 +4624,7 @@ sub nic_he_update { - - } elsif (exists $errors{$status}) { - if (($status eq 'nochg') || ($status eq 'interval')) { -- warning("updating %s: %s: %s", $host, $status, $errors{$status}); -+ warning("updating %s: No DNS 'A' record update required; %s", $host, $errors{$status}); - $config{$host}{'ip'} = $ip; - $config{$host}{'mtime'} = $now; - $config{$host}{'status'} = 'good'; -@@ -4669,7 +4669,7 @@ sub nic_he_update { - - } elsif (exists $errors{$status}) { - if (($status eq 'nochg') || ($status eq 'interval')) { -- warning("updating %s: %s: %s", $host, $status, $errors{$status}); -+ warning("updating %s: No DNS 'AAAA' record update required; %s", $host, $errors{$status}); - $config{$host}{'ipv6'} = $ipv6; - $config{$host}{'mtime'} = $now; - $config{$host}{'status'} = 'good'; This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <abe...@us...> - 2017-05-05 12:58:25
|
Revision: 8287 http://sourceforge.net/p/astlinux/code/8287 Author: abelbeck Date: 2017-05-05 12:58:22 +0000 (Fri, 05 May 2017) Log Message: ----------- ddclient-curl, version bump to 3.8.3-03 Modified Paths: -------------- branches/1.0/package/ddclient/ddclient.mk Removed Paths: ------------- branches/1.0/package/ddclient/ddclient-0001-upstream-4da69be-549bcb6.patch Deleted: branches/1.0/package/ddclient/ddclient-0001-upstream-4da69be-549bcb6.patch =================================================================== --- branches/1.0/package/ddclient/ddclient-0001-upstream-4da69be-549bcb6.patch 2017-05-01 19:19:16 UTC (rev 8286) +++ branches/1.0/package/ddclient/ddclient-0001-upstream-4da69be-549bcb6.patch 2017-05-05 12:58:22 UTC (rev 8287) @@ -1,232 +0,0 @@ -From 4da69be41f1d5bf64b8e3d1fad66c9da86fac837 Mon Sep 17 00:00:00 2001 -From: David Kerr <da...@ke...> -Date: Sat, 22 Apr 2017 10:20:43 -0400 -Subject: [PATCH 1/2] Record update status of IPv6 separate from IPv4 (ie, - don't use same variable for both). - ---- - ddclient | 18 ++++++++++-------- - 1 file changed, 10 insertions(+), 8 deletions(-) - -diff --git a/ddclient b/ddclient -index cfd6f6a..443b4e9 100755 ---- a/ddclient -+++ b/ddclient -@@ -416,6 +416,7 @@ my %variables = ( - 'mtime' => setv(T_NUMBER, 0, 1, 0, 0, undef), - 'atime' => setv(T_NUMBER, 0, 1, 0, 0, undef), - 'status' => setv(T_ANY, 0, 1, 0, '', undef), -+ 'status-ipv6' => setv(T_ANY, 0, 1, 0, '', undef), - 'min-interval' => setv(T_DELAY, 0, 0, 1, interval('30s'), 0), - 'max-interval' => setv(T_DELAY, 0, 0, 1, interval('25d'), 0), - 'min-error-interval' => setv(T_DELAY, 0, 0, 1, interval('5m'), 0), -@@ -2478,7 +2479,7 @@ sub nic_updateable { - - } elsif ((defined($config{$host}{'usev6'}) && ($config{$host}{'usev6'} ne 'no') ) && - ((!exists($cache{$host}{'ipv6'})) || ("$cache{$host}{'ipv6'}" ne "$ipv6"))) { -- if (($cache{$host}{'status'} eq 'good') && -+ if (($cache{$host}{'status-ipv6'} eq 'good') && - !interval_expired($host, 'mtime', 'min-interval')) { - warning("skipping update of %s from %s to %s.\nlast updated %s.\nWait at least %s between update attempts.", - $host, -@@ -2490,7 +2491,7 @@ sub nic_updateable { - if opt('verbose') || !define($cache{$host}{'warned-min-interval'}, 0); - $cache{$host}{'warned-min-interval'} = $now; - -- } elsif (($cache{$host}{'status'} ne 'good') && !interval_expired($host, 'atime', 'min-error-interval')) { -+ } elsif (($cache{$host}{'status-ipv6'} ne 'good') && !interval_expired($host, 'atime', 'min-error-interval')) { - warning("skipping update of %s from %s to %s.\nlast updated %s but last attempt on %s failed.\nWait at least %s between update attempts.", - $host, - ($cache{$host}{'ipv6'} ? $cache{$host}{'ipv6'} : '<nothing>'), -@@ -2530,6 +2531,7 @@ sub nic_updateable { - } - } - $config{$host}{'status'} = define($cache{$host}{'status'},''); -+ $config{$host}{'status-ipv6'} = define($cache{$host}{'status-ipv6'},''); - $config{$host}{'update'} = $update; - if ($update) { - $config{$host}{'status'} = 'noconnect'; -@@ -3855,7 +3857,7 @@ sub nic_freedns_update { - if($ipv6 eq $freedns_hosts_ipv6{$h}->[1]) { - $config{$h}{'ipv6'} = $ipv6; - $config{$h}{'mtime'} = $now; -- $config{$h}{'status'} = 'good'; -+ $config{$h}{'status-ipv6'} = 'good'; - success("update not necessary %s: good: IPv6 address already set to %s", $h, $ipv6); - } else { - debug("Update: %s", $freedns_hosts_ipv6{$h}->[2]."&address=".$ipv6); -@@ -3868,10 +3870,10 @@ sub nic_freedns_update { - if($reply =~ /Updated.*$h.*to.*$ipv6/) { - $config{$h}{'ipv6'} = $ipv6; - $config{$h}{'mtime'} = $now; -- $config{$h}{'status'} = 'good'; -+ $config{$h}{'status-ipv6'} = 'good'; - success("updating %s: good: IPv6 address set to %s", $h, $ipv6); - } else { -- $config{$h}{'status'} = 'failed'; -+ $config{$h}{'status-ipv6'} = 'failed'; - warning("SENT: %s", $freedns_hosts_ipv6{$h}->[2]) unless opt('verbose'); - warning("REPLIED: %s", $reply); - failed("updating %s: Invalid reply.", $h); -@@ -4441,7 +4443,7 @@ sub nic_cloudflare_update { - # Cache - $config{$key}{'ipv6'} = $ipv6; - $config{$key}{'mtime'} = $now; -- $config{$key}{'status'} = 'good'; -+ $config{$key}{'status-ipv6'} = 'good'; - } - } - } -@@ -4654,7 +4656,7 @@ sub nic_he_update { - foreach my $line (@reply) { - my ($status, $ipv6_ignore) = split / /, lc $line; - -- $config{$host}{'status'} = $status; -+ $config{$host}{'status-ipv6'} = $status; - if ($status eq 'good') { - success("updating %s: IPv6 address set to %s", $host, $ipv6); - $config{$host}{'ipv6'} = $ipv6; -@@ -4665,7 +4667,7 @@ sub nic_he_update { - warning("updating %s: No DNS 'AAAA' record update required; %s", $host, $errors{$status}); - $config{$host}{'ipv6'} = $ipv6; - $config{$host}{'mtime'} = $now; -- $config{$host}{'status'} = 'good'; -+ $config{$host}{'status-ipv6'} = 'good'; - - } else { - failed("updating %s: %s: %s", $host, $status, $errors{$status}); - -From 549bcb66f2c3eb9f3a52445f6d11d0c37e0e55dd Mon Sep 17 00:00:00 2001 -From: David Kerr <da...@ke...> -Date: Sat, 22 Apr 2017 10:22:44 -0400 -Subject: [PATCH 2/2] Add command line option "-max-warn" to configure the - maximum number of times a warning message should be logged. When in daemon - mode and an IP address is not found for some reason (e.g. using a cmd to - query a host and that host has gone offline) ddclient would fill up syslog - with the same warning every couple of minutes. We now default to logging the - message only once but you can specify number of times you would like it - logged with e.g. "-max-warn 9" which would log the warning 9 times (you can - specify any number). - ---- - ddclient | 65 ++++++++++++++++++++++++++++++++++++++++++---------------------- - 1 file changed, 43 insertions(+), 22 deletions(-) - -diff --git a/ddclient b/ddclient -index 443b4e9..ea1d50d 100755 ---- a/ddclient -+++ b/ddclient -@@ -734,6 +734,7 @@ my @opt = ( - [ "retry", "!", "-{no}retry : retry failed updates." ], - [ "force", "!", "-{no}force : force an update even if the update may be unnecessary" ], - [ "timeout", "=i", "-timeout max : wait at most 'max' seconds for the host to respond" ], -+ [ "max-warn", "=i", "-max-warn max : maximum nubmer of warning messages for undefined IP address" ], - - [ "syslog", "!", "-{no}syslog : log messages to syslog" ], - [ "facility", "=s", "-facility {type} : log messages to syslog to facility {type}" ], -@@ -763,6 +764,8 @@ my ($result, %config, %globals, %cache); - my $saved_cache = ''; - my %saved_opt = %opt; - $result = 'OK'; -+my (%warned_ipv4, %warned_ipv6); -+my $inv_ip_warn_count = define(opt('max-warn'),1); - - test_geturl(opt('geturl')) if opt('geturl'); - -@@ -2415,6 +2418,14 @@ sub nic_updateable { - my $ip = $config{$host}{'wantip'}; - my $ipv6 = $config{$host}{'wantipv6'}; - -+ if (defined($config{$host}{'use'}) && ($config{$host}{'use'} ne 'no') && define($ipv6,0) && define($warned_ipv6{$host},0) ) { -+ $warned_ipv6{$host} = 0; -+ warning("IPv6 address for %s valid: %s. Reset warning count", $host, $ipv6); -+ } -+ if (defined($config{$host}{'usev6'}) && ($config{$host}{'usev6'} ne 'no') && define($ip,0) && define($warned_ipv4{$host},0) ) { -+ $warned_ipv4{$host} = 0; -+ warning("IP address for %s valid: %s. Reset warning count", $host, $ip); -+ } - if ($config{$host}{'login'} eq '') { - warning("null login name specified for host %s.", $host); - -@@ -2462,16 +2473,21 @@ sub nic_updateable { - - } elsif (($cache{$host}{'status'} ne 'good') && !interval_expired($host, 'atime', 'min-error-interval')) { - -- warning("skipping update of %s from %s to %s.\nlast updated %s but last attempt on %s failed.\nWait at least %s between update attempts.", -- $host, -- ($cache{$host}{'ip'} ? $cache{$host}{'ip'} : '<nothing>'), -- $ip, -- ($cache{$host}{'mtime'} ? prettytime($cache{$host}{'mtime'}) : '<never>'), -- ($cache{$host}{'atime'} ? prettytime($cache{$host}{'atime'}) : '<never>'), -- prettyinterval($config{$host}{'min-error-interval'}) -- ) -- if opt('verbose') || !define($cache{$host}{'warned-min-error-interval'}, 0); -- $cache{$host}{'warned-min-error-interval'} = $now; -+ if (opt('verbose') || (!define($cache{$host}{'warned-min-error-interval'}, 0) && (define($warned_ipv4{$host}, 0) < $inv_ip_warn_count) )) { -+ warning("skipping update of %s from %s to %s.\nlast updated %s but last attempt on %s failed.\nWait at least %s between update attempts.", -+ $host, -+ ($cache{$host}{'ip'} ? $cache{$host}{'ip'} : '<nothing>'), -+ $ip, -+ ($cache{$host}{'mtime'} ? prettytime($cache{$host}{'mtime'}) : '<never>'), -+ ($cache{$host}{'atime'} ? prettytime($cache{$host}{'atime'}) : '<never>'), -+ prettyinterval($config{$host}{'min-error-interval'}) -+ ); -+ if (!define($ip,0) && !opt('verbose')) { -+ $warned_ipv4{$host} = define($warned_ipv4{$host}, 0) + 1; -+ warning ("IP address for %s undefined. Warned %s times, suppressing further warnings", $host, $inv_ip_warn_count) if ($warned_ipv4{$host} >= $inv_ip_warn_count); -+ } -+ } -+ $cache{$host}{'warned-min-error-interval'} = $now; - - } else { - $update = 1; -@@ -2492,16 +2508,21 @@ sub nic_updateable { - $cache{$host}{'warned-min-interval'} = $now; - - } elsif (($cache{$host}{'status-ipv6'} ne 'good') && !interval_expired($host, 'atime', 'min-error-interval')) { -- warning("skipping update of %s from %s to %s.\nlast updated %s but last attempt on %s failed.\nWait at least %s between update attempts.", -- $host, -- ($cache{$host}{'ipv6'} ? $cache{$host}{'ipv6'} : '<nothing>'), -- $ipv6, -- ($cache{$host}{'mtime'} ? prettytime($cache{$host}{'mtime'}) : '<never>'), -- ($cache{$host}{'atime'} ? prettytime($cache{$host}{'atime'}) : '<never>'), -- prettyinterval($config{$host}{'min-error-interval'}) -- ) -- if opt('verbose') || !define($cache{$host}{'warned-min-error-interval'}, 0); -- $cache{$host}{'warned-min-error-interval'} = $now; -+ if (opt('verbose') || (!define($cache{$host}{'warned-min-error-interval'}, 0) && (define($warned_ipv6{$host}, 0) < $inv_ip_warn_count) )) { -+ warning("skipping update of %s from %s to %s.\nlast updated %s but last attempt on %s failed.\nWait at least %s between update attempts.", -+ $host, -+ ($cache{$host}{'ipv6'} ? $cache{$host}{'ipv6'} : '<nothing>'), -+ $ipv6, -+ ($cache{$host}{'mtime'} ? prettytime($cache{$host}{'mtime'}) : '<never>'), -+ ($cache{$host}{'atime'} ? prettytime($cache{$host}{'atime'}) : '<never>'), -+ prettyinterval($config{$host}{'min-error-interval'}) -+ ); -+ if (!define($ipv6,0) && !opt('verbose')) { -+ $warned_ipv6{$host} = define($warned_ipv6{$host}, 0) + 1; -+ warning ("IPv6 address for %s undefined. Warned %s times, suppressing further warnings", $host, $inv_ip_warn_count) if ($warned_ipv6{$host} >= $inv_ip_warn_count); -+ } -+ } -+ $cache{$host}{'warned-min-error-interval'} = $now; - - } else { - $update = 1; -@@ -3825,7 +3846,7 @@ sub nic_freedns_update { - $config{$h}{'ip'} = $ip; - $config{$h}{'mtime'} = $now; - $config{$h}{'status'} = 'good'; -- success("update not necessary %s: good: IPv4 address already set to %s", $h, $ip); -+ success("update not necessary %s: good: IPv4 address already set to %s", $h, $ip) if (!$daemon || opt('verbose')); - } else { - debug("Update: %s", $freedns_hosts{$h}->[2]."&address=".$ip); - my $reply = geturl(opt('proxy'), $freedns_hosts{$h}->[2]."&address=".$ip); -@@ -3858,7 +3879,7 @@ sub nic_freedns_update { - $config{$h}{'ipv6'} = $ipv6; - $config{$h}{'mtime'} = $now; - $config{$h}{'status-ipv6'} = 'good'; -- success("update not necessary %s: good: IPv6 address already set to %s", $h, $ipv6); -+ success("update not necessary %s: good: IPv6 address already set to %s", $h, $ipv6) if (!$daemon || opt('verbose')); - } else { - debug("Update: %s", $freedns_hosts_ipv6{$h}->[2]."&address=".$ipv6); - my $reply = geturl(opt('proxy'), $freedns_hosts_ipv6{$h}->[2]."&address=".$ipv6); Modified: branches/1.0/package/ddclient/ddclient.mk =================================================================== --- branches/1.0/package/ddclient/ddclient.mk 2017-05-01 19:19:16 UTC (rev 8286) +++ branches/1.0/package/ddclient/ddclient.mk 2017-05-05 12:58:22 UTC (rev 8287) @@ -3,7 +3,7 @@ # ddclient # ############################################################# -DDCLIENT_VERSION = 3.8.3-02 +DDCLIENT_VERSION = 3.8.3-03 DDCLIENT_SOURCE = ddclient-curl-$(DDCLIENT_VERSION).tar.gz DDCLIENT_SITE = https://github.com/astlinux-project/ddclient-curl/releases/download/$(DDCLIENT_VERSION) This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <abe...@us...> - 2017-08-12 18:11:35
|
Revision: 8479 http://sourceforge.net/p/astlinux/code/8479 Author: abelbeck Date: 2017-08-12 18:11:32 +0000 (Sat, 12 Aug 2017) Log Message: ----------- ddclient, version bump to ddclient-curl 3.8.3-05, add DuckDNS support, web interface support to follow Modified Paths: -------------- branches/1.0/package/ddclient/ddclient.conf branches/1.0/package/ddclient/ddclient.mk Removed Paths: ------------- branches/1.0/package/ddclient/ddclient-0001-upstream-add-ipv6-address-type-selector.patch Deleted: branches/1.0/package/ddclient/ddclient-0001-upstream-add-ipv6-address-type-selector.patch =================================================================== --- branches/1.0/package/ddclient/ddclient-0001-upstream-add-ipv6-address-type-selector.patch 2017-08-12 12:55:43 UTC (rev 8478) +++ branches/1.0/package/ddclient/ddclient-0001-upstream-add-ipv6-address-type-selector.patch 2017-08-12 18:11:32 UTC (rev 8479) @@ -1,176 +0,0 @@ -From e1b846ed6058b292766d5f94df6bfb62b2fb4a49 Mon Sep 17 00:00:00 2001 -From: Lonnie Abelbeck <lo...@ab...> -Date: Tue, 6 Jun 2017 13:08:57 -0500 -Subject: [PATCH] get-ipv6-from-ipv4.pl, add optional options: gua, ula, lla or - all. Defaults to: gua - ---- - contrib/get-ipv6-from-ipv4/get-ipv6-from-ipv4.pl | 97 +++++++++++++++++++----- - 1 file changed, 76 insertions(+), 21 deletions(-) - -diff --git a/contrib/get-ipv6-from-ipv4/get-ipv6-from-ipv4.pl b/contrib/get-ipv6-from-ipv4/get-ipv6-from-ipv4.pl -index fc6209b..32781b9 100644 ---- a/contrib/get-ipv6-from-ipv4/get-ipv6-from-ipv4.pl -+++ b/contrib/get-ipv6-from-ipv4/get-ipv6-from-ipv4.pl -@@ -3,7 +3,7 @@ - ## - ## Get IPv6 global address given it's IPv4 address or hostname - ## --## Usage: get-ipv6-from-ipv4 address|hostname -+## Usage: get-ipv6-from-ipv4 address|hostname [gua|ula|lla|all] - ## - ## Return IPv6 global address in stdout - ## -@@ -13,8 +13,10 @@ - - my $hostv4 = $ARGV[0]; - -+my $type = $ARGV[1]; -+ - sub usage { -- print STDERR "Usage: get-ipv6-from-ipv4 address|hostname\n"; -+ print STDERR "Usage: get-ipv6-from-ipv4 address|hostname [gua|ula|lla|all]\n"; - exit 1; - } - -@@ -28,6 +30,10 @@ sub error { - usage; - } - -+if (!defined $type || ($type ne 'ula' && $type ne 'lla' && $type ne 'all')) { -+ $type = 'gua'; -+} -+ - # Add hostv4 entry to ARP table - `fping -c 1 $hostv4 >/dev/null 2>&1`; - -@@ -41,9 +47,29 @@ sub error { - error "No entry in ARP table for host: $hostv4"; - } - -+my $gua_srcv6; -+my $ula_srcv6; -+my $srcv6; -+my $ipv6; - my $ip_cmd = `ip -6 -o addr show dev $int scope global 2>/dev/null`; -- --my $srcv6 = $1 if $ip_cmd =~ /^.*? inet6 ([0-9a-fA-F:]+)\//s; -+my @lines = split('\n', $ip_cmd); -+foreach my $line (@lines) { -+ if ($line =~ /^.* inet6 ([0-9a-fA-F:]+)\//) { -+ $ipv6 = $1; -+ if ($ipv6 =~ /^fd/i) { -+ $ula_srcv6 = $ipv6 if !defined $ula_srcv6; -+ } else { -+ $gua_srcv6 = $ipv6 if !defined $gua_srcv6; -+ } -+ } -+} -+if ($type eq 'ula') { -+ $srcv6 = $gua_srcv6 if defined $gua_srcv6; -+ $srcv6 = $ula_srcv6 if defined $ula_srcv6; -+} else { -+ $srcv6 = $ula_srcv6 if defined $ula_srcv6; -+ $srcv6 = $gua_srcv6 if defined $gua_srcv6; -+} - - if (!defined $srcv6) { - error "No IPv6 global address for interface: $int"; -@@ -56,51 +82,80 @@ sub error { - sleep 5; - - # Output the first IPv6 global address matching the MAC address --my $llhostv6; --my $hostv6; -+my $gua_hostv6; -+my $ula_hostv6; -+my $lla_hostv6; - $ip_cmd = `ip -6 neigh show dev $int`; --my @lines = split('\n', $ip_cmd); -+@lines = split('\n', $ip_cmd); - foreach my $line (@lines) { - if ($line =~ /^fe80::/i) { - if ($line =~ /^([0-9a-f:]+) .*lladdr ${mac}/i) { -- $llhostv6 = $1; -+ $lla_hostv6 = $1 if !defined $lla_hostv6; - } - } else { - if ($line =~ /^([0-9a-f:]+) .*lladdr ${mac}/i) { -- $hostv6 = $1; -- last; -+ $ipv6 = $1; -+ if ($ipv6 =~ /^fd/i) { -+ $ula_hostv6 = $ipv6 if !defined $ula_hostv6; -+ } else { -+ $gua_hostv6 = $ipv6 if !defined $gua_hostv6; -+ } - } - } - } --if (defined $hostv6) { -- print "$hostv6\n"; -+if (defined $gua_hostv6 && $type eq 'gua') { -+ print "$gua_hostv6\n"; -+ exit 0; -+} elsif (defined $ula_hostv6 && $type eq 'ula') { -+ print "$ula_hostv6\n"; - exit 0; --} elsif (!defined $llhostv6) { -+} elsif (defined $lla_hostv6 && $type eq 'lla') { -+ print "$lla_hostv6\n"; -+ exit 0; -+} -+if (!defined $lla_hostv6) { - exit 1; - } - - # Generate the IPv6 EUI-64 format from the prefix and link-local host - my @p = split(':', $srcv6); --my @h = split(':', $llhostv6); --$hostv6 = join(':', $p[0], $p[1], $p[2], $p[3], $h[$#h-3], $h[$#h-2], $h[$#h-1], $h[$#h]); -+my @h = split(':', $lla_hostv6); -+$ipv6 = join(':', $p[0], $p[1], $p[2], $p[3], $h[$#h-3], $h[$#h-2], $h[$#h-1], $h[$#h]); - - # Try again with the IPv6 EUI-64 format --`fping6 -I $int -c 2 -S $srcv6 $hostv6 >/dev/null 2>&1`; -+`fping6 -I $int -c 2 -S $srcv6 $ipv6 >/dev/null 2>&1`; - - # Wait for Neighbor Discovery to settle - sleep 1; - - # Output the first IPv6 global address matching the MAC address --undef $hostv6; -+undef $gua_hostv6; -+undef $ula_hostv6; - $ip_cmd = `ip -6 neigh show dev $int`; - @lines = split('\n', $ip_cmd); - foreach my $line (@lines) { - if (!($line =~ /^fe80::/i)) { - if ($line =~ /^([0-9a-f:]+) .*lladdr ${mac}/i) { -- $hostv6 = $1; -- last; -+ $ipv6 = $1; -+ if ($ipv6 =~ /^fd/i) { -+ $ula_hostv6 = $ipv6 if !defined $ula_hostv6; -+ } else { -+ $gua_hostv6 = $ipv6 if !defined $gua_hostv6; -+ } - } - } - } --print "$hostv6\n" if defined $hostv6; --exit 0; -+if ($type eq 'all') { -+ print "$gua_hostv6\n" if defined $gua_hostv6; -+ print "$ula_hostv6\n" if defined $ula_hostv6; -+ print "$lla_hostv6\n" if defined $lla_hostv6; -+ exit 0; -+} -+if (defined $gua_hostv6 && $type eq 'gua') { -+ print "$gua_hostv6\n"; -+ exit 0; -+} elsif (defined $ula_hostv6 && $type eq 'ula') { -+ print "$ula_hostv6\n"; -+ exit 0; -+} -+exit 1; Modified: branches/1.0/package/ddclient/ddclient.conf =================================================================== --- branches/1.0/package/ddclient/ddclient.conf 2017-08-12 12:55:43 UTC (rev 8478) +++ branches/1.0/package/ddclient/ddclient.conf 2017-08-12 18:11:32 UTC (rev 8479) @@ -130,4 +130,10 @@ #@he@>login=@DDUSER@ #@he@>password=@DDPASS@ #@he@>@DDHOST@ +#@duckdns@> +#@duckdns@>## DuckDNS +#@duckdns@>ssl=yes +#@duckdns@>protocol=duckdns +#@duckdns@>password=@DDPASS@ +#@duckdns@>@DDHOST@ Modified: branches/1.0/package/ddclient/ddclient.mk =================================================================== --- branches/1.0/package/ddclient/ddclient.mk 2017-08-12 12:55:43 UTC (rev 8478) +++ branches/1.0/package/ddclient/ddclient.mk 2017-08-12 18:11:32 UTC (rev 8479) @@ -3,7 +3,7 @@ # ddclient # ############################################################# -DDCLIENT_VERSION = 3.8.3-03 +DDCLIENT_VERSION = 3.8.3-05 DDCLIENT_SOURCE = ddclient-curl-$(DDCLIENT_VERSION).tar.gz DDCLIENT_SITE = https://github.com/astlinux-project/ddclient-curl/releases/download/$(DDCLIENT_VERSION) This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |