C# Class Goedel.Cryptography.CryptoProviderExchangeRSA

Provider for RSA encryption.
Inheritance: CryptoProviderExchange
Show file Open project: hallambaker/Mathematical-Mesh

Protected Properties

Property Type Description
OAEP bool

Private Properties

Property Type Description
Factory CryptoProvider

Public Methods

Method Description
CryptoProviderExchangeRSA ( RSAKeyPair RSAKeyPair ) : System

Create an instance of the RSA crypto provider.

CryptoProviderExchangeRSA ( int KeySize ) : System

Return a provider with the specified key size.

Decrypt ( byte Input ) : byte[]

Decrypt data block.

Encrypt ( byte Input ) : byte[]

Encrypt data block. Block MUST be smaller than the key length or an exception will be thrown.

FindLocal ( string UDF ) : bool

Locate private key in local key store.

Generate ( KeySecurity KeySecurity ) : void

Generate a new RSA Key Pair with the Key size specified when the instance was created.

Private Methods

Method Description
Factory ( int KeySize, CryptoAlgorithmID DigestAlgorithm ) : CryptoProvider

Method Details

CryptoProviderExchangeRSA() public method

Create an instance of the RSA crypto provider.
public CryptoProviderExchangeRSA ( RSAKeyPair RSAKeyPair ) : System
RSAKeyPair RSAKeyPair RSAKeyPair to use.
return System

CryptoProviderExchangeRSA() public method

Return a provider with the specified key size.
public CryptoProviderExchangeRSA ( int KeySize ) : System
KeySize int Key length in bits.
return System

Decrypt() public method

Decrypt data block.
public Decrypt ( byte Input ) : byte[]
Input byte Data to decrypt.
return byte[]

Encrypt() public method

Encrypt data block. Block MUST be smaller than the key length or an exception will be thrown.
public Encrypt ( byte Input ) : byte[]
Input byte Data to encrypt.
return byte[]

FindLocal() public method

Locate private key in local key store.
public FindLocal ( string UDF ) : bool
UDF string Fingerprint of key
return bool

Generate() public method

Generate a new RSA Key Pair with the Key size specified when the instance was created.
public Generate ( KeySecurity KeySecurity ) : void
KeySecurity KeySecurity
return void

Property Details

OAEP protected property

If true (default), OAEP padding will be used. If false, deprecated PKCS#1.5 padding is used.
protected bool OAEP
return bool