Class WindowsCredentialProvider
Gets System.Net.NetworkCredentials using the Windows Credential Manager.
public abstract class WindowsCredentialProvider : ICredentialProvider
- Inheritance
-
objectWindowsCredentialProvider
- Implements
- Derived
- Extension Methods
Methods
GetCredential(string, WindowsCredentialsFlags)
Performs the actual WindowsCredentials API call to prompt the user or the credential store for credentials.
protected abstract NetworkCredential? GetCredential(string target, WindowsCredentialsFlags flags)
Parameters
target
stringA string identifying the target the credentials are intended for.
flags
WindowsCredentialsFlagsFlags for configuring the prompt.
Returns
- NetworkCredential
GetCredential(Uri, bool)
Returns System.Net.NetworkCredentials for a specific System.Uri.
public NetworkCredential? GetCredential(Uri uri, bool previousIncorrect = false)
Parameters
uri
UriThe URI that the client is providing authentication for.
previousIncorrect
boolReports that the credentials previously returned by this provider were incorrect.
Returns
- NetworkCredential