Security: Update to Rails 2.3.14

This commit is contained in:
Jacques Distler 2011-08-19 01:54:58 -05:00
parent 3c650f2cf6
commit 4b2448b09a
26 changed files with 106 additions and 33 deletions

View file

@ -5,6 +5,13 @@ class SanitizerTest < ActionController::TestCase
@sanitizer = nil # used by assert_sanitizer
end
def test_strip_tags_with_quote
sanitizer = HTML::FullSanitizer.new
string = '<" <img src="trollface.gif" onload="alert(1)"> hi'
assert_equal ' hi', sanitizer.sanitize(string)
end
def test_strip_tags
sanitizer = HTML::FullSanitizer.new
assert_equal("<<<bad html", sanitizer.sanitize("<<<bad html"))