From f4e385a35017f95c43549bb852d5cab594796a6f Mon Sep 17 00:00:00 2001 From: Frederick Muriuki Muriithi Date: Thu, 25 Jun 2026 14:10:21 -0500 Subject: Clear any related JWT tokens when deleting a client. --- gn_auth/auth/authentication/oauth2/models/oauth2client.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/gn_auth/auth/authentication/oauth2/models/oauth2client.py b/gn_auth/auth/authentication/oauth2/models/oauth2client.py index dfe5d79..b3ec91f 100644 --- a/gn_auth/auth/authentication/oauth2/models/oauth2client.py +++ b/gn_auth/auth/authentication/oauth2/models/oauth2client.py @@ -298,6 +298,8 @@ def delete_client( cursor.execute("DELETE FROM authorisation_code WHERE client_id=?", params) cursor.execute("DELETE FROM oauth2_tokens WHERE client_id=?", params) + cursor.execute("DELETE FROM jwt_refresh_tokens WHERE client_id=?", + params) cursor.execute("DELETE FROM oauth2_clients WHERE client_id=?", params) return the_client -- cgit 1.4.1