summaryrefslogtreecommitdiff
path: root/methods
diff options
context:
space:
mode:
Diffstat (limited to 'methods')
-rw-r--r--methods/http.cc4
1 files changed, 4 insertions, 0 deletions
diff --git a/methods/http.cc b/methods/http.cc
index 2e7fca307..d75e9fe84 100644
--- a/methods/http.cc
+++ b/methods/http.cc
@@ -974,6 +974,10 @@ void HttpMethod::SendReq(FetchItem *Itm)
Req << "User-Agent: " << ConfigFind("User-Agent",
"Debian APT-HTTP/1.3 (" PACKAGE_VERSION ")") << "\r\n";
+ auto const referer = ConfigFind("Referer", "");
+ if (referer.empty() == false)
+ Req << "Referer: " << referer << "\r\n";
+
Req << "\r\n";
if (Debug == true)