From c0c26ca0740cfdb0ab53e852dde43aff2ff357e0 Mon Sep 17 00:00:00 2001 From: ldm0 Date: Sun, 4 Oct 2026 08:51:26 +0800 Subject: [PATCH] test(csp): cover encoded commas across policy parsing and URL matching --- moli-renderer-v8/src/content_security_policy.rs | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/moli-renderer-v8/src/content_security_policy.rs b/moli-renderer-v8/src/content_security_policy.rs index c2c32f2ab3..0b6bcb7d83 100644 --- a/moli-renderer-v8/src/content_security_policy.rs +++ b/moli-renderer-v8/src/content_security_policy.rs @@ -2224,6 +2224,11 @@ mod tests { "https://cdn.test/foo%2cbar", true, ), + ( + "img-src https://cdn.test/foo%2cbar", + "https://cdn.test/foo,bar", + true, + ), ( ", , img-src * , , img-src 'none', ,", "https://cdn.test/asset",