Bug #10196
closedCloudflare dyndns not working (Invalid TTL)
100%
Description
Cloudflare DynDNS was working fine until today. I think that Cloudflare changed their API and because of that, the dynamic DNS client in pfSense is no longer working.
Relevant system log entry:
/rc.newwanip: phpDynDNS (ak2): UNKNOWN ERROR - Invalid TTL. Must be between 120 and 2,147,483,647 seconds, or 1 for automatic
You cannot set TTL on the dashboard right now. I checked the master branch of pfSense on GitHub and there is no TTL option for it either.
Files
Updated by László Dobó almost 5 years ago
Updated by János K almost 5 years ago
- File fix.png fix.png added
- File dyndns.class.fix.txt dyndns.class.fix.txt added
László Dobó wrote:
Cloudflare DynDNS was working fine until today. I think that Cloudflare changed their API and because of that, the dynamic DNS client in pfSense is no longer working.
Relevant system log entry:
[...]
You cannot set TTL on the dashboard right now. I checked the master branch of pfSense on GitHub and there is no TTL option for it either.
Hi,
I edited /etc/inc/dyndns.class file and DDNS Updater is working again. (https://stackoverflow.com/a/54454832)
I'm removed braces "{ }" and added new line "ttl => 1". See attachment image.
I hope soon to be officially corrected.
Updated by László Dobó almost 5 years ago
János K wrote:
László Dobó wrote:
Cloudflare DynDNS was working fine until today. I think that Cloudflare changed their API and because of that, the dynamic DNS client in pfSense is no longer working.
Relevant system log entry:
[...]
You cannot set TTL on the dashboard right now. I checked the master branch of pfSense on GitHub and there is no TTL option for it either.
Hi,
I edited /etc/inc/dyndns.class file and DDNS Updater is working again. (https://stackoverflow.com/a/54454832)
I'm removed braces "{ }" and added new line "ttl => 1". See attachment image.I hope soon to be officially corrected.
Thank you for your help! I successfully applied the same fix just before submitting this issue and can confirm that it works just fine. Nonetheless, I think that implementing an official fix is highly recommended. Currently, I don't have the time myself but hope somebody can fix this in the future.
Updated by Jim Pingle almost 5 years ago
- Status changed from New to In Progress
- Assignee set to Jim Pingle
- Priority changed from Normal to High
- Target version set to 2.4.5
What exact set of {}
did you remove? I do not see any in the cloudflare query setup that look like they should be removed. The braces around variable names are there so that PHP will properly replace them in strings. Though it doesn't look like the braces or quotes should be necessary since they only surround the variable itself.
From what I can see it just needs the TTL parameter added into the $hostData
array around line 818 ( source:src/etc/inc/dyndns.class#L818 ) and the TTL field enabled in the GUI. The TTL could default to 1
but the user should be able to override that.
Updated by Jim Pingle almost 5 years ago
- File cf-ttl.diff added
Try applying the change in the attached diff and see if it works for you.
Updated by Jim Pingle almost 5 years ago
- Status changed from In Progress to Feedback
- % Done changed from 0 to 100
Applied in changeset 9404b54a44a820b9c0332149a6ea794eed54bdac.
Updated by Jim Pingle almost 5 years ago
- File cf-ttl.diff cf-ttl.diff added
Fixed diff (CF wants TTL to be an integer type).
Updated by Jim Pingle almost 5 years ago
- Status changed from Feedback to Resolved
Code is present in current snapshots, marking this as resolved.