<KeyIdentifier> Element (WSE for Microsoft .NET) (2)

Specifies the key identifier for a security token.

<microsoft.web.services2> Element
  <tokenIssuer> Element (WSE for Microsoft .NET) (2)
    <serverToken> Element
      <KeyInfo> Element (WSE for Microsoft .NET) (2)
        <SecurityTokenReference> Element (WSE for Microsoft .NET) (2)

<wsse:KeyIdentifier ValueType="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-x509-token-profile-1.0#X509SubjectKeyIdentifier">
  ZPGrPnuqATeSgVjLYcmiY/GSWWY=
</wsse:KeyIdentifier>

Attributes and Elements

Attributes

Attribute Description

ValueType

Optional attribute. Specifies the type of security token the key identifier identifies.

Child Elements

None

Parent Elements

Element Description

<SecurityTokenReference> Element (WSE for Microsoft .NET) (2)

Specifies a security token that must be used to encrypt a SOAP message.

Text Value

A text value is required. The text value is the base64 encoded key identifier for the security token.

Remarks

When issuing security tokens, use the <KeyIdentifier> element to specify a security token within a <serverToken> Element element. For more details about issuing security tokens, see Issuing Security Tokens.

Example

The following code example specifies an X509SecurityToken with a specific key to sign the responses for security token requests.

<?xml version="1.0" encoding="utf-8"?>
<configuration>
  <microsoft.web.services2>
    <tokenIssuer>
      <serverToken>
        <KeyInfo xmlns="http://www.w3.org/2000/09/xmldsig#">
          <wsse:SecurityTokenReference 
            xmlns:wsse="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd">
            <wsse:KeyIdentifier ValueType="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-x509-token-profile-1.0#X509SubjectKeyIdentifier">              ZPGrPnuqATeSgVjLYcmiY/GSWWY=            </wsse:KeyIdentifier>
          </wsse:SecurityTokenReference>
        </KeyInfo>
      </serverToken>
    </tokenIssuer>
  </microsoft.web.services2>
</configuration>

See Also

Reference

<serverToken> Element

Other Resources

Issuing Security Tokens