Freigeben über


ClaimsPrincipalExtensions.GetHomeObjectId(ClaimsPrincipal) Method

Definition

Gets the Home Object ID associated with the ClaimsPrincipal.

public static string? GetHomeObjectId (this System.Security.Claims.ClaimsPrincipal claimsPrincipal);
static member GetHomeObjectId : System.Security.Claims.ClaimsPrincipal -> string
<Extension()>
Public Function GetHomeObjectId (claimsPrincipal As ClaimsPrincipal) As String

Parameters

claimsPrincipal
ClaimsPrincipal

The ClaimsPrincipal from which to retrieve the sub claim.

Returns

Home Object ID (sub) of the identity, or null if it cannot be found.

Applies to