Table of Contents

Interface IAsymmetricBlockCipher

Namespace
Org.BouncyCastle.Crypto
Assembly
BouncyCastle.Cryptography.dll
public interface IAsymmetricBlockCipher

Remarks

Base interface for a public/private key block cipher.

Properties

AlgorithmName

The name of the algorithm this cipher implements.

string AlgorithmName { get; }

Property Value

string

Methods

GetInputBlockSize()

int GetInputBlockSize()

Returns

int

The maximum size, in bytes, an input block may be.

GetOutputBlockSize()

int GetOutputBlockSize()

Returns

int

The maximum size, in bytes, an output block will be.

Init(bool, ICipherParameters)

Initialise the cipher.

void Init(bool forEncryption, ICipherParameters parameters)

Parameters

forEncryption bool

Initialise for encryption if true, for decryption if false.

parameters ICipherParameters

The key or other data required by the cipher.

ProcessBlock(byte[], int, int)

Process a block.

byte[] ProcessBlock(byte[] inBuf, int inOff, int inLen)

Parameters

inBuf byte[]

The input buffer.

inOff int

The offset into that the input block begins.

inLen int

The length of the input block.

Returns

byte[]

Exceptions

InvalidCipherTextException

Input decrypts improperly.

DataLengthException

Input is too large for the cipher.