summaryrefslogtreecommitdiff
path: root/kvmd/apps
diff options
context:
space:
mode:
Diffstat (limited to 'kvmd/apps')
-rw-r--r--kvmd/apps/__init__.py4
-rw-r--r--kvmd/apps/kvmd/auth.py8
2 files changed, 6 insertions, 6 deletions
diff --git a/kvmd/apps/__init__.py b/kvmd/apps/__init__.py
index e4b10127..89a1af0e 100644
--- a/kvmd/apps/__init__.py
+++ b/kvmd/apps/__init__.py
@@ -111,9 +111,9 @@ def _init_config(config_path: str, sections: List[str], override_options: List[s
config = make_config(raw_config, scheme)
if "kvmd" in sections:
- scheme["kvmd"]["auth"]["internal"] = get_auth_service_class(config.kvmd.auth.internal_type).get_options()
+ scheme["kvmd"]["auth"]["internal"] = get_auth_service_class(config.kvmd.auth.internal_type).get_plugin_options()
if config.kvmd.auth.external_type:
- scheme["kvmd"]["auth"]["external"] = get_auth_service_class(config.kvmd.auth.external_type).get_options()
+ scheme["kvmd"]["auth"]["external"] = get_auth_service_class(config.kvmd.auth.external_type).get_plugin_options()
config = make_config(raw_config, scheme)
return config
diff --git a/kvmd/apps/kvmd/auth.py b/kvmd/apps/kvmd/auth.py
index 0753f176..d1d21db4 100644
--- a/kvmd/apps/kvmd/auth.py
+++ b/kvmd/apps/kvmd/auth.py
@@ -47,12 +47,12 @@ class AuthManager:
) -> None:
self.__internal_service = get_auth_service_class(internal_type)(**internal_kwargs)
- get_logger().info("Using internal auth service %r", self.__internal_service.PLUGIN_NAME)
+ get_logger().info("Using internal auth service %r", self.__internal_service.get_plugin_name())
self.__external_service: Optional[BaseAuthService] = None
if external_type:
self.__external_service = get_auth_service_class(external_type)(**external_kwargs)
- get_logger().info("Using external auth service %r", self.__external_service.PLUGIN_NAME)
+ get_logger().info("Using external auth service %r", self.__external_service.get_plugin_name())
self.__internal_users = internal_users
@@ -66,9 +66,9 @@ class AuthManager:
ok = (await service.authorize(user, passwd))
if ok:
- get_logger().info("Authorized user %r via auth service %r", user, service.PLUGIN_NAME)
+ get_logger().info("Authorized user %r via auth service %r", user, service.get_plugin_name())
else:
- get_logger().error("Got access denied for user %r from auth service %r", user, service.PLUGIN_NAME)
+ get_logger().error("Got access denied for user %r from auth service %r", user, service.get_plugin_name())
return ok
async def login(self, user: str, passwd: str) -> Optional[str]: