Esempio n. 1
0
        public void SetKeys(byte[] key, byte[] clientNonce, byte[] serverNonce)
        {
            try
            {
                _aesLock.EnterWriteLock();

                _aes = new OcbAes();
                _aes.Initialise(key);

                ServerNonce = serverNonce;
                ClientNonce = clientNonce;
            }
            finally
            {
                _aesLock.ExitWriteLock();
            }
        }
Esempio n. 2
0
        public void SetKeys(byte[] key, byte[] clientNonce, byte[] serverNonce)
        {
            try
            {
                _aesLock.EnterWriteLock();

                _aes = new OcbAes();
                _aes.Initialise(key);

                ServerNonce = serverNonce;
                ClientNonce = clientNonce;
            }
            finally
            {
                _aesLock.ExitWriteLock();
            }
        }