Little tweaks

This commit is contained in:
2025-05-22 05:55:33 +02:00
parent c7ff39169a
commit 2717651189
16 changed files with 51 additions and 20 deletions

View File

@@ -28,6 +28,8 @@ class TestCspConfigurationConsistency(unittest.TestCase):
return True
if entry.startswith(('data:', 'blob:')):
return True
if entry == '*':
return True
parsed = urlparse(entry)
return parsed.scheme in ('http', 'https') and bool(parsed.netloc)

View File

@@ -181,7 +181,7 @@ class TestCspFilters(unittest.TestCase):
# Expect '*.domain-example.com' in the frame-ancestors directive
self.assertRegex(
header,
r"frame-ancestors\s+'self'\s+\*\.domain-example\.com;"
r"frame-ancestors\s+'self'\s+domain-example\.com;"
)
# Now disable the feature and rebuild