X509KeyIdentifierClauseType X509KeyIdentifierClauseType X509KeyIdentifierClauseType X509KeyIdentifierClauseType Enum

定义

一个列出 X.509 密钥标识符子句可能的类型的枚举。An enumeration listing the possible types of X.509 key identifier clauses.

public enum class X509KeyIdentifierClauseType
public enum X509KeyIdentifierClauseType
type X509KeyIdentifierClauseType = 
Public Enum X509KeyIdentifierClauseType
继承
X509KeyIdentifierClauseTypeX509KeyIdentifierClauseTypeX509KeyIdentifierClauseTypeX509KeyIdentifierClauseType

字段

Any Any Any Any 0

如果 X.509 证书中存在 SubjectKeyIdentifier,则使用它;否则使用 IssuerSerialSubjectKeyIdentifier is used if present in the X.509 certificate, otherwise IssuerSerial is used.

IssuerSerial IssuerSerial IssuerSerial IssuerSerial 2

使用 IssuerSerial 引用:颁发者标识符加上对颁发者唯一的序列号。The IssuerSerial reference is used: the issuer identifier plus a serial number that is unique for an issuer.

RawDataKeyIdentifier RawDataKeyIdentifier RawDataKeyIdentifier RawDataKeyIdentifier 4

该引用包含整个 X.509 证书的原始数据。The reference contains the raw data for the entire X.509 certificate.

SubjectKeyIdentifier SubjectKeyIdentifier SubjectKeyIdentifier SubjectKeyIdentifier 3

引用基于 X.509 证书的主题密钥标识符扩展(并非所有证书都具有扩展,它是可选属性)。Reference is based on the subject key identifier extension of an X.509 certificate (not all certificates have one, it is an optional property).

Thumbprint Thumbprint Thumbprint Thumbprint 1

使用 X.509 指纹。The X.509 Thumbprint is used.

示例

下面的代码演示如何将 X509ReferenceStyle 属性设置为此枚举的成员。The following code shows how to set the X509ReferenceStyle property to a member of this enumeration.

AsymmetricSecurityBindingElement abe =
    (AsymmetricSecurityBindingElement)SecurityBindingElement.
    CreateMutualCertificateBindingElement(
    MessageSecurityVersion.
    WSSecurity10WSTrustFebruary2005WSSecureConversationFebruary2005WSSecurityPolicy11BasicSecurityProfile10);

abe.SetKeyDerivation(false);

X509SecurityTokenParameters istp =
   abe.InitiatorTokenParameters as X509SecurityTokenParameters;
if (istp != null)
{
    istp.X509ReferenceStyle =
    X509KeyIdentifierClauseType.IssuerSerial;
}
Dim abe As AsymmetricSecurityBindingElement = CType(SecurityBindingElement.CreateMutualCertificateBindingElement(MessageSecurityVersion.WSSecurity10WSTrustFebruary2005WSSecureConversationFebruary2005WSSecurityPolicy11BasicSecurityProfile10), AsymmetricSecurityBindingElement)

abe.SetKeyDerivation(False)

Dim istp As X509SecurityTokenParameters = TryCast(abe.InitiatorTokenParameters, X509SecurityTokenParameters)
If istp IsNot Nothing Then
    istp.X509ReferenceStyle = X509KeyIdentifierClauseType.IssuerSerial
End If

适用于