Język

AppServicesAuthenticationTokenAcquisition.ReplyForbiddenWithWwwAuthenticateHeader Metoda

Definicja

Używane w internetowych interfejsach API (co w związku z tym nie może mieć interakcji z użytkownikiem). Odpowiada klientowi za pośrednictwem protokołu HttpResponse, wysyłając adres 403 (zabronione) i wypełniając polecenia wwwAuthenticateHeaders, aby klient mógł wyzwolić interakcję z użytkownikiem, aby użytkownik mógł wyrazić zgodę na więcej zakresów.

public void ReplyForbiddenWithWwwAuthenticateHeader(System.Collections.Generic.IEnumerable<string> scopes, Microsoft.Identity.Client.MsalUiRequiredException msalServiceException, string? authenticationScheme, Microsoft.AspNetCore.Http.HttpResponse? httpResponse = default);
abstract member ReplyForbiddenWithWwwAuthenticateHeader : seq<string> * Microsoft.Identity.Client.MsalUiRequiredException * string * Microsoft.AspNetCore.Http.HttpResponse -> unit
override this.ReplyForbiddenWithWwwAuthenticateHeader : seq<string> * Microsoft.Identity.Client.MsalUiRequiredException * string * Microsoft.AspNetCore.Http.HttpResponse -> unit
Public Sub ReplyForbiddenWithWwwAuthenticateHeader (scopes As IEnumerable(Of String), msalServiceException As MsalUiRequiredException, authenticationScheme As String, Optional httpResponse As HttpResponse = Nothing)

Parametry

scopes
IEnumerable<String>

Zakresy wyrażania zgody.

msalServiceException
MsalUiRequiredException

MsalUiRequiredException wyzwalanie wyzwania.

authenticationScheme
String

Schemat uwierzytelniania. Jeśli wartość null, użyje metody OpenIdConnectDefault.AuthenticationScheme, jeśli zostanie wywołana z aplikacji internetowej, i JwtBearerDefault.AuthenticationScheme, jeśli zostanie wywołana z internetowego interfejsu API.

httpResponse
HttpResponse

Element HttpResponse do aktualizacji.

Implementuje

Dotyczy