1
0
mirror of https://github.com/dkmstr/openuds.git synced 2024-12-22 13:34:04 +03:00

Fixed ticket access in restricted mode

This commit is contained in:
Adolfo Gómez García 2023-07-14 13:48:55 +02:00
parent b614c8fff6
commit 0173a06411
No known key found for this signature in database
GPG Key ID: DD1ABF20724CDA23
2 changed files with 3 additions and 2 deletions

View File

@ -250,7 +250,9 @@ def ticketAuth(
usr # Temporarily store this user as "authenticated" user, next requests will be done using session
)
request.authorized = True # User is authorized
request.session['ticket'] = '1' # Store that user access is done using ticket
# Set restricted access (no allow to see other services, logout automatically if user tries to access other service, ...)
request.session['restricted'] = True # Access is from ticket
# Transport must always be automatic for ticket authentication

View File

@ -89,7 +89,6 @@ def index(request: HttpRequest) -> HttpResponse:
# Includes a request.session ticket, indicating that
@never_cache
def ticketLauncher(request: HttpRequest) -> HttpResponse:
request.session['restricted'] = True # Access is from ticket
return index(request)