[Mono-bugs] [Bug 606142] New: HTTP Does not follow redirects correctly

bugzilla_noreply at novell.com bugzilla_noreply at novell.com
Fri May 14 22:50:03 EDT 2010



           Summary: HTTP Does not follow redirects correctly
    Classification: Mono
           Product: MonoTouch
           Version: unspecified
          Platform: Other
        OS/Version: Other
            Status: NEW
          Severity: Major
          Priority: P5 - None
         Component: Class Libraries
        AssignedTo: mono-bugs at lists.ximian.com
        ReportedBy: fak at kruegersystems.com
         QAContact: mono-bugs at lists.ximian.com
          Found By: ---
           Blocker: ---

Created an attachment (id=362415)
 --> (http://bugzilla.novell.com/attachment.cgi?id=362415)
Project demoing bug

Try to fetch this url:


using WebRequest. It fails with this error and this response URL:

- The remote server returned an error: (404) Not Found.

But it should resolve to:


It seems that it is concatenating URLs together incorrectly. 

Here is a log of the redirect chain:

atom:~ fak$ curl

HTTP/1.1 302 Moved Temporarily
Content-Length: 232
Content-Type: text/html
Date: Sat, 15 May 2010 02:44:22 GMT
Connection: keep-alive

<TITLE>302 Moved Temporarily</TITLE>
The document has moved <A

atom:~ fak$ curl

HTTP/1.1 301 Moved Permanently
X-Powered-By: PHP/5.1.4
Location: /media/nerdist/Number_14_-_Stan_Lee.mp3
Content-type: text/html
Content-Length: 0
Date: Sat, 15 May 2010 02:49:13 GMT
Server: lighttpd/1.4.15

atom:~ fak$ curl
"http://media.libsyn.com/media/nerdist/Number_14_-_Stan_Lee.mp3" -i

HTTP/1.1 302 Found
X-Powered-By: PHP/5.1.4
Content-type: text/html
Content-Length: 0
Date: Sat, 15 May 2010 02:49:37 GMT
Server: lighttpd/1.4.15

atom:~ fak$ curl
> /dev/null 
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
 16 47.8M   16 8111k    0     0  2277k      0  0:00:21  0:00:03  0:00:18
atom:~ fak$

I have attached a project to repro this.

Configure bugmail: http://bugzilla.novell.com/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the QA contact for the bug.
You are the assignee for the bug.

More information about the mono-bugs mailing list