diff --git a/core/rtw_security.c b/core/rtw_security.c index f8bea04..6c0c85c 100644 --- a/core/rtw_security.c +++ b/core/rtw_security.c @@ -1131,13 +1131,8 @@ _func_enter_; if (!qc_exists) mic_iv[1] = 0x00; for (i = 2; i < 8; i++) mic_iv[i] = mpdu[i + 8]; /* mic_iv[2:7] = A2[0:5] = mpdu[10:15] */ - #ifdef CONSISTENT_PN_ORDER - for (i = 8; i < 14; i++) - mic_iv[i] = pn_vector[i - 8]; /* mic_iv[8:13] = PN[0:5] */ - #else for (i = 8; i < 14; i++) mic_iv[i] = pn_vector[13 - i]; /* mic_iv[8:13] = PN[5:0] */ - #endif mic_iv[14] = (unsigned char) (payload_length / 256); mic_iv[15] = (unsigned char) (payload_length % 256); _func_exit_; @@ -1254,19 +1249,13 @@ _func_enter_; for (i = 2; i < 8; i++) ctr_preload[i] = mpdu[i + 8]; /* ctr_preload[2:7] = A2[0:5] = mpdu[10:15] */ - #ifdef CONSISTENT_PN_ORDER - for (i = 8; i < 14; i++) - ctr_preload[i] = pn_vector[i - 8]; /* ctr_preload[8:13] = PN[0:5] */ - #else for (i = 8; i < 14; i++) ctr_preload[i] = pn_vector[13 - i]; /* ctr_preload[8:13] = PN[5:0] */ - #endif ctr_preload[14] = (unsigned char) (c / 256); /* Ctr */ ctr_preload[15] = (unsigned char) (c % 256); _func_exit_; } - /************************************/ /* bitwise_xor() */ /* A 128 bit, bitwise exclusive or */ @@ -1276,9 +1265,7 @@ static void bitwise_xor(u8 *ina, u8 *inb, u8 *out) sint i; _func_enter_; for (i=0; i<16; i++) - { out[i] = ina[i] ^ inb[i]; - } _func_exit_; }