From 613afe3c92c202da1900ef2f7000425f6baabb9e Mon Sep 17 00:00:00 2001 From: Christian Pointner Date: Tue, 7 Apr 2009 00:16:12 +0000 Subject: removed anytun02-compat mode --- src/cipher.cpp | 17 ----------------- 1 file changed, 17 deletions(-) (limited to 'src/cipher.cpp') diff --git a/src/cipher.cpp b/src/cipher.cpp index 15c9af2..ddde683 100644 --- a/src/cipher.cpp +++ b/src/cipher.cpp @@ -79,22 +79,11 @@ AesIcmCipher::AesIcmCipher(kd_dir_t d) : Cipher(d), key_(u_int32_t(DEFAULT_KEY_L init(); } - -AesIcmCipher::AesIcmCipher(kd_dir_t d, bool a) : Cipher(d, a), key_(u_int32_t(DEFAULT_KEY_LENGTH/8)), salt_(u_int32_t(SALT_LENGTH)) -{ - init(); -} - AesIcmCipher::AesIcmCipher(kd_dir_t d, u_int16_t key_length) : Cipher(d), key_(u_int32_t(key_length/8)), salt_(u_int32_t(SALT_LENGTH)) { init(key_length); } -AesIcmCipher::AesIcmCipher(kd_dir_t d, bool a, u_int16_t key_length) : Cipher(d, a), key_(u_int32_t(key_length/8)), salt_(u_int32_t(SALT_LENGTH)) -{ - init(key_length); -} - void AesIcmCipher::init(u_int16_t key_length) { #ifndef USE_SSL_CRYPTO @@ -142,12 +131,6 @@ void AesIcmCipher::calcCtr(KeyDerivation& kd, seq_nr_t seq_nr, sender_id_t sende { kd.generate(dir_, LABEL_SALT, seq_nr, salt_); - - if(anytun02_compat_) { - if(!salt_[u_int32_t(0)]) - salt_[u_int32_t(0)] = 1; - } - std::memcpy(ctr_.salt_.buf_, salt_.getBuf(), SALT_LENGTH); ctr_.salt_.zero_ = 0; ctr_.params_.mux_ ^= MUX_T_HTON(mux); -- cgit v1.2.3