mirror of
https://github.com/PurpleI2P/i2pd.git
synced 2025-01-22 04:04:16 +00:00
strip connection http header
This commit is contained in:
parent
803f11bebb
commit
136b663cef
@ -204,14 +204,14 @@ namespace proxy
|
|||||||
if (eol)
|
if (eol)
|
||||||
{
|
{
|
||||||
*eol = 0; eol++;
|
*eol = 0; eol++;
|
||||||
if (strncmp ((const char *)http_buff, "Referer", 7)) // strip out referer
|
if (strncmp ((const char *)http_buff, "Referer", 7) && strncmp ((const char *)http_buff, "Connection", 10)) // strip out referer and connection
|
||||||
{
|
{
|
||||||
if (!strncmp ((const char *)http_buff, "User-Agent", 10)) // replace UserAgent
|
if (!strncmp ((const char *)http_buff, "User-Agent", 10)) // replace UserAgent
|
||||||
m_request.append("User-Agent: MYOB/6.66 (AN/ON)");
|
m_request.append("User-Agent: MYOB/6.66 (AN/ON)");
|
||||||
else
|
else
|
||||||
m_request.append ((const char *)http_buff);
|
m_request.append ((const char *)http_buff);
|
||||||
m_request.append ("\r\n");
|
m_request.append ("\r\n");
|
||||||
}
|
}
|
||||||
isEndOfHeader = !http_buff[0];
|
isEndOfHeader = !http_buff[0];
|
||||||
auto l = eol - http_buff;
|
auto l = eol - http_buff;
|
||||||
http_buff = eol;
|
http_buff = eol;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user