std::string default_host;
int max_redirects;
bool x_forwarded_for;
+ bool bind_host;
Rep();
};
}
{
max_redirects = 0;
x_forwarded_for = false;
+ bind_host = false;
}
yf::HTTPClient::HTTPClient() : m_p(new Rep)
}
else
uri = hreq->path;
+
+
+ if (bind_host)
+ {
+ std::string host = package.origin().get_bind_address();
+ uri.append(" ");
+ uri.append(host);
+ }
Z_HTTP_Response *http_response = 0;
if (uri.length())
http_response =
{
m_p->x_forwarded_for = mp::xml::get_bool(ptr, 0);
}
+ else if (!strcmp((const char *) ptr->name, "bind_host"))
+ {
+ m_p->bind_host = mp::xml::get_bool(ptr, 0);
+ }
else
{
throw mp::filter::FilterException