auth_oidc: get a lock on the sub during authentication (#65412)

This commit is contained in:
Benjamin Dauvergne 2022-07-07 13:05:56 +02:00
parent e6d3cbe808
commit 55a2c56130
1 changed files with 2 additions and 0 deletions

View File

@ -232,6 +232,8 @@ class OIDCBackend(ModelBackend):
if attribute == 'email':
email = value
Lock.lock_identifier(identifier=id_token.sub)
User = get_user_model()
user = None
if provider.strategy == models.OIDCProvider.STRATEGY_FIND_UUID: