From 9dedc78f3c9c8b4587dfa8ff014c521fe6cb1d2c Mon Sep 17 00:00:00 2001 From: Matthew Wild Date: Wed, 15 Mar 2023 09:41:38 +0000 Subject: util.sasl.oauthbearer: Attach token_info to sasl handler This allows token-aware things to access extra information about the authentication, such as when the token is due to expire and the attached custom 'data'. --- util/sasl/oauthbearer.lua | 2 ++ 1 file changed, 2 insertions(+) (limited to 'util/sasl') diff --git a/util/sasl/oauthbearer.lua b/util/sasl/oauthbearer.lua index 54c63575..5cce2ef7 100644 --- a/util/sasl/oauthbearer.lua +++ b/util/sasl/oauthbearer.lua @@ -75,6 +75,8 @@ local function oauthbearer(self, message) self.resource = token_info.resource; self.role = token_info.role; + self.token_info token_info; + return "success"; end -- cgit v1.2.3