mirror of
https://github.com/tuxis-ie/nsedit.git
synced 2025-04-19 20:09:14 +03:00
Check for newly added configuration options
Fix typo in default config file Closes #40
This commit is contained in:
parent
c70e0b19a1
commit
a8fadba0e0
2 changed files with 11 additions and 1 deletions
|
@ -6,7 +6,7 @@ $apiip = ''; # The IP of the PowerDNS API
|
||||||
$apiport = '8081'; # The port of the PowerDNS API
|
$apiport = '8081'; # The port of the PowerDNS API
|
||||||
$apisid = 'localhost'; # PowerDNS's :server_id
|
$apisid = 'localhost'; # PowerDNS's :server_id
|
||||||
$apiproto = 'http'; # http | https
|
$apiproto = 'http'; # http | https
|
||||||
$apisslsverify = FALSE; # Verify SSL Certificate if using https for apiproto
|
$apisslverify = FALSE; # Verify SSL Certificate if using https for apiproto
|
||||||
$allowzoneadd = FALSE; # Allow normal users to add zones
|
$allowzoneadd = FALSE; # Allow normal users to add zones
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -14,6 +14,16 @@ if (!isset($authmethod) or !preg_match('/^(xapikey|userpass|auto)$/', $authmetho
|
||||||
$blocklogin = TRUE;
|
$blocklogin = TRUE;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (!isset($apiproto) or !preg_match('/^http(s)?$/', $apiproto)) {
|
||||||
|
$errormsg = "The value for \$apiproto is incorrect in your config. Did you configure it?";
|
||||||
|
$blocklogin = TRUE;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (!isset($apisslverify) or !preg_match('/^[01]$/', $apisslverify)) {
|
||||||
|
$errormsg = "The value for \$apisslverify is incorrect in your config. Did you configure it?";
|
||||||
|
$blocklogin = TRUE;
|
||||||
|
}
|
||||||
|
|
||||||
if (!isset($authdb)) {
|
if (!isset($authdb)) {
|
||||||
$errormsg = "You did not configure a value for the setting \$authdb in your config";
|
$errormsg = "You did not configure a value for the setting \$authdb in your config";
|
||||||
$blocklogin = TRUE;
|
$blocklogin = TRUE;
|
||||||
|
|
Loading…
Add table
Reference in a new issue