Skip to content

Commit

Permalink
try to fix unsafe-eval
Browse files Browse the repository at this point in the history
  • Loading branch information
Kenneth Kehl committed Feb 5, 2025
1 parent 9247614 commit 07c5b96
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 3 deletions.
2 changes: 1 addition & 1 deletion app/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -150,7 +150,7 @@ def _csp(config):
"script-src": [
"'self'",
asset_domain,
"'unsafe-eval'",
# "'unsafe-eval'",
"https://js-agent.newrelic.com",
"https://gov-bam.nr-data.net",
"https://www.googletagmanager.com",
Expand Down
8 changes: 6 additions & 2 deletions notifications_utils/request_helper.py
Original file line number Diff line number Diff line change
Expand Up @@ -80,10 +80,14 @@ def rewrite_response_headers(status, headers, exc_info=None):
headers.append(("Cross-Origin-Embedder-Policy", "require-corp"))
headers.append(("Cross-Origin-Resource-Policy", "same-origin"))
headers.append(("Cross-Origin-Opener-Policy", "same-origin"))
headers.append(("Cache-Control", "no-store, no-cache, must-revalidate, proxy-revalidate"))
headers.append(
(
"Cache-Control",
"no-store, no-cache, must-revalidate, proxy-revalidate",
)
)
headers.append(("Pragma", "no-cache"))


return start_response(status, headers, exc_info)

return self._app(environ, rewrite_response_headers)
Expand Down

0 comments on commit 07c5b96

Please sign in to comment.