[Mono-bugs] [Bug 323375] HttpWebRequest does not authenticate via NTLM
bugzilla_noreply at novell.com
bugzilla_noreply at novell.com
Wed Jul 30 17:57:34 EDT 2008
https://bugzilla.novell.com/show_bug.cgi?id=323375
User miguel at novell.com added comment
https://bugzilla.novell.com/show_bug.cgi?id=323375#c12
Miguel de Icaza <miguel at novell.com> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|RESOLVED |REOPENED
Resolution|FIXED |
--- Comment #12 from Miguel de Icaza <miguel at novell.com> 2008-07-30 15:57:34 MDT ---
I was trying to write a unit test case, and I could not get this to work with
trunk.
The attached program prints (401) Unauthorized:
using System;
using System.Text;
using System.Net;
namespace ntlm_auth
{
public class NtlmAuthTests
{
const string URL = "http://ntlmauth.omni-ts.com/";
const string USERID = "mono";
const string PASSWD = "mono";
static void Main ()
{
Valid ();
}
static public void Valid()
{
WebRequest req = WebRequest.Create(URL);
req.Credentials = new NetworkCredential(USERID, PASSWD,
string.Empty);
HttpWebResponse resp = (HttpWebResponse)req.GetResponse();
Console.WriteLine (resp.StatusCode);
}
}
}
--
Configure bugmail: https://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