File tree Expand file tree Collapse file tree 4 files changed +7
-0
lines changed
Expand file tree Collapse file tree 4 files changed +7
-0
lines changed Original file line number Diff line number Diff line change @@ -247,6 +247,8 @@ CROSS_DOMAIN_CSRF_COOKIE_NAME: csrftoken
247247CSRF_COOKIE_SECURE : true
248248CSRF_TRUSTED_ORIGINS :
249249- https://*.localhost
250+ CSRF_TRUSTED_ORIGINS_WITH_SCHEME :
251+ - https://*.localhost
250252DATABASES :
251253 blockstore :
252254 CONN_MAX_AGE : 600
Original file line number Diff line number Diff line change @@ -155,6 +155,7 @@ def get_env_setting(setting):
155155# Once we have migrated to service assets off S3, then we can convert this back to
156156# managed by the yaml file contents
157157STATICFILES_STORAGE = os .environ .get ('STATICFILES_STORAGE' , STATICFILES_STORAGE )
158+ CSRF_TRUSTED_ORIGINS = _YAML_TOKENS .get ('CSRF_TRUSTED_ORIGINS_WITH_SCHEME' , [])
158159
159160MKTG_URL_LINK_MAP .update (_YAML_TOKENS .get ('MKTG_URL_LINK_MAP' , {}))
160161
Original file line number Diff line number Diff line change @@ -330,6 +330,8 @@ CROSS_DOMAIN_CSRF_COOKIE_NAME: ''
330330CSRF_COOKIE_SECURE : true
331331CSRF_TRUSTED_ORIGINS :
332332- https://*.sandbox.localhost
333+ CSRF_TRUSTED_ORIGINS_WITH_SCHEME :
334+ - https://*.sandbox.localhost
333335DASHBOARD_COURSE_LIMIT : 250
334336DATABASES :
335337 blockstore :
Original file line number Diff line number Diff line change @@ -197,6 +197,8 @@ def get_env_setting(setting):
197197 service_variant = SERVICE_VARIANT ,
198198)
199199
200+ CSRF_TRUSTED_ORIGINS = _YAML_TOKENS .get ('CSRF_TRUSTED_ORIGINS_WITH_SCHEME' , [])
201+
200202if FEATURES ['ENABLE_CORS_HEADERS' ] or FEATURES .get ('ENABLE_CROSS_DOMAIN_CSRF_COOKIE' ):
201203 CORS_ALLOW_CREDENTIALS = True
202204 CORS_ORIGIN_WHITELIST = _YAML_TOKENS .get ('CORS_ORIGIN_WHITELIST' , ())
You can’t perform that action at this time.
0 commit comments