From c3811a694e3c16836759ae6c05ded0af2a8b972b Mon Sep 17 00:00:00 2001 From: Linus Nordberg Date: Fri, 3 Mar 2017 15:57:19 +0100 Subject: When checking an ACL, log full ACL only when failing. Also, log the fact that we're failing, with path, at info level. --- src/http_auth.erl | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src') diff --git a/src/http_auth.erl b/src/http_auth.erl index 276e1cd..2cee51f 100644 --- a/src/http_auth.erl +++ b/src/http_auth.erl @@ -69,7 +69,6 @@ check_acl(Method, KeyName, Path) -> allowed_clients end, ACL = plopconfig:get_env(EnvVarName, []), - lager:debug("ACL: ~p", [ACL]), case lists:keyfind(Path, 1, ACL) of {_, noauth} -> lager:debug("Anonymous access allowed"), @@ -83,7 +82,8 @@ check_acl(Method, KeyName, Path) -> failure end; false -> - lager:debug("No allowed keys found for: ~p", [Path]), + lager:debug("ACL: ~p", [ACL]), + lager:info("No allowed keys found for: ~p", [Path]), failure end. -- cgit v1.1