make sure azure auth uses lowercase email #7449

Signed-off-by: si458 <simonsmith5521@gmail.com>
This commit is contained in:
si458
2025-11-26 18:25:56 +00:00
parent f57bd3b80c
commit e120ae0ee7

View File

@@ -7826,8 +7826,8 @@ module.exports.CreateWebServer = function (parent, db, args, certificates, doneF
parent.authLog('setupDomainAuthStrategy', 'Azure profile: ' + JSON.stringify(userex));
var user = null;
if (userex != null) {
var user = { sid: '~azure:' + userex.unique_name, name: userex.name, strategy: 'azure' };
if (typeof userex.email == 'string') { user.email = userex.email; }
var user = { sid: '~azure:' + userex.unique_name.toLowerCase(), name: userex.name, strategy: 'azure' };
if (typeof userex.email == 'string') { user.email = userex.email.toLowerCase(); }
}
return done(null, user);
}