SecurityKeyIdentifier.CreateKey Method ()

 
System_CAPS_noteNote

The .NET API Reference documentation has a new home. Visit the .NET API Browser on docs.microsoft.com to see the new experience.

Creates a key for one of the key identifier clauses.

Namespace:   System.IdentityModel.Tokens
Assembly:  System.IdentityModel (in System.IdentityModel.dll)

public SecurityKey CreateKey()

Return Value

Type: System.IdentityModel.Tokens.SecurityKey

A SecurityKey that represents the created key.

Exception Condition
InvalidOperationException

A key could not be created for any of the key identifier clauses.

The SecurityKey that is returned is for the first key identifier clause in the collection that can create a key.

.NET Framework
Available since 3.0
Return to top
Show: