]> git.ipfire.org Git - ipfire-2.x.git/commitdiff
ddns.cgi: Add required code for generating valid nsupdate.info config section.
authorStefan Schantl <stefan.schantl@ipfire.org>
Wed, 9 Jul 2014 19:14:49 +0000 (21:14 +0200)
committerStefan Schantl <stefan.schantl@ipfire.org>
Wed, 9 Jul 2014 19:14:49 +0000 (21:14 +0200)
html/cgi-bin/ddns.cgi

index 51deb03131988fd424cfe8524706a7b126363a78..303f92c7c82e6d3802cacd14dd5f068253a80a82 100644 (file)
@@ -675,6 +675,14 @@ sub GenerateDDNSConfigFile {
                        $password = "";
                }
 
+               # Handle keys for nsupdate.info
+               } elsif (($provider eq "nsupdate.info") && $password) {
+                       print FILE "secret = $password\n";
+
+                       $username = "";
+                       $password = "";
+               }
+
                # Write auth details.
                if ($use_token) {
                        print FILE "token = $password\n";
@@ -684,7 +692,7 @@ sub GenerateDDNSConfigFile {
                }
 
                # These providers need to be set to only use IPv4.
-               if ($provider ~~ ["freedns.afraid.org", "variomedia.de", "zoneedit.com"]) {
+               if ($provider ~~ ["freedns.afraid.org", "nsupdate.info", "variomedia.de", "zoneedit.com"]) {
                        print FILE "proto = ipv4\n";
                }