Occasionally HTTP headers seem to leak into the page body as seen in the attached screenshots. This only seems to happen quite rarely though, maybe 1 page in 20 or more. Viewing the source of the page shows the headers in it as well. I have only tried this while behind a Squid proxy so far. This bug appears to be related to http://bugs.webkit.org/show_bug.cgi?id=4619 This bug also appears on my companies website (http://www.advfn.com/p.php?pid=sitemap is a good page to try it on) we do not run mod_layout.
Created attachment 14544 [details] Displaying headers on an empty 302 redirect page.
Created attachment 14545 [details] Headers being displayed on a fairly normal page.
Created attachment 14546 [details] Packet dump of session where 1 request displayed headers in the page The first couple of hits to http://www.advfn.com/p.php?pid=sitemap&cb=1179150783 where fine, the last one had headers in it.
Comment on attachment 14546 [details] Packet dump of session where 1 request displayed headers in the page I suck and didn't set the snaplen :-/
Created attachment 14547 [details] Packet dump during which headers are displayed. The last hit to http://www.advfn.com/p.php?pid=sitemap&cb=1179150783 had headers displayed in it.
Based on the packet trace it appears something is sending buggy HTTP responses. There are two responses in which the Content-Length mentioned in the header does not match the apparent length of the data: ('192.168.0.13', '192.168.0.52', 3128, 55552) HTTP/1.0 200 OK Server: Mathopd/1.5p5 Date: Mon, 14 May 2007 14:00:31 GMT Content-Type: text/css Content-Length: 28623 Last-Modified: Wed, 04 Apr 2007 08:05:32 GMT X-Cache: MISS from localhost.localdomain X-Cache-Lookup: HIT from localhost.localdomain:3128 Proxy-Connection: keep-alive Content-Length header says: 28623 Next response start appears to be at: 23102 and ('192.168.0.13', '192.168.0.52', 3128, 55557) HTTP/1.0 200 OK Server: DCLK-AdSvr Content-Type: text/html Content-Length: 3939 Set-Cookie: test_cookie=CheckForPermission; path=/; domain=.doubleclick.net; expires=Mon, 14 May 2007 14:15:27 GMT P3P: CP="CURa ADMa DEVa PSAo PSDo OUR BUS UNI PUR INT DEM STA PRE COM NAV OTC NOI DSP COR" Cache-Control: no-cache Pragma: no-cache X-Cache: MISS from localhost.localdomain X-Cache-Lookup: MISS from localhost.localdomain:3128 Proxy-Connection: keep-alive Content-Length header says: 3939 Next response start appears to be at: 3940 In the case of the former it looks as though the upstream proxy server starts sending packets from an entirely *different* TCP connection to this port. I can't think of any reasonable explanation for the mixed up packets, but it's very probable that they are the cause of the headers appearing on the page. Squid or any network device along the trip could be to blame.
Closing as INVALID as analysis of the packet trace suggests the response stream is garbled before it reaches Safari.