2
0
mirror of https://github.com/inventree/InvenTree.git synced 2025-07-18 18:56:31 +00:00

switch to browser based sessions

This commit is contained in:
Matthias Mair
2025-01-08 13:55:20 +01:00
parent ea940e8c58
commit d482b3677f
3 changed files with 16 additions and 8 deletions
src
backend
InvenTree
users
frontend
src

@@ -5,6 +5,7 @@ import datetime
from django.contrib.auth import get_user, login
from django.contrib.auth.models import Group, User
from django.urls import include, path, re_path
from django.views.decorators.csrf import ensure_csrf_cookie
from django.views.generic.base import RedirectView
import structlog
@@ -330,7 +331,7 @@ class LoginRedirect(RedirectView):
user_urls = [
path('roles/', RoleDetails.as_view(), name='api-user-roles'),
path('token/', GetAuthToken.as_view(), name='api-token'),
path('token/', ensure_csrf_cookie(GetAuthToken.as_view()), name='api-token'),
path(
'tokens/',
include([