/services_dyndns_edit.php: phpDynDNS: (Unknown Response)
-
Folks,
Last night I had to reboot my ISP (at&t) router and got new IPs - first time in an year+.
My DNS provider is google domains and all my dynamic IPs are (were) with the old IP. When forcing renew got the error in subject on my log.
Rebooting, deleting the entries from the service didn't help. The new ones created now have a 0.0.0.0 IP.
Installed ddclient on ubuntu and worked fine.
Any help to troubleshooting this issue is appreciated.This happened from two different locations by the way, specs below:
First:
System Netgate pfSense Plus
BIOS Vendor: American Megatrends Inc.
Version: 1414
Release Date: Tue Sep 23 2014
Version 22.01-RELEASE (amd64)
built on Mon Feb 07 16:37:59 UTC 2022
FreeBSD 12.3-STABLEThe system is on the latest version.
Version information updated at Fri Feb 25 16:45:11 EST 2022
CPU Type Intel(R) Core(TM) i5-3330 CPU @ 3.00GHz
Current: 3000 MHz, Max: 3001 MHz
4 CPUs: 1 package(s) x 4 core(s)
AES-NI CPU Crypto: Yes (active)2nd
System pfSense
BIOS Vendor: Dell Inc.
Version: A17
Release Date: Wed Nov 16 2016
Version 2.6.0-RELEASE (amd64)
built on Mon Jan 31 19:57:53 UTC 2022
FreeBSD 12.3-STABLEThe system is on the latest version.
Version information updated at Fri Feb 25 15:50:57 EST 2022
CPU Type Intel(R) Core(TM) i3-3220 CPU @ 3.30GHz
4 CPUs: 1 package(s) x 2 core(s) x 2 hardware threads
AES-NI CPU Crypto: No -
Hi,
first of all you should edit your post and remove/mask serial and device ID.
Second: did your ever check if your dyndns command for renewing the IPs is working?
Is it exactly the same command when using your Linux host?Regards
-
@fsc830 said in /services_dyndns_edit.php: phpDynDNS: (Unknown Response):
Hi,
first of all you should edit your post and remove/mask serial and device ID.Ok, thanks, done.
Second: did your ever check if your dyndns command for renewing the IPs is working?
Is it exactly the same command when using your Linux host?From pf I only can see the entry in the log that I have in my subject.
That was configured over an year ago and worked. Now that the IP changed, it is not working. Even deleted and recreated the entries in pf to no avail.
-
You should see your setting in services - ddns menu (not sure about the exact wording)!?
At least at my pfSense I can see and edit the command for updating the ddns service.
Regards
-
@fsc830 said in /services_dyndns_edit.php: phpDynDNS: (Unknown Response):
You should see your setting in services - ddns menu (not sure about the exact wording)!?
At least at my pfSense I can see and edit the command for updating the ddns service.
Regards
Yes, correct. It is there and with IPs 0.0.0.0 (the new one created for test) and N/A the old one (already in my config for years). In fact I've moved the install to another location in Jan and it did update the IPs. Either pf 2.6 or google are at fault.
-
@amello Refer to the following post for details on a patch required for successful Google Domains Dynamic DNS updating:
Peter
-
@plfinch
Thanks for the tip. I'll check the patch and apply. -
That patch is in the 'recommended patches' list in the new System Patches package so it's one click to apply it.
Steve
-
@stephenw10 I was very pleasantly surprised this morning when I updated package patches and saw the list of recommended patches with Redmine numbers listed. This is great!
Peter
-
@stephenw10
Hi, I have the same problem. The response from namecheap is not correctly parsed. I applied the patch for Redmine #12816 to pfSense 2.6.0-RELEASE, but the response is still not parsed. The cached IP still says 0.0.0.0. I have also rebooted the router. -
What is namecheap responding with?
Does it correctly update from a different dyndns client?
Steve
-
<?xml version="1.0" encoding="utf-16"?>
<interface-response>
<Command>SETDNSHOST</Command>
<Language>eng</Language>
<IP>xxx.yyy.zzz.aaa</IP> <---- the IP from my external gateway
<ErrCount>0</ErrCount>
<errors/>
<ResponseCount>0</ResponseCount>
<responses/>
<Done>true</Done>
<debug><![CDATA[]]></debug>
</interface-response>I'm only using namecheap for dynamic dns.
-
I removed the .cache file generated for namecheap, and now when I save the settings for its client, the .cache file contains "0.0.0.0|1661343037", and in the UI it's displayed "0.0.0.0".
I also added a freeDNS API Version 2 client, which corectly registers and caches the dynamic IP. -
Hmm, looks OK. Are you actually seeing the 'Unknown Response' error logged?
-
Yes, this is the log generated after I saved the settings for namecheap:
Aug 24 16:23:04 php-fpm 11484 /services_dyndns_edit.php: phpDynDNS (home): (Unknown Response) Aug 24 16:23:04 php-fpm 11484 /services_dyndns_edit.php: phpDynDNS (home): PAYLOAD: <?xml version="1.0" encoding="utf-16"?><interface-response><Command>SETDNSHOST</Command><Language>eng</Language><IP>xxx.yyy.zzz.aaa</IP><ErrCount>0</ErrCount><errors /><ResponseCount>0</ResponseCount><responses /><Done>true</Done><debug><![CDATA[]]></debug></interface-response> Aug 24 16:23:04 php-fpm 11484 /services_dyndns_edit.php: Dynamic DNS namecheap (home.XMX.net): _checkStatus() starting. Aug 24 16:23:04 php-fpm 11484 /services_dyndns_edit.php: Response Data: <?xml version="1.0" encoding="utf-16"?><interface-response><Command>SETDNSHOST</Command><Language>eng</Language><IP>xxx.yyy.zzz.aaa</IP><ErrCount>0</ErrCount><errors /><ResponseCount>0</ResponseCount><responses /><Done>true</Done><debug><![CDATA[]]></debug></interface-response> Aug 24 16:23:04 php-fpm 11484 /services_dyndns_edit.php: Response Header: Aug 24 16:23:04 php-fpm 11484 /services_dyndns_edit.php: Response Header: Aug 24 16:23:04 php-fpm 11484 /services_dyndns_edit.php: Response Header: alt-svc: h3=":443"; ma=86400, h3-29=":443"; ma=86400 Aug 24 16:23:04 php-fpm 11484 /services_dyndns_edit.php: Response Header: cf-ray: 73fc6680cbc5c1af-BUD Aug 24 16:23:04 php-fpm 11484 /services_dyndns_edit.php: Response Header: server: cloudflare Aug 24 16:23:04 php-fpm 11484 /services_dyndns_edit.php: Response Header: expect-ct: max-age=604800, report-uri="https://report-uri.cloudflare.com/cdn-cgi/beacon/expect-ct" Aug 24 16:23:04 php-fpm 11484 /services_dyndns_edit.php: Response Header: cf-cache-status: DYNAMIC Aug 24 16:23:04 php-fpm 11484 /services_dyndns_edit.php: Response Header: strict-transport-security: max-age=16000000; includeSubDomains Aug 24 16:23:04 php-fpm 11484 /services_dyndns_edit.php: Response Header: strict-transport-security: max-age=16000000; includeSubDomains Aug 24 16:23:04 php-fpm 11484 /services_dyndns_edit.php: Response Header: set-cookie: .s=3b275e1f0d8248488011fad0e6fa3ad4; domain=.www.namecheap.com; path=/; httponly Aug 24 16:23:04 php-fpm 11484 /services_dyndns_edit.php: Response Header: vary: Accept-Encoding Aug 24 16:23:04 php-fpm 11484 /services_dyndns_edit.php: Response Header: content-type: application/json Aug 24 16:23:04 php-fpm 11484 /services_dyndns_edit.php: Response Header: date: Wed, 24 Aug 2022 13:23:04 GMT Aug 24 16:23:04 php-fpm 11484 /services_dyndns_edit.php: Response Header: HTTP/2 200 Aug 24 16:23:04 php-fpm 11484 /services_dyndns_edit.php: Dynamic DNS namecheap (home.XMX.net): _update() starting. Aug 24 16:23:04 php-fpm 11484 /services_dyndns_edit.php: Dynamic DNS (home.XMX.net): running get_failover_interface for wan. found igb0 Aug 24 16:23:04 php-fpm 11484 /services_dyndns_edit.php: Dynamic DNS namecheap (home.XMX.net): xxx.yyy.zzz.aaa extracted from Check IP Service Aug 24 16:23:03 php-fpm 11484 /services_dyndns_edit.php: Dynamic DNS namecheap (home.XMX.net): _checkIP() starting. Aug 24 16:23:03 php-fpm 11484 /services_dyndns_edit.php: Dynamic DNS: updatedns() starting
-
Hmm, looks exactly like what that patch should correct.
Does it show as applied? Is the change actually present in /etc/inc/dyndns.class?
-
This is the namecheap section in the /etc/inc/dyndns.class file:
-
-
Hmm, sure looks like the response is correct.
-
@stephenw10
With my limited php experience I was able to find out the problem.
The response is an xml sent on one line, with the encoding set to utf-16, so line$ncresponse = xml2array(substr($tmp, strpos($tmp, "\n") + 1));
gets executed, and $ncresponse is actually empty.
Which means that $ncresponse does not match any of the ifs. so it ends up in the lastelse
.