Browse code

libclamav/mbox.c: mail-follow-urls was not RFC compliant (bb#1192)

git-svn: trunk@4184

Tomasz Kojm authored on 2008/09/17 17:52:58
Showing 2 changed files
... ...
@@ -1,3 +1,7 @@
1
+Wed Sep 17 10:59:48 CEST 2008 (tk)
2
+----------------------------------
3
+  * libclamav/mbox.c: mail-follow-urls was not RFC compliant (bb#1192)
4
+
1 5
 Sun Sep 14 17:20:14 EEST 2008 (edwin)
2 6
 -------------------------------------
3 7
   * clamd/thrmgr.c: fix valgrind warning (bb #1184)
... ...
@@ -4365,12 +4365,12 @@ getURL(struct arg *arg)
4365 4365
 	 */
4366 4366
 	if(via_proxy)
4367 4367
 		snprintf(buf, sizeof(buf) - 1,
4368
-			"GET %s HTTP/1.0\r\nUser-Agent: ClamAV %s\r\n\r\n",
4369
-				url, cl_retver());
4368
+			"GET %s HTTP/1.0\r\nHost: %s\r\nUser-Agent: ClamAV %s\r\n\r\n",
4369
+				url, site, cl_retver());
4370 4370
 	else
4371 4371
 		snprintf(buf, sizeof(buf) - 1,
4372
-			"GET /%s HTTP/1.0\r\nUser-Agent: ClamAV %s\r\n\r\n",
4373
-				url, cl_retver());
4372
+			"GET /%s HTTP/1.0\r\nHost: %s\r\nUser-Agent: ClamAV %s\r\n\r\n",
4373
+				url, site, cl_retver());
4374 4374
 
4375 4375
 	/*cli_dbgmsg("%s", buf);*/
4376 4376