You've already forked matrix-react-sdk
mirror of
https://github.com/matrix-org/matrix-react-sdk.git
synced 2025-08-07 21:23:00 +03:00
OIDC: persist id token claims (#11691)
* persist idTokenClaims * tests * remove unused cde
This commit is contained in:
@@ -272,7 +272,7 @@ export async function attemptDelegatedAuthLogin(
|
||||
*/
|
||||
async function attemptOidcNativeLogin(queryParams: QueryDict): Promise<boolean> {
|
||||
try {
|
||||
const { accessToken, refreshToken, homeserverUrl, identityServerUrl, clientId, issuer } =
|
||||
const { accessToken, refreshToken, homeserverUrl, identityServerUrl, idTokenClaims, clientId, issuer } =
|
||||
await completeOidcLogin(queryParams);
|
||||
|
||||
const {
|
||||
@@ -294,7 +294,7 @@ async function attemptOidcNativeLogin(queryParams: QueryDict): Promise<boolean>
|
||||
logger.debug("Logged in via OIDC native flow");
|
||||
await onSuccessfulDelegatedAuthLogin(credentials);
|
||||
// this needs to happen after success handler which clears storages
|
||||
persistOidcAuthenticatedSettings(clientId, issuer);
|
||||
persistOidcAuthenticatedSettings(clientId, issuer, idTokenClaims);
|
||||
return true;
|
||||
} catch (error) {
|
||||
logger.error("Failed to login via OIDC", error);
|
||||
|
Reference in New Issue
Block a user