[Mono-bugs] [Bug 312968] HttpWebRequest can not handle WWW-Authenticate with POST

bugzilla_noreply at novell.com bugzilla_noreply at novell.com
Tue Sep 1 15:09:56 EDT 2009


http://bugzilla.novell.com/show_bug.cgi?id=312968

User greg.smolyn at strangeloopnetworks.com added comment
http://bugzilla.novell.com/show_bug.cgi?id=312968#c6





--- Comment #6 from Greg Smolyn <greg.smolyn at strangeloopnetworks.com>  2009-09-01 13:09:55 MDT ---
The test case is unfortunately not entirely self-contained, the only
requirement is an HTTP server on the _local machine_ that has authentication
enabled.

This is fairly easy to set up in Apache 2:

In your VirtualHost section for your site, just add
<Directory /var/www/>
          Options Indexes FollowSymLinks
          AllowOverride None
          Order allow,deny
          Allow from all
          AuthType Basic
          AuthName "SSL and Basic Auth Test"
          AuthUserFile /etc/apache2/passwd
          Require user test
</Directory>

then run:

htpasswd -bc /etc/apache2/passwd test test



The test case should then explode (there are comments in the Main.cs file).

It looks like there is a race condition, but mainly when getting very fast
response/request cycles, thus the requirement for a local HTTP server.  I
attempted to recreate with going through the internet, but the delays managed
to keep the reproduction case from occuring.

The scenario is fairly specific, however: requires a POST with a body, and
KeepAlive=false.  So it smells like something in the connection tear-down code
that is having issues.

In the test case provided, an ObjectDisposedException gets thrown and the
program quits.

The error is different if you set up SSL on your local site and try to hit the
URL in the test with https instead of http.  A 5 minute timeout occurs deep in
the Tls code, while it does a WaitOne() for some async lock.

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


More information about the mono-bugs mailing list