Project

General

Profile

Actions

Bug #8014

closed

DynDNS wildcard option doesn't work for provider Loopia

Added by Kristoffer Ekenstam over 6 years ago. Updated over 4 years ago.

Status:
Resolved
Priority:
Normal
Category:
Dynamic DNS
Target version:
Start date:
10/26/2017
Due date:
% Done:

100%

Estimated time:
Plus Target Version:
Release Notes:
Affected Version:
2.4.1
Affected Architecture:

Description

The DynDNS wildcard option doesn't work for provider Loopia.

It seems that this line never results in $this->_dnsWildcard being set to "ON":

if (isset($this->_dnsWildcard) && $this->_dnsWildcard != "OFF") $this->_dnsWildcard = "ON";

The same check is done for many providers, so maybe this problem doesn't only affect Loopia.

Here's a fix for Loopia, that works for me at least:

case 'loopia':
    $needsIP = TRUE;
    if(isset($this->_dnsWildcard) && $this->_dnsWildcard == TRUE) {
        $this->_dnsWildcard = "ON";
    }
    else {
        $this->_dnsWildcard = "OFF";
    }
    curl_setopt($ch, CURLOPT_USERPWD, $this->_dnsUser.':'.$this->_dnsPass);
    curl_setopt($ch, CURLOPT_URL, 'https://dyndns.loopia.se/?system=custom&hostname=' . $this->_dnsHost . '&myip=' . $this->_dnsIP . '&wildcard=' . $this->_dnsWildcard . '&mx=' . $this->_dnsMX . '&backmx=NO');
    break;

Please note that the host(CURLOPT_URL) is changed to https://dyndns.loopia.se, as stated on Loopia's support page:
https://translate.google.se/translate?sl=sv&tl=en&js=y&prev=_t&hl=sv&ie=UTF-8&u=https%3A%2F%2Fsupport.loopia.se%2Fwiki%2Fom-dyndns-stodet%2F&edit-text=

Also reported in this forum thread:
https://forum.pfsense.org/index.php?topic=138826.0

Actions #1

Updated by Jim Pingle over 4 years ago

  • Status changed from New to Resolved

PR was merged a long time ago.
https://github.com/pfsense/pfsense/pull/3753

Actions #2

Updated by Kristoffer Ekenstam over 4 years ago

PR 3753 didn't solve this problem, have checked the latest version.

$this->_dnsWildcard is either ON or 1. Never OFF.
CURLOPT_URL needs to be updated.

The solution above also adds support for MX records.

Actions #3

Updated by Jim Pingle over 4 years ago

  • Status changed from Resolved to New

OK, can you submit that change as a pull request on Github then? Thanks!

https://docs.netgate.com/pfsense/en/latest/development/submitting-a-pull-request-via-github.html

Actions #5

Updated by Jim Pingle over 4 years ago

  • Target version set to 2.5.0

Thanks!

Actions #6

Updated by Jim Pingle over 4 years ago

  • Status changed from New to Pull Request Review
Actions #7

Updated by Renato Botelho over 4 years ago

  • Status changed from Pull Request Review to Feedback
  • Assignee set to Renato Botelho
  • % Done changed from 0 to 100

PR has been merged. Thanks!

Actions #8

Updated by Jim Pingle over 4 years ago

  • Target version changed from 2.5.0 to 2.4.5
Actions #9

Updated by Jim Pingle over 4 years ago

  • Status changed from Feedback to Resolved

Not a service we can test internally, and no response from OP or other consumers of the service in question, so closing. Can revisit in a new issue if there are problems with the change.

Actions

Also available in: Atom PDF