Chromium Code Reviews| Index: net/base/escape.h |
| diff --git a/net/base/escape.h b/net/base/escape.h |
| index c31dcf9aa2250899e76da977b168a9aafc82c596..f75d4502bc311b9a2cf24b71d53ed54241ce5b64 100644 |
| --- a/net/base/escape.h |
| +++ b/net/base/escape.h |
| @@ -93,6 +93,12 @@ class UnescapeRule { |
| // interpreting as a URL and want to do as much unescaping as possible. |
| URL_SPECIAL_CHARS = 4, |
| + // Subset of "URL_SPECIAL_CHARS" - excludes '/' and '\\'. For use with file |
| + // URLs. |
| + // TODO(mmenke): Should GURL unescape those two characters for file URLs? |
| + // that's what FireFox and IE do. |
|
eroman
2016/02/18 19:37:28
Worth noting the obvious, that there are compatibi
mmenke
2016/02/18 20:30:22
Actually, I'm thinking that the compatibility and
|
| + URL_SPECIAL_CHARS_EXCEPT_PATH_SEPERATORS = 8, |
| + |
| // Unescapes characters that can be used in spoofing attempts (such as LOCK) |
| // and control characters (such as BiDi control characters and %01). This |
| // INCLUDES NULLs. This is used for rare cases such as data: URL decoding |
| @@ -100,10 +106,10 @@ class UnescapeRule { |
| // |
| // DO NOT use SPOOFING_AND_CONTROL_CHARS if the URL is going to be displayed |
| // in the UI for security reasons. |
| - SPOOFING_AND_CONTROL_CHARS = 8, |
| + SPOOFING_AND_CONTROL_CHARS = 16, |
|
eroman
2016/02/18 19:37:28
optional style: I find the 1 << X notation simpler
mmenke
2016/02/18 20:30:22
SGTM, done.
|
| // URL queries use "+" for space. This flag controls that replacement. |
| - REPLACE_PLUS_WITH_SPACE = 16, |
| + REPLACE_PLUS_WITH_SPACE = 32, |
| }; |
| }; |