From 3f07f0ce65c41862b97f0a1e347a4452572c9cbb Mon Sep 17 00:00:00 2001 From: Chris Hofstaedtler Date: Fri, 15 Feb 2019 22:22:20 +0100 Subject: [PATCH] recuweb: remove api-key from interface, can just use basic auth --- pdns/recursordist/html/index.html | 4 +--- pdns/recursordist/html/local.js | 11 ++--------- 2 files changed, 3 insertions(+), 12 deletions(-) diff --git a/pdns/recursordist/html/index.html b/pdns/recursordist/html/index.html index c913094e4..2624b90fa 100644 --- a/pdns/recursordist/html/index.html +++ b/pdns/recursordist/html/index.html @@ -22,9 +22,7 @@
- - - +
diff --git a/pdns/recursordist/html/local.js b/pdns/recursordist/html/local.js index 9e6fc0319..549102c0e 100644 --- a/pdns/recursordist/html/local.js +++ b/pdns/recursordist/html/local.js @@ -21,12 +21,6 @@ $(document).ready(function () { $('#' + name).html(h); }; - var password = $("#password").val(); - $("#password").change(function (e) { - password = $("#password").val(); - update(); - }); - var qpsgraph = new Rickshaw.Graph({ element: document.getElementById("qpschart"), width: 400, @@ -70,7 +64,6 @@ $(document).ready(function () { var jsonstatParams = function (command, name, filtered) { var d = { - 'api-key': password, 'command': command, 'name': name }; @@ -159,7 +152,7 @@ $(document).ready(function () { function update() { $.ajax({ - url: 'api/v1/servers/localhost/statistics?api-key=' + password, + url: 'api/v1/servers/localhost/statistics', type: 'GET', dataType: 'json', success: function (adata, x, y) { @@ -216,7 +209,7 @@ $(document).ready(function () { if (!version) { $.ajax({ - url: 'api/v1/servers/localhost?api-key=' + password, type: 'GET', dataType: 'json', + url: 'api/v1/servers/localhost', type: 'GET', dataType: 'json', success: function (data) { version = "PowerDNS " + data["daemon_type"] + " " + data["version"]; } -- 2.40.0