Saml2SecurityTokenHandler.CreateWindowsIdentity(String) 方法

定义

使用指定用户主名称 (UPN)创建 WindowsIdentity 对象。Creates a WindowsIdentity object using the specified User Principal Name (UPN).

protected:
 virtual System::Security::Principal::WindowsIdentity ^ CreateWindowsIdentity(System::String ^ upn);
protected virtual System.Security.Principal.WindowsIdentity CreateWindowsIdentity (string upn);
abstract member CreateWindowsIdentity : string -> System.Security.Principal.WindowsIdentity
override this.CreateWindowsIdentity : string -> System.Security.Principal.WindowsIdentity
Protected Overridable Function CreateWindowsIdentity (upn As String) As WindowsIdentity

参数

upn
String

用来创建标识的 UPN。The UPN to use to create the identity.

返回

WindowsIdentity

已创建的线程的 Windows 标识。The Windows identity that was created.

例外

upnnull 或空字符串。upn is null or an empty string.

适用于