# OAuth Token revocation

* adds revocation of user tokens on logout
This commit is contained in:
2024-12-23 09:26:14 +01:00
parent fa89bbba99
commit 1c24cbea26
2 changed files with 24 additions and 0 deletions

View File

@@ -24,5 +24,10 @@ class LogoutView(View):
Returns:
A redirect
"""
user = request.user
oauth_token = user.oauth_token
if oauth_token:
oauth_token.revoke()
logout(request)
return redirect(SSO_SERVER_BASE)