From 2e77a7593af1371a9990d09bfd4e2a315d77f24e Mon Sep 17 00:00:00 2001 From: Daghan Altas Date: Sun, 29 Dec 2019 15:06:33 +0100 Subject: [PATCH] improving set_cookie security --- app/main/views.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/main/views.py b/app/main/views.py index ba64937c..0835813c 100755 --- a/app/main/views.py +++ b/app/main/views.py @@ -1904,7 +1904,7 @@ def set_cookie(): settings['language'] = 'en' settings['font_size'] = '10' response = make_response("RadhaKrishna") - response.set_cookie('settings', json.dumps(settings)) + response.set_cookie('settings', json.dumps(settings), secure=True, httponly=True, samesite='Lax') return response