RSACryptoServiceProvider Class
Namespace: System.Security.Cryptography · Assembly: GHIElectronics.TinyCLR.System.Security.Cryptography
Concrete RSA implementation. Construct with the desired key size or with externally supplied RSAParameters.
public sealed class RSACryptoServiceProvider : RSA
Constructors
RSACryptoServiceProvider()
public RSACryptoServiceProvider()
No description available.
RSACryptoServiceProvider(int dwKeySize)
public RSACryptoServiceProvider(int dwKeySize)
No description available.
| Parameter | Type | Description |
|---|---|---|
dwKeySize | int |
Properties
KeySize
public override int KeySize { get; set; }
No description available.
KeyExchangeAlgorithm
public override string KeyExchangeAlgorithm { get; }
No description available.
Methods
ExportParameters(bool includePrivateParameters)
public override RSAParameters ExportParameters(bool includePrivateParameters)
No description available.
| Parameter | Type | Description |
|---|---|---|
includePrivateParameters | bool |
Returns RSAParameters
ImportParameters(RSAParameters parameters)
public override void ImportParameters(RSAParameters parameters)
No description available.
| Parameter | Type | Description |
|---|---|---|
parameters | RSAParameters |
Encrypt(byte[] data, RSAEncryptionPadding padding)
public override byte[] Encrypt(byte[] data, RSAEncryptionPadding padding)
No description available.
| Parameter | Type | Description |
|---|---|---|
data | byte[] | |
padding | RSAEncryptionPadding |
Returns byte[]
Decrypt(byte[] data, RSAEncryptionPadding padding)
public override byte[] Decrypt(byte[] data, RSAEncryptionPadding padding)
No description available.
| Parameter | Type | Description |
|---|---|---|
data | byte[] | |
padding | RSAEncryptionPadding |
Returns byte[]
SignData(byte[] data, HashAlgorithmName hashAlgorithm, RSASignaturePadding padding)
public override byte[] SignData(byte[] data, HashAlgorithmName hashAlgorithm, RSASignaturePadding padding)
No description available.
| Parameter | Type | Description |
|---|---|---|
data | byte[] | |
hashAlgorithm | HashAlgorithmName | |
padding | RSASignaturePadding |
Returns byte[]
SignHash(byte[] hash, HashAlgorithmName hashAlgorithm, RSASignaturePadding padding)
public override byte[] SignHash(byte[] hash, HashAlgorithmName hashAlgorithm, RSASignaturePadding padding)
No description available.
| Parameter | Type | Description |
|---|---|---|
hash | byte[] | |
hashAlgorithm | HashAlgorithmName | |
padding | RSASignaturePadding |
Returns byte[]
VerifyData(byte[] data, byte[] signature, HashAlgorithmName hashAlgorithm, RSASignaturePadding padding)
public override bool VerifyData(byte[] data, byte[] signature, HashAlgorithmName hashAlgorithm, RSASignaturePadding padding)
No description available.
| Parameter | Type | Description |
|---|---|---|
data | byte[] | |
signature | byte[] | |
hashAlgorithm | HashAlgorithmName | |
padding | RSASignaturePadding |
Returns bool
VerifyHash(byte[] hash, byte[] signature, HashAlgorithmName hashAlgorithm, RSASignaturePadding padding)
public override bool VerifyHash(byte[] hash, byte[] signature, HashAlgorithmName hashAlgorithm, RSASignaturePadding padding)
No description available.
| Parameter | Type | Description |
|---|---|---|
hash | byte[] | |
signature | byte[] | |
hashAlgorithm | HashAlgorithmName | |
padding | RSASignaturePadding |
Returns bool
Encrypt(byte[] rgb, bool fOAEP)
public byte[] Encrypt(byte[] rgb, bool fOAEP)
No description available.
| Parameter | Type | Description |
|---|---|---|
rgb | byte[] | |
fOAEP | bool |
Returns byte[]
Decrypt(byte[] rgb, bool fOAEP)
public byte[] Decrypt(byte[] rgb, bool fOAEP)
No description available.
| Parameter | Type | Description |
|---|---|---|
rgb | byte[] | |
fOAEP | bool |
Returns byte[]
SignData(byte[] buffer, bool sha256)
public byte[] SignData(byte[] buffer, bool sha256 = false)
No description available.
| Parameter | Type | Description |
|---|---|---|
buffer | byte[] | |
sha256 | bool |
Returns byte[]
VerifyData(byte[] buffer, byte[] signature, bool sha256)
public bool VerifyData(byte[] buffer, byte[] signature, bool sha256 = false)
No description available.
| Parameter | Type | Description |
|---|---|---|
buffer | byte[] | |
signature | byte[] | |
sha256 | bool |
Returns bool
Dispose()
public override void Dispose()
Releases buffered memory (the unmanaged firmware/application buffers). (inherited)