From 94a6ad8af54f7752fd35ca2627bb0bdd10d072c4 Mon Sep 17 00:00:00 2001 From: harada Date: Mon, 25 Mar 2019 16:02:00 +0900 Subject: [PATCH 2/3] Fullwidth characters enclosed in lt and gt. --- lib/redmine/wiki_formatting/textile/redcloth3.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/redmine/wiki_formatting/textile/redcloth3.rb b/lib/redmine/wiki_formatting/textile/redcloth3.rb index 34669d853..3f05fbb34 100644 --- a/lib/redmine/wiki_formatting/textile/redcloth3.rb +++ b/lib/redmine/wiki_formatting/textile/redcloth3.rb @@ -1215,6 +1215,6 @@ class RedCloth3 < String ALLOWED_TAGS = %w(redpre pre code kbd notextile) def escape_html_tags(text) - text.gsub!(%r{<(\/?([!\w]+)[^<>\n]*)(>?)}) {|m| ALLOWED_TAGS.include?($2) ? "<#{$1}#{$3}" : "<#{$1}#{'>' unless $3.blank?}" } + text.gsub!(%r{<(\/?([!_[[:alnum:]]]+)[^<>\n]*)(>?)}) {|m| ALLOWED_TAGS.include?($2) ? "<#{$1}#{$3}" : "<#{$1}#{'>' unless $3.blank?}" } end end -- 2.21.0