OCB_ntz() 보호된 정적인 메소드

protected static OCB_ntz ( long x ) : int
x long
리턴 int
예제 #1
0
 protected virtual void ProcessMainBlock(byte[] output, int outOff)
 {
     Check.DataLength(output, outOff, 16, "Output buffer too short");
     if (this.forEncryption)
     {
         OcbBlockCipher.Xor(this.Checksum, this.mainBlock);
         this.mainBlockPos = 0;
     }
     OcbBlockCipher.Xor(this.OffsetMAIN, this.GetLSub(OcbBlockCipher.OCB_ntz(this.mainBlockCount += 1L)));
     OcbBlockCipher.Xor(this.mainBlock, this.OffsetMAIN);
     this.mainCipher.ProcessBlock(this.mainBlock, 0, this.mainBlock, 0);
     OcbBlockCipher.Xor(this.mainBlock, this.OffsetMAIN);
     Array.Copy(this.mainBlock, 0, output, outOff, 16);
     if (!this.forEncryption)
     {
         OcbBlockCipher.Xor(this.Checksum, this.mainBlock);
         Array.Copy(this.mainBlock, 16, this.mainBlock, 0, this.macSize);
         this.mainBlockPos = this.macSize;
     }
 }
예제 #2
0
 protected virtual void ProcessHashBlock()
 {
     this.UpdateHASH(this.GetLSub(OcbBlockCipher.OCB_ntz(this.hashBlockCount += 1L)));
     this.hashBlockPos = 0;
 }