Difference between revisions of "Dynamic DNS Updater"
Jump to navigation
Jump to search
(2 intermediate revisions by the same user not shown) | |||
Line 7: | Line 7: | ||
==The Solution== | ==The Solution== | ||
− | Use Cisco's IP SLA functionality to generate the proper request. This will periodically request the update page, at the specified frequency, which will update the specified hostname. | + | Use Cisco's IP SLA functionality to generate the proper request. This will periodically request the update page, at the specified frequency, which will update the specified hostname. It allows you to manually set the HTTP/1.1 virtual host, and it allows for passwords over 15 characters. |
===Generate The Authorization Key=== | ===Generate The Authorization Key=== | ||
− | Go to http://www.base64encode.org/ | + | # Go to http://www.base64encode.org/. |
+ | # Enter your username and password in the format '''username:password''' with no spaces | ||
+ | # Click the Encode button. | ||
+ | # Copy the whole thing, including the trailing = sign. The result is used below. | ||
===Create The IP SLA Policy=== | ===Create The IP SLA Policy=== | ||
− | Replace '''dyn.example.ca''' with your hostname. Replace '''dXNlcm5hbWU6cGFzc3dvcmQ=''' with the key generated above. | + | Replace '''dyn.example.ca''' with your hostname. Replace '''dXNlcm5hbWU6cGFzc3dvcmQ=''' with the key generated above. If you're not using EasyDNS, replace the '''api.cp.easydns.com''' and '''/dyn/tomato.php''' with the appropriate values for your provider. |
− | <PRE | + | <PRE> |
ip sla 1 | ip sla 1 | ||
http raw http://api.cp.easydns.com | http raw http://api.cp.easydns.com |
Latest revision as of 15:44, 13 June 2013
The Problem
The Cisco implementation for Dynamic DNS updating is broken in two ways that I've found:
- Firstly, there's Cisco Bug ID CSCtx50249, which truncates the password in the URL to 15 characters. DynDNS providers that generate a key for your domain seem to prefer 16 characters.
- On the 830-series of routers, the DynDNS updater does not do HTTP/1.1 requests to the server, but instead an HTTP/1.0 request. This is a problem with EasyDNS, as their update server is on a virtual host, which requires an HTTP/1.1 request in order to present the user with the correct website. This doesn't appear to be an issue on the 1800 or 870-series.
The Solution
Use Cisco's IP SLA functionality to generate the proper request. This will periodically request the update page, at the specified frequency, which will update the specified hostname. It allows you to manually set the HTTP/1.1 virtual host, and it allows for passwords over 15 characters.
Generate The Authorization Key
- Go to http://www.base64encode.org/.
- Enter your username and password in the format username:password with no spaces
- Click the Encode button.
- Copy the whole thing, including the trailing = sign. The result is used below.
Create The IP SLA Policy
Replace dyn.example.ca with your hostname. Replace dXNlcm5hbWU6cGFzc3dvcmQ= with the key generated above. If you're not using EasyDNS, replace the api.cp.easydns.com and /dyn/tomato.php with the appropriate values for your provider.
ip sla 1 http raw http://api.cp.easydns.com http-raw-request GET /dyn/tomato.php?hostname=dyn.example.ca HTTP/1.1\r\n Host: api.cp.easydns.com\r\n Authorization: Basic dXNlcm5hbWU6cGFzc3dvcmQ=\r\n \r\n end exit frequency 3600 ip sla schedule 1 life forever start-time now