Skip to content
Snippets Groups Projects
Commit 32d6fe32 authored by Chris Hines's avatar Chris Hines
Browse files

make cookies SameSite=strict in the hopes that safari will start sending them

parent baf4c207
No related branches found
No related tags found
3 merge requests!77Revert "disable agressive kill and restart",!35Dev,!13Dev
Pipeline #7621 passed
...@@ -475,7 +475,7 @@ class CreateTunnel(Resource): ...@@ -475,7 +475,7 @@ class CreateTunnel(Resource):
localbind=localbind, authtok=authtok) localbind=localbind, authtok=authtok)
response = make_response("") response = make_response("")
response.mime_type = 'application/json' response.mime_type = 'application/json'
response.set_cookie('twsproxyauth', authtok, httponly=True) response.set_cookie('twsproxyauth', authtok, httponly=True,samesite='Strict')
logger.debug('JobConnect.connect: connecting via redirect with cookie authtok set to {}'.format(authtok)) logger.debug('JobConnect.connect: connecting via redirect with cookie authtok set to {}'.format(authtok))
return response return response
......
...@@ -94,7 +94,7 @@ class TWSProxy(threading.Thread): ...@@ -94,7 +94,7 @@ class TWSProxy(threading.Thread):
initshutdown.clear() initshutdown.clear()
(header, bytessofar) = self.inittws(initshutdown) (header, bytessofar) = self.inittws(initshutdown)
if self.authtok is not None: if self.authtok is not None:
replyheader = b'Set-Cookie: twsproxyauth2='+self.authtok+b' ; HttpOnly\r\n' replyheader = b'Set-Cookie: twsproxyauth2='+self.authtok+b' ; HttpOnly; SameSite=Strict\r\n'
else: else:
replyheader = None replyheader = None
insertafter = b'HTTP/1.1 200 OK\r\n' insertafter = b'HTTP/1.1 200 OK\r\n'
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment