summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rwxr-xr-xsrc/conf_mode/http-api.py8
1 files changed, 8 insertions, 0 deletions
diff --git a/src/conf_mode/http-api.py b/src/conf_mode/http-api.py
index 9c062f0aa..c0c16cfc0 100755
--- a/src/conf_mode/http-api.py
+++ b/src/conf_mode/http-api.py
@@ -59,10 +59,18 @@ def get_config():
key = conf.return_value('keys id {0} key'.format(name))
new_key = { 'id': name, 'key': key }
http_api['api_keys'].append(new_key)
+ else:
+ raise ConfigError('Missing HTTPS API key string for key id "}"'.format(name))
return http_api
def verify(http_api):
+ # Verify API server settings, if present
+ keys = http_api['api_keys']
+
+ if not keys:
+ raise ConfigError('At least one HTTPS API key is required')
+
return None
def generate(http_api):