/// <summary> /// Hashes the core. /// </summary> /// <param name="rgb">The RGB.</param> /// <param name="ib">The ib.</param> /// <param name="cb">The cb.</param> protected override void HashCore(byte[] rgb, int ib, int cb) { if (!_innerPaddingWritten) { // write the inner padding _hashProvider.TransformBlock(_innerPadding, 0, BlockSize, _innerPadding, 0); // ensure we only write inner padding once _innerPaddingWritten = true; } _hashProvider.HashCore(rgb, ib, cb); }
/// <summary> /// Routes data written to the object into the hash algorithm for computing the hash. /// </summary> /// <param name="array">The input to compute the hash code for.</param> /// <param name="ibStart">The offset into the byte array from which to begin using data.</param> /// <param name="cbSize">The number of bytes in the byte array to use as data.</param> protected override void HashCore(byte[] array, int ibStart, int cbSize) { _hashProvider.HashCore(array, ibStart, cbSize); }