We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents d11cb91 + e345d7d commit cc3cc1fCopy full SHA for cc3cc1f
ruby/ql/src/experimental/cwe-176/examples/unicode_normalization.rb
@@ -1,7 +1,7 @@
1
class UnicodeNormalizationHtMLSafeController < ActionController::Base
2
def unicodeNormalize
3
unicode_input = params[:unicode_input]
4
- unicode_html_safe = unicode_input.html_safe
+ unicode_html_safe = CGI.escapeHTML(unicode_input).html_safe
5
normalized_nfkc = unicode_html_safe.unicode_normalize(:nfkc) # $result=BAD
6
normalized_nfc = unicode_html_safe.unicode_normalize(:nfc) # $result=BAD
7
end
0 commit comments