Org.BouncyCastle.Crypto.Modes.SicBlockCipher.Reset C# (CSharp) Method

Reset() public method

public Reset ( ) : void
return void
		public void Reset()
		{
			Array.Copy(IV, 0, counter, 0, counter.Length);
			cipher.Reset();
		}
	}

Usage Example

        private void Reset(
            bool clearMac)
        {
            cipher.Reset(); // TODO Redundant since the mac will reset it?
            mac.Reset();

            bufOff = 0;
            Array.Clear(bufBlock, 0, bufBlock.Length);

            if (clearMac)
            {
                Array.Clear(macBlock, 0, macBlock.Length);
            }

            byte[] tag = new byte[blockSize];
            tag[blockSize - 1] = (byte)Tag.H;
            mac.BlockUpdate(tag, 0, blockSize);

            cipherInitialized = false;

            if (initialAssociatedText != null)
            {
                ProcessAadBytes(initialAssociatedText, 0, initialAssociatedText.Length);
            }
        }
All Usage Examples Of Org.BouncyCastle.Crypto.Modes.SicBlockCipher::Reset