Ejemplo n.º 1
0
 internal void InitEncryption(Config4Impl a_config)
 {
     if (a_config.Encrypt() && a_config.Password() != null && a_config.Password().Length
         > 0)
     {
         i_encrypt   = true;
         i_encryptor = new byte[a_config.Password().Length];
         for (int i = 0; i < i_encryptor.Length; i++)
         {
             i_encryptor[i] = (byte)(a_config.Password()[i] & unchecked ((int)(0xff)));
         }
         i_lastEncryptorByte = a_config.Password().Length - 1;
         return;
     }
     OldEncryptionOff();
 }
Ejemplo n.º 2
0
		internal void InitEncryption(Config4Impl a_config)
		{
			if (a_config.Encrypt() && a_config.Password() != null && a_config.Password().Length
				 > 0)
			{
				i_encrypt = true;
				i_encryptor = new byte[a_config.Password().Length];
				for (int i = 0; i < i_encryptor.Length; i++)
				{
					i_encryptor[i] = (byte)(a_config.Password()[i] & unchecked((int)(0xff)));
				}
				i_lastEncryptorByte = a_config.Password().Length - 1;
				return;
			}
			OldEncryptionOff();
		}