fix:zap-report
This commit is contained in:
1 parent
9e52cfc16f
commit
c7d622f4e3
5 files changed
+29
-4
No files matched your search
@@ -189,7 +189,9 @@ def test_security_headers_on_all_kinds_of_responses(app: Any) -> None:
|
||||
assert "script-src 'self'" in headers["Content-Security-Policy"], path
|
||||
assert headers["Referrer-Policy"] == "same-origin", path
|
||||
assert "server" not in headers, path
|
||||
if not path.startswith("/static/"):
|
||||
if path.startswith("/static/"):
|
||||
assert headers["Cache-Control"] == "public, no-cache", path
|
||||
else:
|
||||
assert headers["Cache-Control"] == "no-store", path
|
||||
html = client.get("/login").text
|
||||
assert "<script>" not in html and " style=" not in html and "onclick" not in html
|
||||
|
||||
Reference in new issue
Block a user