Monday, February 4, 2008

Dynamic DNS and transparent proxies

I prefer having my DynDNS account updated by my Linux-based DSL-500T ADSL modem/router (flashed with Russian firmware) since it means the host updates occur every time a PPP session is established. Otherwise, I would have needed an inefficient cron job at my main box.

I haven't needed to access my PC remotely in the past few months, so I just recently noticed that my DynDNS host wasn't getting updated. At first, I thought there was something wrong with the router, but after my previous blog, I noticed that my host's registered IP address was that of (you guessed it, good for you!) Globe's transparent proxy.

It turns out my router's ddns call (hardcoded in the router's firmware-flashed XML) was using automatic IP resolution, i.e. DynDNS used whatever IP address the update command came from.

So, I downloaded the current XML configuration, made it more editable with HTML Tidy (tidy -xml), fixed the command to use -i ppp0 instead of -r, mashed the XML back into a single line with another one of my quick-and-dirty scripts (clutter), and reflashed it into the router. After it rebooted, my DynDNS account was being updated properly again. Phew.

ddns -u myuser:mypass -h myhost.at.dyndns -w -r -q -i ppp0

If any of you are having similar problems, check if your ISP has a transparent proxy. If you're lucky enough to be able to customize the commands your router runs, the above might be of some help.

Of course, if you're really lucky, your router doesn't have this problem in the first place. :-P

2 comments:

__ said...

i'll pray over my router. it might just grow some decent ddns wings. i'll call it skyline pidgin. :D

Unknown said...

Ah, you're really lucky then... no ddns problems. :-P