Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1161)

Unified Diff: net/http/http_util.cc

Issue 2097263002: Deprecate Net.{HttpRequest,Response}.ContainsInvalidHeaderValuesInRFC7230 UMAs (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Remove IsValidHeaderValueRFC7230(). Created 4 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « net/http/http_util.h ('k') | net/http/http_util_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/http/http_util.cc
diff --git a/net/http/http_util.cc b/net/http/http_util.cc
index 06fc15edd3668e367d0551cf4314de04beb73c65..dfba045d9bc1c603febf92f6dacaf46db0c741c4 100644
--- a/net/http/http_util.cc
+++ b/net/http/http_util.cc
@@ -353,24 +353,6 @@ bool HttpUtil::IsValidHeaderValue(const std::string& value) {
}
// static
-bool HttpUtil::IsValidHeaderValueRFC7230(const base::StringPiece& value) {
- // This empty string is a valid header-value.
- if (value.empty())
- return true;
-
- // Check leading/trailing whitespaces.
- if (IsLWS(value[0]) || IsLWS(value[value.size() - 1]))
- return false;
-
- // Check each octet is |field-vchar|, |SP| or |HTAB|.
- for (unsigned char c : value) {
- if (c == 0x7F || (c < 0x20 && c != '\t'))
- return false;
- }
- return true;
-}
-
-// static
std::string HttpUtil::StripHeaders(const std::string& headers,
const char* const headers_to_remove[],
size_t headers_to_remove_len) {
« no previous file with comments | « net/http/http_util.h ('k') | net/http/http_util_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698