This documentation is archived and is not being maintained.

AuthenticationManager.Authenticate Method

Calls each registered authentication module to find the first module that can respond to the authentication request.

Namespace:  System.Net
Assembly:  System (in System.dll)

Public Shared Function Authenticate ( _
	challenge As String, _
	request As WebRequest, _
	credentials As ICredentials _
) As Authorization
Dim challenge As String 
Dim request As WebRequest 
Dim credentials As ICredentials 
Dim returnValue As Authorization 

returnValue = AuthenticationManager.Authenticate(challenge, _
	request, credentials)


Type: System.String

The challenge returned by the Internet resource.

Type: System.Net.WebRequest

The WebRequest that initiated the authentication challenge.

Type: System.Net.ICredentials

The ICredentials associated with this request.

Return Value

Type: System.Net.Authorization
An instance of the Authorization class containing the result of the authorization attempt. If there is no authentication module to respond to the challenge, this method returns Nothing.


challenge is Nothing.


request is Nothing.


credentials is Nothing.

The Authenticate method calls the IAuthenticationModule.Authenticate method on each registered authentication module until one of the module responds with an Authorization instance.

The first Authorization instance returned is used to authenticate the request. If no authentication module can authenticate the request, the Authenticate method returns Nothing.

Authentication modules are called in the order in which they are registered with the AuthenticationManager.

Windows 7, Windows Vista, Windows XP SP2, Windows XP Media Center Edition, Windows XP Professional x64 Edition, Windows XP Starter Edition, Windows Server 2008 R2, Windows Server 2008, Windows Server 2003, Windows Server 2000 SP4, Windows Millennium Edition, Windows 98, Windows CE, Windows Mobile for Smartphone, Windows Mobile for Pocket PC

The .NET Framework and .NET Compact Framework do not support all versions of every platform. For a list of the supported versions, see .NET Framework System Requirements.

.NET Framework

Supported in: 3.5, 3.0, 2.0, 1.1, 1.0

.NET Compact Framework

Supported in: 3.5, 2.0, 1.0