Skip to content

Commit c190b32

Browse files
committed
test: fix encoding in the unicode XSS test
See flavorjones/loofah#205 for a short history of this test string. Related to #111
1 parent becbad0 commit c190b32

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

test/sanitizer_test.rb

+1-1
Original file line numberDiff line numberDiff line change
@@ -414,7 +414,7 @@ def test_should_sanitize_img_dynsrc_lowsrc
414414
end
415415

416416
def test_should_sanitize_div_background_image_unicode_encoded
417-
raw = %(background-image:\0075\0072\006C\0028'\006a\0061\0076\0061\0073\0063\0072\0069\0070\0074\003a\0061\006c\0065\0072\0074\0028.1027\0058.1053\0053\0027\0029'\0029)
417+
raw = %(background-image:\u0075\u0072\u006C\u0028'\u006a\u0061\u0076\u0061\u0073\u0063\u0072\u0069\u0070\u0074\u003a\u0061\u006c\u0065\u0072\u0074\u0028.1027\u0058.1053\u0053\u0027\u0029'\u0029)
418418
assert_equal '', sanitize_css(raw)
419419
end
420420

0 commit comments

Comments
 (0)