diff options
author | Dileep Ranganathan <dileep.ranganathan@intel.com> | 2018-10-12 02:29:49 -0700 |
---|---|---|
committer | Dileep Ranganathan <dileep.ranganathan@intel.com> | 2018-10-19 04:55:34 -0700 |
commit | c3aa7ebbb6f17c93958103077614f5bdac9837b0 (patch) | |
tree | 5688c63850524dabe9eba9cd96cf29df3cd91279 /osdf/webapp | |
parent | 8d495104b8174cdc19b4bf27b98d9b4210fec01f (diff) |
Enable SMS in OSDF
Load secrets from SMS in OSDF.
Removed secrets from osdf_config.yaml.
Unit tests to use the test/config/osdf_config.yaml.
Helm charts uses a Job to load secrets.
CSIT needs to load it using the preload tool provided by SMS.
Change-Id: I0f832033476c02958f6392abba74e4d5a36cc902
Issue-ID: OPTFRA-343
Signed-off-by: Dileep Ranganathan <dileep.ranganathan@intel.com>
Diffstat (limited to 'osdf/webapp')
-rw-r--r-- | osdf/webapp/appcontroller.py | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/osdf/webapp/appcontroller.py b/osdf/webapp/appcontroller.py index 3a5385d..9714fb5 100644 --- a/osdf/webapp/appcontroller.py +++ b/osdf/webapp/appcontroller.py @@ -21,7 +21,8 @@ from flask_httpauth import HTTPBasicAuth from flask import Response import json import osdf -from osdf.config.base import http_basic_auth_credentials, osdf_config +import osdf.config.base as cfg_base +from osdf.config.base import osdf_config from osdf.adapters.aaf import aaf_authentication as aaf_auth auth_basic = HTTPBasicAuth() @@ -38,7 +39,8 @@ unauthorized_message = json.dumps(error_body) def get_pw(username): end_point = request.url.split('/')[-1] auth_group = osdf.end_point_auth_mapping.get(end_point) - return http_basic_auth_credentials[auth_group].get(username) if auth_group else None + return cfg_base.http_basic_auth_credentials[auth_group].get( + username) if auth_group else None @auth_basic.error_handler def auth_error(): |