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

Unified Diff: net/proxy/proxy_server.cc

Issue 2832057: Add some plumbing for in-progress work on enabling SSL proxy support.... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 10 years, 5 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/proxy/proxy_server.h ('k') | net/proxy/proxy_server_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/proxy/proxy_server.cc
===================================================================
--- net/proxy/proxy_server.cc (revision 52951)
+++ net/proxy/proxy_server.cc (working copy)
@@ -34,6 +34,8 @@
return ProxyServer::SCHEME_SOCKS5;
if (LowerCaseEqualsASCII(begin, end, "direct"))
return ProxyServer::SCHEME_DIRECT;
+ if (LowerCaseEqualsASCII(begin, end, "https"))
+ return ProxyServer::SCHEME_HTTPS;
return ProxyServer::SCHEME_INVALID;
}
@@ -53,6 +55,8 @@
return ProxyServer::SCHEME_SOCKS5;
if (LowerCaseEqualsASCII(begin, end, "direct"))
return ProxyServer::SCHEME_DIRECT;
+ if (LowerCaseEqualsASCII(begin, end, "https"))
+ return ProxyServer::SCHEME_HTTPS;
return ProxyServer::SCHEME_INVALID;
}
@@ -132,6 +136,8 @@
return std::string("socks4://") + host_and_port();
case SCHEME_SOCKS5:
return std::string("socks5://") + host_and_port();
+ case SCHEME_HTTPS:
+ return std::string("https://") + host_and_port();
default:
// Got called with an invalid scheme.
NOTREACHED();
@@ -180,6 +186,8 @@
return std::string("SOCKS ") + host_and_port();
case SCHEME_SOCKS5:
return std::string("SOCKS5 ") + host_and_port();
+ case SCHEME_HTTPS:
+ return std::string("HTTPS ") + host_and_port();
default:
// Got called with an invalid scheme.
NOTREACHED();
@@ -195,6 +203,8 @@
case SCHEME_SOCKS4:
case SCHEME_SOCKS5:
return 1080;
+ case SCHEME_HTTPS:
+ return 443;
default:
return -1;
}
« no previous file with comments | « net/proxy/proxy_server.h ('k') | net/proxy/proxy_server_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698