Gets the default system credentials from the CredentialCache.
[Visual Basic] Public Shared ReadOnly Property DefaultCredentials As _ ICredentialLookup [C#] public static ICredentialLookup DefaultCredentials {get;} [C++] public: __property static ICredentialLookup* get_DefaultCredentials(); [JScript] public static function get DefaultCredentials() : ICredentialLookup;
System.Net.DefaultCredentials applies to NTLM and Kerberos-based authentication only.
System.Net.DefaultCredentials returns the system credentials for the current security context in which the application is running. For a client-side application, this is usually the Windows credentials (user name/password/domain) of the user running the application. When accessed from within an ASP+ page, the security context is determined by the ASP+ page. This context will be either the process token associated with IIS, or, if using ASP+ impersonation, it will be the process token being impersonated.
CredentialCache Class | CredentialCache Members | System.Net Namespace