WebClientProtocol.Credentials Property

Gets or sets security credentials for XML Web service client authentication.

[Visual Basic]
Public Property Credentials As ICredentials
public ICredentials Credentials {get; set;}
public: __property ICredentials* get_Credentials();
public: __property void set_Credentials(ICredentials*);
public function get Credentials() : ICredentials;
public function set Credentials(ICredentials);

Property Value

The ICredentials for the XML Web service client.


When using the Credentials property, a XML Web service client must instantiate a class implementing ICredentials, such as NetworkCredential, and then set the client credentials specific to the authentication mechanism. The NetworkCredential class can be used to set authentication credentials using the basic, digest, NTLM and Kerberos authentication mechanisms.

When the Credentials property is set to CredentialCache.DefaultCredentials then the client negotiates with the server to do Kerberos and/or NTLM authentication depending on how the server is configured.


Platforms: Windows 98, Windows NT 4.0, Windows Millennium Edition, Windows 2000, Windows XP Home Edition, Windows XP Professional, Windows Server 2003 family, .NET Compact Framework

See Also

WebClientProtocol Class | WebClientProtocol Members | System.Web.Services.Protocols Namespace | ICredentials | NetworkCredential