SchlundTech DynDNS backend for PHP
Branch: master
Clone or download
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
.gitignore Include example config but ignore custom configs. Apr 17, 2013
README.md
config.example.php
functions.php
request-get.xml
request-put.xml Initial commit. Apr 15, 2013
robots.txt Disallow all robots. Apr 19, 2013
update.php

README.md

php-dyndns

SchlundTech DynDNS backend for PHP.

Installation

Prerequisites

  • Contract with Schlund-Technologies and access to the XML-Gateway.
  • Webserver with PHP and php-curl (optional, runs from CLI as well).

Setup

  1. Create a subdomain with an A-record in your domain, say home.example.com. It should have a low TTL value such that it is not cached (schlundtech only allows >=60).
  2. Upload the files to your webserver. The update.php script has to be accessible from the web, for example: dyndns.example.com/update.php. HTTPS is highly recommended!
  3. Copy config.example.php to config.php and adjust the settings.
  4. Create the logdir and give the webserver write-access to it.
  5. Set up a cron-job, fritz-box, router, ... to do a request every time the ip-address changes. The URL is http://dyndns.example.com/update.php?pass=<password>&domain=example.com&ipaddr=<ipaddr>&ip6addr=<ip6addr>

NGINX configuration

This is an example configuration for nginx:

server {
  # your settings

  location ~ /\.git {
    deny all;
  }

  location ~ ^/config.*.php { deny all; }
  location ~ ^/request-get.xml { deny all; }
  location ~ ^/request-put.xml  { deny all; }
  location ~ ^/logs/  { deny all; }
}

Command line

The script can also be executed from the command line:

php update.php --pass="<password>" --domain="example.com" --ipaddr="<ipaddr>" --ip6addr="<ip6addr>"

Roadmap

  • Standardize API, e.g. like Dyn.com
  • Security-Audit
  • Rolling log files