Skip to content

Commit

Permalink
Merge pull request #1634 from muffinresearch/enforce-csp
Browse files Browse the repository at this point in the history
Enforce CSP in Production
  • Loading branch information
muffinresearch committed Feb 8, 2016
2 parents 8f2a628 + f3a1c4b commit 1a2d8f7
Show file tree
Hide file tree
Showing 3 changed files with 1 addition and 3 deletions.
1 change: 0 additions & 1 deletion settings.py
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,6 @@
}

# CSP report endpoint which returns a 204 from addons-nginx in local dev.
CSP_REPORT_ONLY = False
CSP_REPORT_URI = '/csp-report'

# Allow GA over http + www subdomain in local development.
Expand Down
1 change: 0 additions & 1 deletion src/olympia/conf/dev/settings.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,6 @@

# Allow addons-dev CDN for CSP.
DEV_CDN_HOST = 'https://addons-dev-cdn.allizom.org'
CSP_REPORT_ONLY = False
CSP_FONT_SRC += (DEV_CDN_HOST,)
CSP_FRAME_SRC += ('https://www.sandbox.paypal.com',)
CSP_IMG_SRC += (DEV_CDN_HOST,)
Expand Down
2 changes: 1 addition & 1 deletion src/olympia/lib/settings_base.py
Original file line number Diff line number Diff line change
Expand Up @@ -1274,7 +1274,7 @@ def JINJA_CONFIG():
ANALYTICS_HOST = 'https://ssl.google-analytics.com'

CSP_REPORT_URI = '/__cspreport__'
CSP_REPORT_ONLY = True
CSP_REPORT_ONLY = False
CSP_EXCLUDE_URL_PREFIXES = ()

# NOTE: CSP_DEFAULT_SRC MUST be set otherwise things not set
Expand Down

0 comments on commit 1a2d8f7

Please sign in to comment.