Interface IDigest
- Namespace
- Org.BouncyCastle.Crypto
- Assembly
- BouncyCastle.Cryptography.dll
public interface IDigest
Remarks
Base interface for a message digest.
Properties
AlgorithmName
The algorithm name.
string AlgorithmName { get; }
Property Value
Methods
BlockUpdate(byte[], int, int)
Update the message digest with a block of bytes.
void BlockUpdate(byte[] input, int inOff, int inLen)
Parameters
inputbyte[]The byte array containing the data.
inOffintThe offset into the byte array where the data starts.
inLenintThe length of the data.
BlockUpdate(ReadOnlySpan<byte>)
Update the message digest with a span of bytes.
void BlockUpdate(ReadOnlySpan<byte> input)
Parameters
inputReadOnlySpan<byte>The span containing the data.
DoFinal(byte[], int)
Close the digest, producing the final digest value.
int DoFinal(byte[] output, int outOff)
Parameters
outputbyte[]The byte array the digest is to be copied into.
outOffintThe offset into the byte array the digest is to start at.
Returns
- int
The number of bytes written.
Remarks
This call leaves the digest reset.
DoFinal(Span<byte>)
Close the digest, producing the final digest value.
int DoFinal(Span<byte> output)
Parameters
Returns
- int
The number of bytes written.
Remarks
This call leaves the digest reset.
GetByteLength()
Return the size, in bytes, of the internal buffer used by this digest.
int GetByteLength()
Returns
- int
The size, in bytes, of the internal buffer used by this digest.
GetDigestSize()
Return the size, in bytes, of the digest produced by this message digest.
int GetDigestSize()
Returns
- int
The size, in bytes, of the digest produced by this message digest.
Reset()
Reset the digest back to its initial state.
void Reset()
Update(byte)
Update the message digest with a single byte.
void Update(byte input)
Parameters
inputbyteThe input byte to be entered.