mirror of
https://github.com/Tautulli/Tautulli.git
synced 2025-07-30 11:38:36 -07:00
Expire the previous JWT on update if HTTP root is set
* Required for Tautulli/Tautulli-Issues#255
This commit is contained in:
parent
ff887d9948
commit
48f846da40
3 changed files with 13 additions and 3 deletions
|
@ -296,10 +296,14 @@ class AuthController(object):
|
|||
self.on_logout(payload['user'], payload['user_group'])
|
||||
|
||||
jwt_cookie = str(JWT_COOKIE_NAME + plexpy.CONFIG.PMS_UUID)
|
||||
cherrypy.response.cookie[jwt_cookie] = 'expire'
|
||||
cherrypy.response.cookie[jwt_cookie] = ''
|
||||
cherrypy.response.cookie[jwt_cookie]['expires'] = 0
|
||||
cherrypy.response.cookie[jwt_cookie]['path'] = plexpy.HTTP_ROOT.rstrip('/') or '/'
|
||||
|
||||
if plexpy.HTTP_ROOT != '/':
|
||||
# Aslo expire the JWT on the root path
|
||||
cherrypy.response.headers['Set-Cookie'] = jwt_cookie + '=""; expires=Thu, 01 Jan 1970 12:00:00 GMT; path=/'
|
||||
|
||||
cherrypy.request.login = None
|
||||
|
||||
if redirect_uri:
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue