domeneshop: Honor http: or https: scheme in server variable

This commit is contained in:
Richard Hansen 2024-07-13 18:10:59 -04:00
parent c31668b413
commit 6fbb7eb3dc
2 changed files with 4 additions and 11 deletions

View file

@ -62,9 +62,9 @@ repository history](https://github.com/ddclient/ddclient/commits/master).
address changes. [#654](https://github.com/ddclient/ddclient/pull/654) address changes. [#654](https://github.com/ddclient/ddclient/pull/654)
* `he.net`: Added support for updating Hurricane Electric records. * `he.net`: Added support for updating Hurricane Electric records.
[#682](https://github.com/ddclient/ddclient/pull/682) [#682](https://github.com/ddclient/ddclient/pull/682)
* `dyndns2`: The `server` option can now include `http://` or `https://` to * `dyndns2`, `domeneshop`: The `server` option can now include `http://` or
control the use of TLS. If omitted, the value of the `ssl` option is used `https://` to control the use of TLS. If omitted, the value of the `ssl`
to determine the scheme. option is used to determine the scheme.
[#703](https://github.com/ddclient/ddclient/pull/703) [#703](https://github.com/ddclient/ddclient/pull/703)
### Bug fixes ### Bug fixes

View file

@ -4570,16 +4570,9 @@ sub nic_domeneshop_update {
my $ip = delete $config{$h}{'wantip'}; my $ip = delete $config{$h}{'wantip'};
info("Setting IP address to %s for %s", $ip, $h); info("Setting IP address to %s for %s", $ip, $h);
verbose("UPDATE:", "Updating %s", $h); verbose("UPDATE:", "Updating %s", $h);
# Set the URL that we're going to to update
my $url;
$url = $globals{'ssl'} ? "https://" : "http://";
$url .= "$config{$h}{'server'}$endpointPath?hostname=$h&myip=$ip";
# Try to get URL
my $reply = geturl( my $reply = geturl(
proxy => opt('proxy'), proxy => opt('proxy'),
url => $url, url => "$config{$h}{'server'}$endpointPath?hostname=$h&myip=$ip",
login => $config{$h}{'login'}, login => $config{$h}{'login'},
password => $config{$h}{'password'}, password => $config{$h}{'password'},
); );