RsaSecurityKey Class

Represents a security key that is generated using the RSA algorithm. This class cannot be inherited.

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

public sealed class RsaSecurityKey : AsymmetricSecurityKey

The RsaSecurityKey type exposes the following members.

Public methodRsaSecurityKeyInitializes a new instance of the RsaSecurityKey class using the specified RSA algorithm.

Public propertyKeySizeGets the size, in bits, of the key. (Overrides SecurityKey.KeySize.)

Public methodDecryptKeyDecrypts the specified encrypted key. (Overrides SecurityKey.DecryptKey(String, Byte[]).)
Public methodEncryptKeyEncrypts the specified key using the specified algorithm. (Overrides SecurityKey.EncryptKey(String, Byte[]).)
Public methodEquals(Object)Determines whether the specified object is equal to the current object. (Inherited from Object.)
Public methodGetAsymmetricAlgorithmGets the specified asymmetric cryptographic algorithm. (Overrides AsymmetricSecurityKey.GetAsymmetricAlgorithm(String, Boolean).)
Public methodGetHashAlgorithmForSignatureGets a cryptographic algorithm that generates a hash for a digital signature. (Overrides AsymmetricSecurityKey.GetHashAlgorithmForSignature(String).)
Public methodGetHashCodeServes as the default hash function. (Inherited from Object.)
Public methodGetSignatureDeformatterGets the de-formatter algorithm for the digital signature. (Overrides AsymmetricSecurityKey.GetSignatureDeformatter(String).)
Public methodGetSignatureFormatterGets the formatter algorithm for the digital signature. (Overrides AsymmetricSecurityKey.GetSignatureFormatter(String).)
Public methodGetTypeGets the Type of the current instance. (Inherited from Object.)
Public methodHasPrivateKeyGets a value that indicates whether the private key is available. (Overrides AsymmetricSecurityKey.HasPrivateKey().)
Public methodIsAsymmetricAlgorithmGets a value that indicates whether the specified algorithm uses asymmetric keys. (Overrides SecurityKey.IsAsymmetricAlgorithm(String).)
Public methodIsSupportedAlgorithmGets a value that indicates whether the specified algorithm is supported by this class. (Overrides SecurityKey.IsSupportedAlgorithm(String).)
Public methodIsSymmetricAlgorithmGets a value that indicates whether the specified algorithm uses symmetric keys. (Overrides SecurityKey.IsSymmetricAlgorithm(String).)
Public methodToStringReturns a string that represents the current object. (Inherited from Object.)

.NET Framework

Supported in: 4.6, 4.5, 4, 3.5, 3.0

.NET Framework Client Profile

Supported in: 4, 3.5 SP1

Any public static (Shared in Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.
Was this page helpful?
(1500 characters remaining)
Thank you for your feedback
© 2015 Microsoft