Add SPDNS as new provider.
authorStefan Schantl <stefan.schantl@ipfire.org>
Sun, 15 Jun 2014 10:16:59 +0000 (12:16 +0200)
committerStefan Schantl <stefan.schantl@ipfire.org>
Sun, 15 Jun 2014 10:16:59 +0000 (12:16 +0200)
ddns.conf.sample
src/ddns/__init__.py
src/ddns/providers.py

index bb0e839..f9058e6 100644 (file)
 # username = user
 # password = pass
 
+# [test.spdns.org]
+# provider = spdns.org
+# username = user
+# password = pass
+
 # [test.lightningwirelabs.com]
 # provider = dns.lightningwirelabs.com
 
index 5172832..d8b2b10 100644 (file)
@@ -98,6 +98,7 @@ class DDNSCore(object):
                        DDNSProviderNOIP,
                        DDNSProviderLightningWireLabs,
                        DDNSProviderSelfhost,
+                       DDNSProviderSPDNS,
                ):
                        self.register_provider(provider)
 
index 8a5185f..68305c7 100644 (file)
@@ -489,3 +489,21 @@ class DDNSProviderSelfhost(DDNSProvider):
                match = re.search("status=20(0|4)", response.read())
                if not match:
                        raise DDNSUpdateError
+
+
+class DDNSProviderSPDNS(DDNSProviderDynDNS):
+       INFO = {
+               "handle"    : "spdns.org",
+               "name"      : "SPDNS",
+               "website"   : "http://spdns.org/",
+               "protocols" : ["ipv4",]
+       }
+
+       # Detailed information about request and response codes are provided
+       # by the vendor. They are using almost the same mechanism and status
+       # codes as dyndns.org so we can inherit all those stuff.
+       #
+       # http://wiki.securepoint.de/index.php/SPDNS_FAQ
+       # http://wiki.securepoint.de/index.php/SPDNS_Update-Tokens
+
+       url = "https://update.spdns.de/nic/update"