System.Security.Authentication.AuthenticationException Class

The exception that is thrown when authentication fails for an authentication stream.

See Also: AuthenticationException Members


public class AuthenticationException : SystemException


The System.Net.Security.NegotiateStream and System.Net.Security.SslStream classes throw this exception when the client or server cannot be authenticated. When this exception is thrown, you can retry the authentication with different credentials. If you cannot retry the authentication, a System.Net.FatalAuthenticationException is thrown instead of the System.Security.Authentication.AuthenticationException.


Namespace: System.Security.Authentication
Assembly: System (in System.dll)
Assembly Versions:,
Since: .NET 2.0