diff options
author | Timothy N. Tsvetkov <timothy.tsvetkov@gmail.com> | 2010-11-24 00:17:05 +0300 |
---|---|---|
committer | Santiago Pastorino <santiago@wyeworks.com> | 2010-12-30 22:43:43 -0200 |
commit | e5b84fd72358deddd29c515aacab7edf2643908e (patch) | |
tree | 9aa4c81e85567bc9082d2b251d0771c96dabb155 /actionpack/lib/action_controller/vendor/html-scanner/html | |
parent | 573fd39e22b3d278457fa764c107095808b361fe (diff) | |
download | rails-e5b84fd72358deddd29c515aacab7edf2643908e.tar.gz rails-e5b84fd72358deddd29c515aacab7edf2643908e.tar.bz2 rails-e5b84fd72358deddd29c515aacab7edf2643908e.zip |
ActionController::Base.helpers.sanitize ignores case in protocol
[#6044 state:committed]
Signed-off-by: Santiago Pastorino <santiago@wyeworks.com>
Diffstat (limited to 'actionpack/lib/action_controller/vendor/html-scanner/html')
-rw-r--r-- | actionpack/lib/action_controller/vendor/html-scanner/html/sanitizer.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/actionpack/lib/action_controller/vendor/html-scanner/html/sanitizer.rb b/actionpack/lib/action_controller/vendor/html-scanner/html/sanitizer.rb index 3e5d23b5c1..09dd08898c 100644 --- a/actionpack/lib/action_controller/vendor/html-scanner/html/sanitizer.rb +++ b/actionpack/lib/action_controller/vendor/html-scanner/html/sanitizer.rb @@ -170,7 +170,7 @@ module HTML def contains_bad_protocols?(attr_name, value) uri_attributes.include?(attr_name) && - (value =~ /(^[^\/:]*):|(�*58)|(p)|(%|%)3A/ && !allowed_protocols.include?(value.split(protocol_separator).first)) + (value =~ /(^[^\/:]*):|(�*58)|(p)|(%|%)3A/ && !allowed_protocols.include?(value.split(protocol_separator).first.downcase)) end end end |