Index: components/url_formatter/url_formatter.cc |
diff --git a/components/url_formatter/url_formatter.cc b/components/url_formatter/url_formatter.cc |
index d54b67913ce76d400907266963475bae6920cdd9..8f9bfe39018cb4bf6bb4174366d76c6e11e14ed7 100644 |
--- a/components/url_formatter/url_formatter.cc |
+++ b/components/url_formatter/url_formatter.cc |
@@ -415,6 +415,7 @@ bool IDNSpoofChecker::Check(base::StringPiece16 label, bool is_tld_ascii) { |
// - Disallow U+0585 (Armenian Small Letter Oh) and U+0581 (Armenian Small |
// Letter Co) to be next to Latin. |
// - Disallow Latin 'o' and 'g' next to Armenian. |
+ // - Disalow mixing of Latin and Canadian Syllabary. |
dangerous_pattern = new icu::RegexMatcher( |
icu::UnicodeString( |
"[^\\p{scx=kana}\\p{scx=hira}\\p{scx=hani}]" |
@@ -428,7 +429,8 @@ bool IDNSpoofChecker::Check(base::StringPiece16 label, bool is_tld_ascii) { |
"^[\\u0585\\u0581]+[a-z]|[a-z][\\u0585\\u0581]+$|" |
"[a-z][\\u0585\\u0581]+[a-z]|" |
"^[og]+[\\p{scx=armn}]|[\\p{scx=armn}][og]+$|" |
- "[\\p{scx=armn}][og]+[\\p{scx=armn}]", |
+ "[\\p{scx=armn}][og]+[\\p{scx=armn}]|" |
+ "[\\p{sc=cans}].*[a-z]|[a-z].*[\\p{sc=cans}]", |
-1, US_INV), |
0, status); |
tls_index.Set(dangerous_pattern); |