Org.BouncyCastle.Crypto.Engines.RC532Engine.DecryptBlock C# (CSharp) Method

DecryptBlock() private method

private DecryptBlock ( byte input, int inOff, byte outBytes, int outOff ) : int
input byte
inOff int
outBytes byte
outOff int
return int
        private int DecryptBlock(
            byte[]  input,
            int     inOff,
            byte[]  outBytes,
            int     outOff)
        {
            int A = BytesToWord(input, inOff);
            int B = BytesToWord(input, inOff + 4);

            for (int i = _noRounds; i >= 1; i--)
            {
                B = RotateRight(B - _S[2*i+1], A) ^ A;
                A = RotateRight(A - _S[2*i],   B) ^ B;
            }

            WordToBytes(A - _S[0], outBytes, outOff);
            WordToBytes(B - _S[1], outBytes, outOff + 4);

            return 2 * 4;
        }