SkeinEngine Class

Implementation of the Skein family of parameterised hash functions in 256, 512 and 1024 bit block sizes, based on the Threefish tweakable block cipher.

Definition

Namespace: Org.BouncyCastle.Crypto.Digests
Assembly: BouncyCastle.Cryptography (in BouncyCastle.Cryptography.dll) Version: 2.3.0-beta.187+d6da5648ae
public class SkeinEngine : IMemoable
Inheritance
Object    SkeinEngine
Implements
IMemoable

Remarks

This is the 1.3 version of Skein defined in the Skein hash function submission to the NIST SHA-3 competition in October 2010.

Skein was designed by Niels Ferguson - Stefan Lucks - Bruce Schneier - Doug Whiting - Mihir Bellare - Tadayoshi Kohno - Jon Callas - Jesse Walker.

This implementation is the basis for SkeinDigest and SkeinMac, implementing the parameter based configuration system that allows Skein to be adapted to multiple applications.
Initialising the engine with SkeinParameters allows standard and arbitrary parameters to be applied during the Skein hash function.

Implemented:

  • 256, 512 and 1024 bit internal states.
  • Full 96 bit input length.
  • Parameters defined in the Skein specification, and arbitrary other pre and post message parameters.
  • Arbitrary output size in 1 byte intervals.

Not implemented:

  • Sub-byte length input (bit padding).
  • Tree hashing.

Constructors

SkeinEngine(SkeinEngine) Creates a SkeinEngine as an exact copy of an existing instance.
SkeinEngine(Int32, Int32) Constructs a Skein digest with an internal state size and output size.

Properties

Methods

BlockUpdate(ReadOnlySpanByte) 
BlockUpdate(Byte, Int32, Int32) 
Copy 
DoFinal(SpanByte) 
DoFinal(Byte, Int32) 
EqualsDetermines whether the specified object is equal to the current object.
(Inherited from Object)
FinalizeAllows an object to try to free resources and perform other cleanup operations before it is reclaimed by garbage collection.
(Inherited from Object)
GetHashCodeServes as the default hash function.
(Inherited from Object)
GetTypeGets the Type of the current instance.
(Inherited from Object)
Init Initialises the Skein engine with the provided parameters. See SkeinParameters for details on the parameterisation of the Skein hash function.
MemberwiseCloneCreates a shallow copy of the current Object.
(Inherited from Object)
Reset Reset the engine to the initial state (with the key and any pre-message parameters , ready to accept message input.
Reset(IMemoable) 
ToStringReturns a string that represents the current object.
(Inherited from Object)
Update 

Fields

SKEIN_1024 1024 bit block size - Skein-1024
SKEIN_256 256 bit block size - Skein-256
SKEIN_512 512 bit block size - Skein-512

See Also