# HG changeset patch # User Kim Alvefur # Date 1678446112 -3600 # Node ID ac252db71027ca69133c81d6b4ce7f8cd11bcae6 # Parent c24a622a7b8572ba86ef5baf25e6ccb1ed9301a1 mod_http_oauth2: Log flows enabled and disabled If a developer ever wants to be sure what the state is diff -r c24a622a7b85 -r ac252db71027 mod_http_oauth2/mod_http_oauth2.lua --- a/mod_http_oauth2/mod_http_oauth2.lua Fri Mar 10 11:54:30 2023 +0100 +++ b/mod_http_oauth2/mod_http_oauth2.lua Fri Mar 10 12:01:52 2023 +0100 @@ -445,7 +445,10 @@ local allowed_grant_type_handlers = module:get_option_set("allowed_oauth2_grant_types", {"authorization_code", "password"}) for handler_type in pairs(grant_type_handlers) do if not allowed_grant_type_handlers:contains(handler_type) then + module:log("debug", "Grant type %q disabled", handler_type); grant_type_handlers[handler_type] = nil; + else + module:log("debug", "Grant type %q enabled", handler_type); end end @@ -453,7 +456,10 @@ local allowed_response_type_handlers = module:get_option_set("allowed_oauth2_response_types", {"code"}) for handler_type in pairs(response_type_handlers) do if not allowed_response_type_handlers:contains(handler_type) then + module:log("debug", "Response type %q disabled", handler_type); grant_type_handlers[handler_type] = nil; + else + module:log("debug", "Response type %q enabled", handler_type); end end