mirror of
https://github.com/klzgrad/naiveproxy.git
synced 2024-11-24 06:16:30 +03:00
http: Add padding for CONNECT requests
This commit is contained in:
parent
354190ed29
commit
cee091b0ec
@ -7,6 +7,7 @@
|
|||||||
#include <unordered_set>
|
#include <unordered_set>
|
||||||
|
|
||||||
#include "base/metrics/histogram_macros.h"
|
#include "base/metrics/histogram_macros.h"
|
||||||
|
#include "base/rand_util.h"
|
||||||
#include "base/strings/string_util.h"
|
#include "base/strings/string_util.h"
|
||||||
#include "base/strings/stringprintf.h"
|
#include "base/strings/stringprintf.h"
|
||||||
#include "net/base/host_port_pair.h"
|
#include "net/base/host_port_pair.h"
|
||||||
@ -40,6 +41,8 @@ void ProxyClientSocket::BuildTunnelRequest(
|
|||||||
request_headers->SetHeader(HttpRequestHeaders::kUserAgent, user_agent);
|
request_headers->SetHeader(HttpRequestHeaders::kUserAgent, user_agent);
|
||||||
|
|
||||||
request_headers->MergeFrom(auth_headers);
|
request_headers->MergeFrom(auth_headers);
|
||||||
|
request_headers->SetHeader("Padding",
|
||||||
|
std::string(base::RandInt(16, 32), '.'));
|
||||||
}
|
}
|
||||||
|
|
||||||
// static
|
// static
|
||||||
|
Loading…
Reference in New Issue
Block a user