Bug #10196
closed
Cloudflare dyndns not working (Invalid TTL)
Added by László Dobó almost 5 years ago.
Updated almost 5 years ago.
Affected Architecture:
All
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
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.
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.
- 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.
Try applying the change in the attached diff and see if it works for you.
- Status changed from In Progress to Feedback
- % Done changed from 0 to 100
- File deleted (
cf-ttl.diff)
Fixed diff (CF wants TTL to be an integer type).
It's working for me as well!
- Status changed from Feedback to Resolved
Code is present in current snapshots, marking this as resolved.
Also available in: Atom
PDF