diff mod_auth_oauth_external/mod_auth_oauth_external.lua @ 5443:4e79f344ae2f

mod_auth_oauth_external: Also do XEP-0106 escaping in SASL OAUTHBEARER For consistency. The mangling should be made configurable in the future.
author Kim Alvefur <zash@zash.se>
date Wed, 10 May 2023 19:33:37 +0200
parents 7480dde4cd2e
children 0207fd248480
line wrap: on
line diff
--- a/mod_auth_oauth_external/mod_auth_oauth_external.lua	Wed May 10 19:11:25 2023 +0200
+++ b/mod_auth_oauth_external/mod_auth_oauth_external.lua	Wed May 10 19:33:37 2023 +0200
@@ -127,7 +127,7 @@
 				return false, nil, nil;
 			end
 
-			return response[username_field], true, response;
+			return jid.escape(response[username_field]), true, response;
 		end
 	end
 	return sasl.new(host, profile);