Michal Josef Špaček
c747f2737a
Rewrite deprecated use of IO::Socket::INET6 to new solution
...
Module IO::Socket::INET6 is deprecated.
There is common IO::Socket::IP module, which is working with ipv4 and
ipv6 in same way. There is backward compatibility with IO::Socket::INET6
2022-12-08 13:58:21 +01:00
Luca Schöneberg
89e30d0aa8
fix hetzner zone problem
2022-11-21 16:17:08 +01:00
gertfriend
f01110aedb
Add regfish ( #471 )
2022-11-18 08:43:47 +01:00
Sandro Jäckel
3dffe5372a
Format
2022-10-31 00:07:05 +01:00
Sandro Jäckel
e8cc636474
Use https in more places
2022-10-31 00:06:56 +01:00
Sandro Jäckel
36744e5b20
set version number via autoconf
2022-10-25 15:46:33 +02:00
Sandro Jäckel
3e2cb0a0dc
Cut 3.10.0 release
2022-10-20 20:06:35 +02:00
satrapes
c9754a125c
Add support for njal.la ( #459 )
...
Co-authored-by: Dimitris Paraskevopoulos <dpparaskevopoulos@gmail.com>
2022-09-30 14:49:57 +02:00
Thomas Hebb
8a6b9d0862
cloudflare: Remove unused $hostname variable
...
This is no longer used since commit 6c951a0395
("Add files via
upload"), which updated to the Cloudflare API v4. The new API does not
require any preprocessing of the domain name.
2022-09-25 10:22:38 -07:00
pesenise
36b8db950f
Add support for domaindiscount24.com ( #436 )
...
* Update ddclient.in
add Row 526 - 529
add Row 869 - 877
add Row 6992 - 7066
* Update ChangeLog.md
* Update ChangeLog.md
* Update ddclient.in
Co-authored-by: Sandro <sandro.jaeckel@gmail.com>
* Update ChangeLog.md
Co-authored-by: Sandro <sandro.jaeckel@gmail.com>
* Update ChangeLog.md
Co-authored-by: Sandro <sandro.jaeckel@gmail.com>
* Update ddclient.in
Co-authored-by: Sandro <sandro.jaeckel@gmail.com>
* Update ddclient.in
Co-authored-by: Sandro <sandro.jaeckel@gmail.com>
* Update ddclient.in
Co-authored-by: Sandro <sandro.jaeckel@gmail.com>
* Update ddclient.in
Co-authored-by: Sandro <sandro.jaeckel@gmail.com>
* Update ddclient.in
Co-authored-by: Sandro <sandro.jaeckel@gmail.com>
Co-authored-by: Sandro <sandro.jaeckel@gmail.com>
2022-07-30 17:07:10 +02:00
Sandro Jäckel
4201bf3b03
Fix version parsing for real, cut 3.10.0_2
2022-05-16 02:07:49 +02:00
Sandro Jäckel
ca4ce91497
Use numeric only version to fix tests
2022-05-15 23:08:03 +02:00
Sandro Jäckel
6be775dc10
Bump version to 3.10.0rc1
2022-05-15 22:44:51 +02:00
Richard Hansen
251b167d41
New -list-devices
option
...
This will make it possible for the Debian package to fetch the list of
supported firewall/router devices and prompt the user to choose one
upon installation.
2022-05-15 22:28:38 +02:00
Richard Hansen
0ea681645b
New -list-protocols
option
...
This will make it possible for the Debian package to fetch the list of
supported protocols and prompt the user to choose one upon
installation.
2022-05-15 22:28:33 +02:00
Richard Hansen
f5932d8be3
New -list-web-services
option
...
This will make it possible for the Debian package to fetch the list of
supported built-in web-based IP discovery services and prompt the user
to choose one upon installation.
2022-05-15 22:28:26 +02:00
Sandro
833828334e
Merge pull request #413 from oddlama/develop
...
Improve warnings about ddclient.conf permissions. (fixes #348 )
2022-05-15 22:10:17 +02:00
oddlama
327d999ca2
Improve warnings about ddclient.conf permissions. ( fixes #348 )
...
The new code will always warn if ddclient.conf is accessible by others,
warn if it is owned by ddclient and accessible by the group,
and otherwise warn if it is writable but not owned by ddclient.
This primarily allows two permission modes for ddclient.conf:
First, the classic `ddclient:ddclient mode 0600` as well as the
more restrictive `root:ddclient mode 0640` which previously
warned unnecessarily.
2022-05-12 20:34:06 +02:00
Joerg Werner
4a01678030
Add support for hetzner dns console
2022-04-23 17:46:10 +02:00
Awalon
beb7147a39
Added support for GoDaddy DNS zone updates. ( #398 )
2022-04-17 02:35:07 +02:00
Sandro
215d4679e4
Merge pull request #374 from so-lar-is/add-support-for-1984-is
2022-01-24 00:02:33 +01:00
Sandro Jäckel
4f5f0e0efc
Update all http endpoints which support https to that
2022-01-23 23:59:16 +01:00
me@so.lar.is
30778c5451
Add support for 1984.is
2022-01-19 01:48:54 +01:00
Sandro
17160fb016
Merge pull request #343 from zraexy/patch-1
2022-01-13 17:11:34 +01:00
Austin H
3e952e6892
Cloudflare Fix
...
Cloudflare was returning values not being matched properly by the regex expression.
Numbers that were not Headers.
This fix or patch should resolve that issue, by only collecting one match to JSON relevant data.
2021-08-17 11:44:37 -04:00
David Mell
9631575ab4
Update easyDNS endpoint URL
...
Fixes #340
2021-06-29 12:49:12 -08:00
David Mell
ed128a0b99
Fix CloudFlare zone ID endpoint URL
...
Fixes #339
2021-06-29 12:44:59 -08:00
Reuben Thomas
f0270e4940
Add dnsexit support (based on #52 ) ( #311 )
...
* Patch in dnsexit support
Based on patch from here https://sourceforge.net/p/ddclient/discussion/399428/thread/04e23ee6/ hacked back in.
* dnsexit: check for valid responses that mean 'failure' (from @truesalo)
Co-authored-by: sreknob <sreknob@hotmail.com>
2021-05-12 14:45:28 -05:00
David Kerr
b84f2334e4
Redact login and password when printing out internal hash values ( #274 )
...
* Redact login and password when printing out internal hash values
* Remove from debug message in geturl() parameters sent as part of a URL
* Update comment with password redaction
Making it clearer that all parameters are redacted, not just password related ones.
Co-authored-by: DaveSophoServices <dave@sophoservices.com>
2021-05-11 20:26:02 -05:00
David Kerr
24ba945949
IPv6 framework + Cloudflare + FreeDNS ( #291 )
...
* Add basic framework to support IPv6
* Update cloudflare to use new IPv6 framework
* Update FreeDNS to use new IPv6 framework
2021-05-11 20:16:19 -05:00
Mike Chester
9fb2aee4d0
Fix geturl function call for Gandi ( #314 )
...
* Fix geturl function call
The function should be called without the brackets
* Update ci.yml
Removed Cento6 & 8
Co-authored-by: DaveSophoServices <dave@sophoservices.com>
2021-05-11 10:48:44 -05:00
DaveSophoServices
29cfc55581
Merge pull request #324 from krerkkiat/doc-cloudflare-token
...
modify Cloudflare documentation
2021-05-11 10:01:36 -05:00
Sandro Jäckel
9a44eeb826
Use HTTP/1.0, fix #332
2021-05-11 11:47:10 +02:00
Krerkkiat Chusap
db8b6baca9
modify Cloudflare documentation
...
It seems that ddclient check if the login field is equal to "token" to
use the correct header for the API token.
2021-04-05 12:36:45 -04:00
David Kerr
4c76274ba6
Add missing comment block
2020-09-21 15:16:48 -04:00
David Kerr
1b2f45cc59
Add get_default_interface
2020-09-21 15:16:48 -04:00
David Kerr
213cf6ad09
Add get_ip_from_interface function
2020-09-21 15:16:11 -04:00
David Kerr
d1d7548e09
So the bug was actually in the escape_curl_param function, not that the data should not be escaped
2020-08-22 21:32:27 -04:00
David Kerr
6ae64e6cfb
bug fix... segfault when using WWW::Curl::Easy->pushopt() replace with setopt()
2020-08-21 17:28:57 -04:00
David Kerr
4c79c6b607
must not escape the 'data' field sent to servers.
2020-08-21 17:01:13 -04:00
David Kerr
3a73e5e6b4
header_ok() function must accept HTTP versions other than just '1'
2020-08-21 16:59:07 -04:00
David Kerr
cde60432dd
Remove from debug message in geturl() parameters sent as part of a URL
2020-08-12 12:53:59 -04:00
David Kerr
8106b3025f
Add support to use WWW::Curl::Easy if it exists
2020-08-07 11:17:44 -04:00
David Kerr
d24b75960d
Add support for curl and option to not validate SSL certificates for getip from web or firewall
...
Check exists not just length
2020-08-07 11:17:44 -04:00
Richard Hansen
2de6a02f14
New %builtinweb
entries for nsupdate.info
2020-08-04 13:58:51 -04:00
Richard Hansen
c9b6c8b3bf
New %builtinweb
entries for whatismyv6.com
2020-08-04 13:57:07 -04:00
Richard Hansen
ae89dbdfa3
New %builtinweb
entry for Hurricane Electric
2020-08-04 13:54:49 -04:00
Richard Hansen
fb42a50318
New %builtinweb
entry for ZoneEdit
2020-08-04 13:51:26 -04:00
Richard Hansen
460cf2f465
New %builtinweb
entry for FreeDNS
2020-08-04 13:51:26 -04:00
Richard Hansen
1a8bfafb3d
New %builtinweb
entry for Google Domains
2020-08-04 13:51:26 -04:00
Richard Hansen
ad81aa43d2
New %builtinweb
entries for noip.com
2020-08-04 13:51:26 -04:00
Richard Hansen
295ba387aa
Rename ipifyipv{4,6}
to ipify-ipv{4,6}
...
The added dash makes it easier to read.
2020-08-04 13:51:26 -04:00
Richard Hansen
f3a92fbe63
Delete trailing commas
2020-08-04 13:46:21 -04:00
Richard Hansen
deab8970a1
Whitespace fixes
2020-08-04 13:46:21 -04:00
Richard Hansen
601460c0b3
Turn if-skip
into a no-op and mark it as deprecated
...
There is no way the user can meaningfully set `if-skip` because the
user doesn't have control over how ddclient reads an interface's
settings (ddclient could theoretically run `ip addr show`, run
`ifconfig`, read a file in `/dev`, make a system call, use a Perl
library, etc.).
2020-08-03 12:55:38 -04:00
Richard Hansen
686bf5a8c8
Improve -help
text
2020-08-02 23:38:46 -04:00
Richard Hansen
4bf9d59722
Whitespace fixes
2020-08-02 21:52:11 -04:00
David Kerr
1ad4d6737a
Add is_ipv6_global and extract_ipv6_global functions
2020-08-01 19:11:28 -04:00
Richard Hansen
25a636879f
Change the default server for dslreports1
to www.dslreports.com
...
Before, it defaulted to `members.dyndns.org` which didn't make much
sense.
2020-08-01 16:22:38 -04:00
Richard Hansen
f8185182e9
Add new device built-ins (fw=<device>
)
...
Thanks goes to Geoff Simmons, who provided the definitions in
https://bugs.debian.org/589980 .
2020-07-27 12:23:35 -04:00
Sandro
2e1bb5165a
Merge pull request #254 from rhansen/geturl
...
Eliminate unnecessary hashref
2020-07-22 10:56:17 +02:00
Richard Hansen
ae7919fcc4
Mark gandi
protocol's ttl
var as optional
...
Gandi doesn't require a TTL in the update request. The protocol
implementation already does the right thing if the `ttl` var is
`undef`.
2020-07-18 15:05:53 -04:00
Jimmy Thrasibule
7f719dc305
Add support for Gandi LiveDNS
...
Allow update of a DNS record hosted by the Gandi LiveDNS service.
Signed-off-by: Jimmy Thrasibule <jimmy.thrasibule@orange.com>
Reviewed-by: Richard Hansen <rhansen@rhansen.org>
2020-07-18 15:01:52 -04:00
Jimmy Thrasibule
b6a7c44d39
Ensure header_ok accept any 2xx return code
...
Adapt `header_ok` to return success for any HTTP 2xx code.
Signed-off-by: Jimmy Thrasibule <jimmy.thrasibule@orange.com>
Reviewed-by: Richard Hansen <rhansen@rhansen.org>
2020-07-18 15:01:52 -04:00
Richard Hansen
286fe02478
Fix -daemon
command-line argument parsing
...
It turns out the logic removed in
d10601de11
had a purpose after all.
2020-07-14 23:17:19 -04:00
Richard Hansen
7d58f2d749
Import IO::Socket::INET
...
We've always required IO::Socket::INET but never explicitly included
it. For some reason that hasn't been a problem until now.
Fixes #255
2020-07-12 18:58:31 -04:00
Richard Hansen
5f1dacc3bd
Eliminate unnecessary hashref
...
Pass the key-value pairs directly instead of via a hashref.
2020-07-11 21:39:48 -04:00
David Kerr
29202f5bc1
New is_ipv6 and extract_ipv6 algorithms
...
Also add unit tests.
2020-07-11 11:04:47 -04:00
David Kerr
92c1294af9
Accept leading zeros in IPv4 addresses
...
Also add unit tests.
2020-07-11 11:04:33 -04:00
Richard Hansen
dd8e376784
Add geturl
SSL tests
...
These don't test validation, only that IO::Socket::SSL is used.
2020-07-08 13:40:31 -04:00
Richard Hansen
6ff0362450
Get the AF_INET and friends constants from Socket
...
Apparently it is enough to simply import Socket or IO::Socket to use
AF_INET and friends, but all examples in official documentation show
them in the import list. Because I do not fully understand the
intricacies of Perl import logic, I do the same thing here, fully
aware that I might have joined a cargo cult. Regardless of its
correctness or necessity, listing the constants in the import list has
the advantage of making it clear why the `use` statement exists.
I chose to import the constants from Socket instead of IO::Socket
because that module's documentation explicitly documents the
constants.
2020-07-07 20:55:32 -04:00
Sandro
ee4191f865
Merge pull request #225 from reetp/master
...
Add DinaHosting
2020-07-07 10:15:32 +02:00
Sandro
f0c583890a
Merge pull request #246 from rhansen/unwrap
...
Unwrap unnecessarily wrapped lines
2020-07-07 10:11:37 +02:00
Sandro
b0b04aa278
Merge pull request #247 from rhansen/parse_assignments
...
Simplify `parse_assignments`
2020-07-07 10:11:21 +02:00
Sandro
eac5d25e47
Merge pull request #245 from rhansen/continue-on-failure
...
Don't skip updates to remaining hosts if one host fails
2020-07-07 10:10:42 +02:00
Sandro
9d7af91bf4
Merge pull request #242 from rhansen/mkdir-var-cache
2020-07-07 10:09:47 +02:00
Sandro
666fc293fb
Merge pull request #243 from rhansen/delete-fw-debug
...
Delete out-of-place debug messages
2020-07-07 10:08:49 +02:00
Richard Hansen
71acd749a1
Simplify parse_assignments
2020-07-07 00:10:33 -04:00
Richard Hansen
c3de24bb49
Unwrap unnecessarily wrapped lines
2020-07-07 00:09:44 -04:00
Richard Hansen
bdf8835904
Don't skip updates to remaining hosts if one host fails
2020-07-07 00:08:56 -04:00
Richard Hansen
ee8e1e8844
Don't abort if unable to write the cache file
2020-07-07 00:04:33 -04:00
Richard Hansen
6ae5fe62d7
Create /var/cache/ddclient
if it doesn't exist
...
Fixes #76
2020-07-07 00:04:33 -04:00
Richard Hansen
df3c777e11
Delete out-of-place debug messages
...
Neither `opt('fw')` nor `$globals{'fw'}` are used in `geturl` so
delete the debug messages showing their values.
2020-07-07 00:03:56 -04:00
John Crisp
e2c3f9dd04
Add support for dinahosting
...
Fixes #203
2020-07-07 00:00:45 -04:00
Richard Hansen
231306395a
Test for definedness or emptiness, not truthiness
...
Use `//` or `eq ''` for tests to avoid treating the string `'0'` as
false.
2020-07-06 23:58:51 -04:00
Richard Hansen
03dffae74e
Honor the ssl
option for the web
URL
2020-07-06 20:20:01 -04:00
Richard Hansen
7921c53605
Explicitly tell geturl
to ignore the global ssl
option
...
Changing behavior based on the identity of the caller is fragile and
makes the code difficult to understand.
2020-07-06 20:19:27 -04:00
Richard Hansen
2e5db5af44
Fix detection of get_ip
caller
...
This was broken in f6f920eb39
.
2020-07-06 17:14:08 -04:00
Sandro Jäckel
b7e7d27a24
Remove dtdns
2020-07-06 15:59:55 +02:00
Sandro Jäckel
12a4a10c9c
Remove hammernode1
2020-07-06 15:57:52 +02:00
Richard Hansen
323208e9cc
Add geturl
connectivity unit tests
...
Addresses #232
2020-07-05 18:36:46 -04:00
Sandro
b6770a4d9f
Merge pull request #234 from rhansen/url-parsing
...
Fix URL parsing for IPv6 URLs and pathless URLs
2020-07-06 00:33:22 +02:00
Richard Hansen
06503a483b
Fix URL parsing for IPv6 URLs and pathless URLs
...
Now the following valid URLs are parsed correctly:
* http://[::1]:123/foo
* http://localhost?foo=bar
There are still problems with the URL parsing logic but this is enough
to write some unit tests.
2020-07-05 18:21:35 -04:00
Richard Hansen
49c8717420
Silence warning when calling geturl
from an anonymous sub
2020-07-05 18:16:08 -04:00
Richard Hansen
a15cec7cd9
Stringify default port numbers
...
The IO::Socket classes expect strings for the port number because you
can pass service names from `/etc/services`. Numbers work too, but
using strings everywhere makes it easier to write unit tests.
2020-07-05 16:32:41 -04:00
David Kerr
52fdb0bdeb
add missing semicolons and fix incorrect debug message
2020-07-03 17:32:27 -04:00
Sandro
d844039e6c
Merge pull request #175 from rhansen/config-file-parse
...
Improve parsing of config file assignments
2020-07-03 23:24:55 +02:00
Richard Hansen
f7ff1f8259
New options to specify CA certificate location
...
This is a prerequisite to adding `geturl()` unit tests (we will need
to run a dummy https server).
2020-07-03 16:59:18 -04:00
Richard Hansen
6d7d248f79
Improve parsing of config file assignments
...
* Ignore empty `key=value` strings in variable assignments. Now the
following lines are supported with the expected meaning:
* `a=1 , b=2`
* `a=1,,b=2`
* Improve the warning message when there is an unterminated quote.
* Add a warning if the line ends with a backslash.
Also add unit tests.
2020-07-03 16:56:01 -04:00
Richard Hansen
283f609b28
Update Vim modeline and Emacs file-local variables
...
Both:
* Force the file type to Perl
* Set the tab width to 8 so that people cringe in horror at the
sight of a tab
* Set the line with to 99
Emacs:
* Disable indent-tabs-mode
* Set the indentation level to 4
Vim:
* Highlight column 100
Addresses #206
2020-07-01 22:52:29 -04:00
Richard Hansen
8ed93cb576
Move per-service variables to the service definitions
...
Most of the entries in `%variables` are only used once. Move them down
to their respective service definitions.
Also:
* Use idiomatic hash merging instead of `merge()`.
* Sort the variables by name.
2020-06-30 22:14:15 -04:00
Richard Hansen
7a2d065a2d
Fix woima protocol implementation for
loop
2020-06-30 18:41:40 -04:00
Richard Hansen
ccc876c160
Remove the /a
regex flag
...
This flag was added in Perl 5.14 so we can't use it.
2020-06-30 18:34:41 -04:00
David Kerr
36d8b511b3
Move un_zero_pad
into extract_ipv4
, extract_ipv6
...
This also causes `is_ipv4` to reject IPv4 addresses with leading
zeros.
2020-06-30 15:44:24 -04:00
David Kerr
0a999577c7
Simplify the IPv4 regular expression
2020-06-30 15:43:07 -04:00
David Kerr
5da22a8a69
Implement is_ipv6
in terms of extract_ivp6
2020-06-30 15:26:40 -04:00
David Kerr
ab0a4597ce
Validate the ip
setting
2020-06-30 15:22:13 -04:00
David Kerr
fe513f733d
Use is_ipv6
, not extract_ipv6
, to validate IPv6 address
2020-06-30 15:19:38 -04:00
David Kerr
af1332264f
Delete unnecessary address check
...
`get_ip` is guaranteed to return a valid IP address or `undef`.
2020-06-30 15:16:55 -04:00
Richard Hansen
44eaf653f1
Rename *.template
to *.in
...
Apparently the `.template` extension is commonly used in macOS for a
word processor template file.
See issue #206 .
2020-06-30 13:27:08 -04:00