IAuthenticationModule.CanPreAuthenticate Propiedad

Definición

Obtiene un valor que indica si el módulo de autenticación admite la preautenticación.

C#
public bool CanPreAuthenticate { get; }

Valor de propiedad

true si el módulo de autorización admite la preautenticación; en caso contrario, false.

Ejemplos

En el ejemplo siguiente se muestra cómo usar la propiedad CanPreAuthenticate. Para obtener un ejemplo completo, consulte la AuthenticationManager clase .

C#
// Define the authentication type. This type is then used to identify this
// custom authentication module. The default is set to Basic.
public string AuthenticationType { get; } = "Basic";

// Define the pre-authentication capabilities for the module. The default is set
// to false.
public bool CanPreAuthenticate { get; }

Comentarios

La CanPreAuthenticate propiedad se establece true en para indicar que el módulo de autenticación puede responder con una instancia válida Authorization cuando se llama al PreAuthenticate método .

Notas a los implementadores

Normalmente, se trata de un valor fijo; El módulo de autenticación puede autenticarse previamente o no.

Se aplica a

Producto Versiones
.NET Core 2.0, Core 2.1, Core 2.2, Core 3.0, Core 3.1, 5, 6, 7, 8, 9, 10
.NET Framework 1.1, 2.0, 3.0, 3.5, 4.0, 4.5, 4.5.1, 4.5.2, 4.6, 4.6.1, 4.6.2, 4.7, 4.7.1, 4.7.2, 4.8, 4.8.1
.NET Standard 2.0, 2.1