Fix(Auth): Flask Samesite attribute must be 'Lax' for OAuth login callback
This commit is contained in:
@@ -40,7 +40,7 @@ class Config:
|
||||
# Auth0
|
||||
SESSION_COOKIE_SECURE = True
|
||||
SESSION_COOKIE_HTTPONLY = True
|
||||
SESSION_COOKIE_SAMESITE = 'Strict'
|
||||
SESSION_COOKIE_SAMESITE = 'Lax' # 'Strict' # Strict is preferable for security, but Lax is required for OAuth functionality
|
||||
REMEMBER_COOKIE_SECURE = True
|
||||
# PERMANENT_SESSION_LIFETIME = 3600
|
||||
WTF_CSRF_ENABLED = True
|
||||
|
||||
@@ -24738,6 +24738,14 @@ VALUES
|
||||
, 'tierneybailey13@gmail.com' -- email
|
||||
, 1 -- is_super_user
|
||||
, 1 -- active
|
||||
),
|
||||
(
|
||||
'auth0|679cc2fe0d652a47af90d16b' -- id_user_auth0
|
||||
, 'Demo' -- firstname
|
||||
, '' -- surname
|
||||
, 'bot@partsltd.co.uk' -- email
|
||||
, 0 -- is_super_user
|
||||
, 1 -- active
|
||||
)
|
||||
;
|
||||
|
||||
|
||||
@@ -900,6 +900,14 @@ VALUES
|
||||
, 'tierneybailey13@gmail.com' -- email
|
||||
, 1 -- is_super_user
|
||||
, 1 -- active
|
||||
),
|
||||
(
|
||||
'auth0|679cc2fe0d652a47af90d16b' -- id_user_auth0
|
||||
, 'Demo' -- firstname
|
||||
, '' -- surname
|
||||
, 'bot@partsltd.co.uk' -- email
|
||||
, 0 -- is_super_user
|
||||
, 1 -- active
|
||||
)
|
||||
;
|
||||
|
||||
|
||||
14
static/MySQL/deprecated/9001_add_user.sql
Normal file
14
static/MySQL/deprecated/9001_add_user.sql
Normal file
@@ -0,0 +1,14 @@
|
||||
USE partsltd_prod;
|
||||
|
||||
INSERT INTO Shop_User (
|
||||
id_user_auth0
|
||||
, firstname
|
||||
, surname
|
||||
, email
|
||||
, is_super_user
|
||||
, active
|
||||
)
|
||||
VALUES ( 'auth0|679cc2fe0d652a47af90d16b' , 'Demo' , '' , 'bot@partsltd.co.uk' , 0 , 1 );
|
||||
|
||||
INSERT INTO Shop_User_Role_Link ( id_user, id_role )
|
||||
VALUES (4, 2);
|
||||
Reference in New Issue
Block a user