You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
By default, if you're using JWT and Token Blacklist, the Logout view tries to find the Refresh token in the request body. However, if I am using HttpOnly cookie, my Refresh token wouldn't be in the request body.
It can be fixed by changing:
if 'rest_framework_simplejwt.token_blacklist' in settings.INSTALLED_APPS:
# add refresh token to blacklist
try:
token = RefreshToken(request.get['refresh'])
to
if 'rest_framework_simplejwt.token_blacklist' in settings.INSTALLED_APPS:
# add refresh token to blacklist
try:
token = RefreshToken(request.COOKIES['refresh_token'])
But it is quite cumbersome to define my own view for one line of change. Please consider making this change to the codebase.
The text was updated successfully, but these errors were encountered:
By default, if you're using JWT and Token Blacklist, the Logout view tries to find the Refresh token in the request body. However, if I am using HttpOnly cookie, my Refresh token wouldn't be in the request body.
It can be fixed by changing:
to
But it is quite cumbersome to define my own view for one line of change. Please consider making this change to the codebase.
The text was updated successfully, but these errors were encountered: