Re: WebServices and CF - Redux
- From: "Alex Feinman [MVP]" <public_news@xxxxxxxxxxxxxxx>
- Date: Fri, 22 Apr 2005 17:17:32 -0700
NTLM required for Integrated Windows authentication is not supported in CF 1.0. It is in CF 2.0 though
--
Alex Feinman
---
Visit http://www.opennetcf.org
"Bill" <Bill@xxxxxxxxxxxxxxxxxxxxxxxxx> wrote in message news:C7036084-6A6C-461F-A7A8-78B526A1C78E@xxxxxxxxxxxxxxxx
Goal: to employ Windows Authentication to access sensitive Web Services from
a CF application. Please humor me and consider the following code one more
time:
mammoth.POE_WebServices wert = new PreProcEval.mammoth.POE_WebServices();
wert.Credentials = new NetworkCredential( "userid", "password", "domain" );
wert.PreAuthenticate = true;
String error = String.Empty;
try { DataSet myData = wert.POE_FindPatient( "Z99999", String.Empty, String.Empty, error );
foreach( DataRow myRow in myData.Tables[0].Rows ) { lvPatientSelector.Items.Add( new ListViewItem( myRow.ItemArray[0].ToString() )); } } catch( WebException wex ) { MessageBox.Show( wex.Status.ToString() ); }
I set up the web server for anonoymous (no) authentication. I created 2 projects, one is a CF project, the other a regular .NET project. Both projects run and produce the desired result.
In my next experiment I set the web server to require Integrated Windows
Authentication. The regular .NET project ran and got the desired result, but
the CF project produced a WebException status of ProtocolError. It looks
very much to me as though something about the credentials isn't working for
CF project. This despite the fact that the NetworkCredential constructor, and
the WebClientProtocol.credential property are documented as being supported
by the CF. There could be domain issues involve I suppose but it looks like
the NetworkCredential constructor has this covered. I really want to be able
to use IWA on this project. Once again looking for a nudge in the right
direction!
Bill
.
- Follow-Ups:
- Re: WebServices and CF - Redux
- From: Bill
- Re: WebServices and CF - Redux
- References:
- WebServices and CF - Redux
- From: Bill
- WebServices and CF - Redux
- Prev by Date: Re: Best way to create a timer app.
- Next by Date: Re: Emulate cancel button
- Previous by thread: WebServices and CF - Redux
- Next by thread: Re: WebServices and CF - Redux
- Index(es):
Relevant Pages
|