From toasty@kevinday.com  Sun Jan 19 18:01:09 2003
Return-Path: <toasty@kevinday.com>
Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125])
	by hub.freebsd.org (Postfix) with ESMTP id E93C637B401
	for <FreeBSD-gnats-submit@freebsd.org>; Sun, 19 Jan 2003 18:01:09 -0800 (PST)
Received: from kevinday.com (dsl092-133-142.chi1.dsl.speakeasy.net [66.92.133.142])
	by mx1.FreeBSD.org (Postfix) with ESMTP id 0CBEA43E4A
	for <FreeBSD-gnats-submit@freebsd.org>; Sun, 19 Jan 2003 18:01:09 -0800 (PST)
	(envelope-from toasty@kevinday.com)
Received: from kevinday.com (localhost [127.0.0.1])
	by kevinday.com (8.12.6/8.12.6) with ESMTP id h0K1vcc9057185
	for <FreeBSD-gnats-submit@freebsd.org>; Sun, 19 Jan 2003 19:57:38 -0600 (CST)
	(envelope-from toasty@kevinday.com)
Received: (from toasty@localhost)
	by kevinday.com (8.12.6/8.12.6/Submit) id h0K1vb5a057184;
	Sun, 19 Jan 2003 19:57:37 -0600 (CST)
Message-Id: <200301200157.h0K1vb5a057184@kevinday.com>
Date: Sun, 19 Jan 2003 19:57:37 -0600 (CST)
From: Kevin Day <toasty@dragondata.com>
Reply-To: Kevin Day <toasty@dragondata.com>
To: FreeBSD-gnats-submit@freebsd.org
Cc:
Subject: HTTP_PROXY with libfetch stalls at 99%
X-Send-Pr-Version: 3.113
X-GNATS-Notify:

>Number:         47237
>Category:       bin
>Synopsis:       HTTP_PROXY with libfetch stalls at 99%
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    des
>State:          closed
>Quarter:        
>Keywords:       
>Date-Required:  
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Sun Jan 19 18:10:01 PST 2003
>Closed-Date:    Tue Jun 01 02:25:34 PDT 2004
>Last-Modified:  Tue Jun 01 02:25:34 PDT 2004
>Originator:     Kevin Day
>Release:        FreeBSD 5.0-RELEASE i386
>Organization:
Your.org, Inc.
>Environment:
System: FreeBSD pb.kevinday.com 5.0-RELEASE FreeBSD 5.0-RELEASE #0: Sun Jan 19 09:51:33 CST 2003 root@pb.kevinday.com:/usr/src/sys/i386/compile/PB i386

>Description:

Somewhere between 4.4-RELEASE and 5.0-RELEASE libfetch stopped working with
my HTTP proxy server(listing it using the HTTP_PROXY variable).

Any file that isn't of a trivial length (over 4k?) will get to 99%
completed and hang. ps shows that fetch is waiting in sbwait, but press
SIGINFO doesn't respond with it's normal statistics until you ^C fetch. When
you do ^C it, fetch shows it has only a small number of bytes left in the
download (usually less than 1000).

The HTTP Proxy server in question is the windows HTTP proxy that Hughes uses
for their 2-way DirectWay satellite system. (They expose a HTTP port on the
LAN side of a windows host that other systems on your LAN can use for HTTP
requests through the satellite connection)


>How-To-Repeat:

I can repeat it at will, but I'm guessing others are going to have a tough
time with this. I'm willing to try anything anyone suggests, or give anyone
here ssh access to experiment on their own.

>Fix:



>Release-Note:
>Audit-Trail:

From: Kevin Day <toasty@dragondata.com>
To: freebsd-gnats-submit@freebsd.org, toasty@dragondata.com
Cc:  
Subject: Re: bin/47237: HTTP_PROXY with libfetch stalls at 99%
Date: Sun, 02 Feb 2003 01:55:48 -0600

 With some prodding from <tom@freebsd.org> I narrowed this down a bit more 
 on my own.
 
 
 Getting libfetch from this time:
 
 cvs co -D "Wed Jun 5 10:31:01 2002 UTC " libfetch
 
 Works.
 
 cvs co -D "Wed Jun 5 12:19:08 2002 UTC" libfetch
 
 Does not.
 
 (http.c going from 1.56 to 1.57 during that time)
 
 
 
Responsible-Changed-From-To: freebsd-bugs->des 
Responsible-Changed-By: johan 
Responsible-Changed-When: Mon Feb 3 12:40:29 PST 2003 
Responsible-Changed-Why:  
Over to libfetch maintainer. 

http://www.freebsd.org/cgi/query-pr.cgi?pr=47237 

From: Dag-Erling Smorgrav <des@ofug.org>
To: freebsd-gnats-submit@freebsd.org
Cc:  
Subject: Re: bin/47237: HTTP_PROXY with libfetch stalls at 99%
Date: Mon, 03 Feb 2003 21:51:00 +0100

 I would like to see the output of 'fetch -vvv foo', where foo is a URL
 which exhibits the problem, with both the working and non-working
 version.
 
 DES
 -- 
 Dag-Erling Smorgrav - des@ofug.org

From: Kevin Day <toasty@dragondata.com>
To: freebsd-gnats-submit@freebsd.org, toasty@dragondata.com
Cc: des@ofug.org
Subject: Re: bin/47237: HTTP_PROXY with libfetch stalls at 99%
Date: Tue, 04 Feb 2003 02:44:03 -0600

 >From: Dag-Erling Smorgrav <des@ofug.org>
 >To: freebsd-gnats-submit@freebsd.org
 >Cc:
 >Subject: Re: bin/47237: HTTP_PROXY with libfetch stalls at 99%
 >Date: Mon, 03 Feb 2003 21:51:00 +0100
 >
 >  I would like to see the output of 'fetch -vvv foo', where foo is a URL
 >  which exhibits the problem, with both the working and non-working
 >  version.
 >
 >  DES
 >  --
 >  Dag-Erling Smorgrav - des@ofug.org
 
 
 Ok...
 
 Here is the stock 5.0-RELEASE fetch:
 
 bash-2.05b$ unset HTTP_PROXY
 bash-2.05b$ fetch -vvv -o /dev/null http://www.freebsd.org
 ---> www.freebsd.org:80
 looking up www.freebsd.org
 connecting to www.freebsd.org:80
 requesting http://www.freebsd.org/
  >>> GET / HTTP/1.1
  >>> Host: www.freebsd.org
  >>> User-Agent: fetch libfetch/2.0
  >>> Connection: close
  >>>
 <<< HTTP/1.1 200 OK
 <<< Date: Tue, 04 Feb 2003 08:13:03 GMT
 <<< Server: Apache/1.3.x LaHonda (Unix)
 <<< Last-Modified: Sat, 01 Feb 2003 09:34:35 GMT
 last modified: [2003-02-01 09:34:35]
 <<< ETag: "26fb00-7cc4-3e3b94ab"
 <<< Accept-Ranges: bytes
 <<< Content-Length: 31940
 content length: [31940]
 <<< Connection: close
 <<< Content-Type: text/html
 <<< X-Pad: avoid browser bug
 <<<
 offset 0, length -1, size -1, clength 31940
 local size / mtime: 0 / 1044346260
 remote size / mtime: 31940 / 1044092075
 Receiving /dev/null (31940 bytes): 100%
 31940 bytes transferred in 1.9 seconds (16.33 kBps)
 
 
 
 bash-2.05b$ export HTTP_PROXY="http://66.92.133.148:83"
 bash-2.05b$ fetch -vvv -o /dev/null http://www.freebsd.org
 scheme:   [http]
 user:     []
 password: []
 host:     [66.92.133.148]
 port:     [83]
 document: [/]
 ---> 66.92.133.148:83
 looking up 66.92.133.148
 connecting to 66.92.133.148:83
 requesting http://www.freebsd.org/
  >>> GET http://www.freebsd.org/ HTTP/1.1
  >>> Host: www.freebsd.org
  >>> User-Agent: fetch libfetch/2.0
  >>> Connection: close
  >>>
 <<< HTTP/1.1 200 OK
 <<< Date: Tue, 04 Feb 2003 08:13:34 GMT
 <<< Server: Apache/1.3.x LaHonda (Unix)
 <<< Last-Modified: Sat, 01 Feb 2003 09:34:35 GMT
 last modified: [2003-02-01 09:34:35]
 <<< ETag: "26fb00-7cc4-3e3b94ab"
 <<< Accept-Ranges: bytes
 <<< Content-Length: 31940
 content length: [31940]
 <<< Content-Type: text/html
 <<< X-Pad: avoid browser bug
 <<<
 offset 0, length -1, size -1, clength 31940
 local size / mtime: 0 / 1044346387
 remote size / mtime: 31940 / 1044092075
 Receiving /dev/null (31940 bytes): 38%
 
 (completely dead here, even SIGINFO does nothing)
 
 ^C
 Receiving /dev/null (31940 bytes): 99% (ETA 00:02)
 31744 bytes transferred in 458.1 seconds (69.29 Bps)
 fetch: transfer interrupted
 
 
 $ cvs co -D "Wed Jun 5 10:31:01 2002 UTC " libfetch
 
 (build libfetch)
 
 $ export LD_LIBRARY_PATH="/home/toasty/cvs/libfetch"
 $ fetch -vvv -o /dev/null http://www.freebsd.org
 scheme:   [http]
 user:     []
 password: []
 host:     [66.92.133.148]
 port:     [83]
 document: [/]
 ---> 66.92.133.148:83
 looking up 66.92.133.148
 connecting to 66.92.133.148:83
 requesting http://www.freebsd.org:80/
  >>> GET http://www.freebsd.org:80/ HTTP/1.1
  >>> Host: www.freebsd.org
  >>> User-Agent: fetch libfetch/2.0
  >>> Connection: close
  >>>
 <<< HTTP/1.1 200 OK
 <<< Date: Tue, 04 Feb 2003 08:28:39 GMT
 <<< Server: Apache/1.3.x LaHonda (Unix)
 <<< Last-Modified: Sat, 01 Feb 2003 09:34:35 GMT
 last modified: [2003-02-01 09:34:35]
 <<< ETag: "26fb00-7cc4-3e3b94ab"
 <<< Accept-Ranges: bytes
 <<< Content-Length: 31940
 content length: [31940]
 <<< Content-Type: text/html
 <<< X-Pad: avoid browser bug
 <<<
 offset 0, length -1, size -1, clength 31940
 local size / mtime: 0 / 1044347302
 remote size / mtime: 31940 / 1044092075
 Receiving /dev/null (31940 bytes): 100%
 31940 bytes transferred in 0.3 seconds (108.12 kBps)
 
 
 $ cvs co -D "Wed Jun 5 12:19:08 2002 UTC" libfetch
 
 (rebuild libfetch)
 
 $ fetch -vvv -o /dev/null http://www.freebsd.org
 scheme:   [http]
 user:     []
 password: []
 host:     [66.92.133.148]
 port:     [83]
 document: [/]
 ---> 66.92.133.148:83
 looking up 66.92.133.148
 connecting to 66.92.133.148:83
 requesting http://www.freebsd.org:80/
 <<< HTTP/1.1 200 OK
 <<< Date: Tue, 04 Feb 2003 08:31:46 GMT
 <<< Server: Apache/1.3.x LaHonda (Unix)
 <<< Last-Modified: Sat, 01 Feb 2003 09:34:35 GMT
 last modified: [2003-02-01 09:34:35]
 <<< ETag: "26fb00-7cc4-3e3b94ab"
 <<< Accept-Ranges: bytes
 <<< Content-Length: 31940
 content length: [31940]
 <<< Content-Type: text/html
 <<< X-Pad: avoid browser bug
 <<<
 offset 0, length -1, size -1, clength 31940
 local size / mtime: 0 / 1044347320
 remote size / mtime: 31940 / 1044092075
 Receiving /dev/null (31940 bytes): 64%
 
 (hang)
 
 
 Here's a tcpdump of a small test file:
 
 02:39:06.617520 66.82.9.27.4401 > 66.17.132.249.80: S 
 698240147:698240147(0) win 65535 <mss 1460> (DF)
 0x0000   4500 002c 931b 4000 7106 6439 4252 091b        E..,..@.q.d9BR..
 0x0010   4211 84f9 1131 0050 299e 4c93 0000 0000        B....1.P).L.....
 0x0020   6002 ffff fdfc 0000 0204 05b4 0000             `.............
 02:39:06.617661 66.17.132.249.80 > 66.82.9.27.4401: S 
 1929909310:1929909310(0) ack 698240148 win 65535 <mss 1460> (DF)
 0x0000   4500 002c 365e 4000 4006 f1f6 4211 84f9        E..,6^@.@...B...
 0x0010   4252 091b 0050 1131 7308 143e 299e 4c94        BR...P.1s..>).L.
 0x0020   6012 ffff 76a5 0000 0204 05b4                  `...v.......
 02:39:06.643750 66.82.9.27.4401 > 66.17.132.249.80: . ack 1 win 65535 (DF)
 0x0000   4500 0028 941b 4000 7106 633d 4252 091b        E..(..@.q.c=BR..
 0x0010   4211 84f9 1131 0050 299e 4c94 7308 143f        B....1.P).L.s..?
 0x0020   5010 ffff 8e62 0000 0000 0000 0000             P....b........
 02:39:06.644081 66.82.9.27.4401 > 66.17.132.249.80: P 1:132(131) ack 1 win 
 65535 (DF)
 0x0000   4500 00ab 951b 4000 7106 61ba 4252 091b        E.....@.q.a.BR..
 0x0010   4211 84f9 1131 0050 299e 4c94 7308 143f        B....1.P).L.s..?
 0x0020   5018 ffff b786 0000 4745 5420 6874 7470        P.......GET.http
 0x0030   3a2f 2f77 7777 2e64 7261 676f 6e64 6174        ://www.dragondat
 0x0040   612e 636f 6d3a 3830 2f74 6573 7466 696c        a.com:80/testfil
 0x0050   6520 4854 5450 2f31 2e31 0d0a 486f 7374        e.HTTP/1.1..Host
 0x0060   3a20 7777 772e 6472 6167 6f6e 6461 7461        :.www.dragondata
 0x0070   2e63 6f6d 0d0a 5573 6572 2d41 6765 6e74        .com..User-Agent
 0x0080   3a20 6665 7463 6820 6c69 6266 6574 6368        :.fetch.libfetch
 0x0090   2f32 2e30 0d0a 436f 6e6e 6563 7469 6f6e        /2.0..Connection
 0x00a0   3a20 636c 6f73 650d 0a0d 0a                    :.close....
 02:39:06.646916 66.17.132.249.80 > 66.82.9.27.4401: P 1:238(237) ack 132 
 win 65535 (DF)
 0x0000   4500 0115 3664 4000 4006 f107 4211 84f9        E...6d@.@...B...
 0x0010   4252 091b 0050 1131 7308 143f 299e 4d17        BR...P.1s..?).M.
 0x0020   5018 ffff f332 0000 4854 5450 2f31 2e31        P....2..HTTP/1.1
 0x0030   2032 3030 204f 4b0d 0a44 6174 653a 2054        .200.OK..Date:.T
 0x0040   7565 2c20 3034 2046 6562 2032 3030 3320        ue,.04.Feb.2003.
 0x0050   3038 3a33 393a 3036 2047 4d54 0d0a 5365        08:39:06.GMT..Se
 0x0060   7276 6572 3a20 4170 6163 6865 0d0a 4c61        rver:.Apache..La
 0x0070   7374 2d4d 6f64 6966 6965 643a 2054 7565        st-Modified:.Tue
 0x0080   2c20 3034 2046 6562 2032 3030 3320 3038        ,.04.Feb.2003.08
 0x0090   3a33 333a 3231 2047 4d54 0d0a 4554 6167        :33:21.GMT..ETag
 0x00a0   3a20 2234 3934 3330 362d 362d 3365 3366        :."494306-6-3e3f
 0x00b0   3761 6431 220d 0a41 6363 6570 742d 5261        7ad1"..Accept-Ra
 0x00c0   6e67 6573 3a20 6279 7465 730d 0a43 6f6e        nges:.bytes..Con
 0x00d0   7465 6e74 2d4c 656e 6774 683a 2036 0d0a        tent-Length:.6..
 0x00e0   436f 6e6e 6563 7469 6f6e 3a20 636c 6f73        Connection:.clos
 0x00f0   650d 0a43 6f6e 7465 6e74 2d54 7970 653a        e..Content-Type:
 0x0100   2074 6578 742f 706c 6169 6e0d 0a0d 0a31        .text/plain....1
 0x0110   3233 3435 0a                                   2345.
 02:39:06.647165 66.17.132.249.80 > 66.82.9.27.4401: F 238:238(0) ack 132 
 win 65535 (DF)
 0x0000   4500 0028 3665 4000 4006 f1f3 4211 84f9        E..(6e@.@...B...
 0x0010   4252 091b 0050 1131 7308 152c 299e 4d17        BR...P.1s..,).M.
 0x0020   5011 ffff 8cf1 0000                            P.......
 02:39:06.673293 66.82.9.27.4401 > 66.17.132.249.80: . ack 239 win 65298 (DF)
 0x0000   4500 0028 961b 4000 7106 613d 4252 091b        E..(..@.q.a=BR..
 0x0010   4211 84f9 1131 0050 299e 4d17 7308 152d        B....1.P).M.s..-
 0x0020   5010 ff12 8dde 0000 0000 0000 0000             P.............
 02:40:10.157328 66.82.9.27.4401 > 66.17.132.249.80: F 132:132(0) ack 239 
 win 65298 (DF)
 0x0000   4500 0028 3045 4000 7106 c713 4252 091b        E..(0E@.q...BR..
 0x0010   4211 84f9 1131 0050 299e 4d17 7308 152d        B....1.P).M.s..-
 0x0020   5011 ff12 8ddd 0000 0000 0000 0000             P.............
 02:40:10.157460 66.17.132.249.80 > 66.82.9.27.4401: . ack 133 win 65535 (DF)
 0x0000   4500 0028 6a8a 4000 4006 bdce 4211 84f9        E..(j.@.@...B...
 0x0010   4252 091b 0050 1131 7308 152d 299e 4d18        BR...P.1s..-).M.
 0x0020   5010 ffff 8cf0 0000                            P.......
 
 
 
 Anything else you'd like to see?
 
 
 
 
State-Changed-From-To: open->suspended 
State-Changed-By: des 
State-Changed-When: Mon Feb 10 02:56:17 PST 2003 
State-Changed-Why:  
I curently have no way of debugging this :( 

http://www.freebsd.org/cgi/query-pr.cgi?pr=47237 
State-Changed-From-To: suspended->feedback 
State-Changed-By: des 
State-Changed-When: Tue Jun 1 00:45:16 PDT 2004 
State-Changed-Why:  
awaiting feedback from originator 

http://www.freebsd.org/cgi/query-pr.cgi?pr=47237 

From: des@des.no (=?iso-8859-1?q?Dag-Erling_Sm=F8rgrav?=)
To: freebsd-gnats-submit@freebsd.org
Cc:  
Subject: Re: bin/47237: HTTP_PROXY with libfetch stalls at 99%
Date: Tue, 01 Jun 2004 09:44:41 +0200

 Does this still occur with recent versions of 4.x or 5.x?
 
 DES
 --=20
 Dag-Erling Sm=F8rgrav - des@des.no
State-Changed-From-To: feedback->closed 
State-Changed-By: des 
State-Changed-When: Tue Jun 1 02:25:33 PDT 2004 
State-Changed-Why:  
unable to reproduce. 

http://www.freebsd.org/cgi/query-pr.cgi?pr=47237 
>Unformatted:
