Modify

Opened 5 years ago

Closed 3 years ago

Last modified 23 months ago

#13246 closed defect (moved_to_github)

ddns-scripts fails with dyndns.org because of missing User-Agent

Reported by: lultimouomo@… Owned by: developers
Priority: normal Milestone: Barrier Breaker 14.07
Component: packages Version: Attitude Adjustment 12.09 Beta
Keywords: ddns-scripts dyndns.org Cc:

Description

dyndns.org documentation at http://dyn.com/support/developers/api/perform-update/ states:

All clients must send a well-formed user agent that includes company name, model number, and software build revision. 

And indeed if I use ddns-scripts with dyndns.org I get a

good 127.0.0.1

response, that according to http://dyn.com/support/developers/api/return-codes/ means:

This answer indicates good update only when 127.0.0.1 address is requested by update. In all other cases it warns user that request was ignored because of agent that does not follow our specifications.

And indeed badly hacking the script so that it passes

-U OpenWrt-TLWR1043ND-12.09 

makes the DNS update work again.

The bug is present in 12.09-rc1

Attachments (0)

Change History (7)

comment:1 Changed 5 years ago by anonymous

we I can add "-U OpenWrt-TLWR1043ND-12.09 "?

comment:2 Changed 5 years ago by xyman

where I can add "-U OpenWrt-TLWR1043ND-12.09 " in script?

I can direct use wget to add "-U OpenWrt-TLWR1043ND-12.09" , but where i can add in dynamic_dns_updater.sh ?

Thanks,

comment:3 Changed 5 years ago by anonymous

In dynamic_dns_updater.sh search for "wget". It should be something like "wget -O -".
Between "wget" and "-O" insert "-U OpenWrt", so it looks like "wget -U OpenWrt -O -".
That worked for me.

comment:4 Changed 5 years ago by anonymous

Oh, find it in line 112

Change
retrieve_prog="/usr/bin/wget -O - ";
To
retrieve_prog="/usr/bin/wget -U OpenWrt-TLWR1043ND-12.09 -O - ";

Done!
Thx.

comment:5 Changed 4 years ago by jow

  • Milestone changed from Attitude Adjustment 12.09 to Barrier Breaker 14.07

Milestone Attitude Adjustment 12.09 deleted

comment:6 Changed 3 years ago by nbd

  • Resolution set to moved_to_github
  • Status changed from new to closed

ddns-scripts is maintained here: https://github.com/openwrt/packages

comment:7 Changed 23 months ago by chris5560

Late extension:
I found a german page showing user agent string when you request the page.
http://bc.larskl.de/browserinfo
I checked curl, GNU wget and busybox-wget on CC 1505 and additional uclient-fetch on DD trunk.
All sending automatically a default HTTP user agent string.
So no need to change ddns-scripts because it's set automatically.

Add Comment

Modify Ticket

Action
as closed .
The resolution will be deleted. Next status will be 'reopened'.
Author


E-mail address and user name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.