@@ -167,7 +167,7 @@ void ieee80211_get_tkip_key(struct ieee80211_key_conf *keyconf,
167
167
tk = & key -> conf .key [ALG_TKIP_TEMP_ENCR_KEY ];
168
168
ctx = & key -> u .tkip .tx ;
169
169
170
- #ifdef CONFIG_TKIP_DEBUG
170
+ #ifdef CONFIG_MAC80211_TKIP_DEBUG
171
171
printk (KERN_DEBUG "TKIP encrypt: iv16 = 0x%04x, iv32 = 0x%08x\n" ,
172
172
iv16 , iv32 );
173
173
@@ -177,7 +177,7 @@ void ieee80211_get_tkip_key(struct ieee80211_key_conf *keyconf,
177
177
printk (KERN_DEBUG "Wrap around of iv16 in the middle of a "
178
178
"fragmented packet\n" );
179
179
}
180
- #endif /* CONFIG_TKIP_DEBUG */
180
+ #endif
181
181
182
182
/* Update the p1k only when the iv16 in the packet wraps around, this
183
183
* might occur after the wrap around of iv16 in the key in case of
@@ -240,7 +240,7 @@ int ieee80211_tkip_decrypt_data(struct crypto_blkcipher *tfm,
240
240
keyid = pos [3 ];
241
241
iv32 = get_unaligned_le32 (pos + 4 );
242
242
pos += 8 ;
243
- #ifdef CONFIG_TKIP_DEBUG
243
+ #ifdef CONFIG_MAC80211_TKIP_DEBUG
244
244
{
245
245
int i ;
246
246
printk (KERN_DEBUG "TKIP decrypt: data(len=%zd)" , payload_len );
@@ -250,7 +250,7 @@ int ieee80211_tkip_decrypt_data(struct crypto_blkcipher *tfm,
250
250
printk (KERN_DEBUG "TKIP decrypt: iv16=%04x iv32=%08x\n" ,
251
251
iv16 , iv32 );
252
252
}
253
- #endif /* CONFIG_TKIP_DEBUG */
253
+ #endif
254
254
255
255
if (!(keyid & (1 << 5 )))
256
256
return TKIP_DECRYPT_NO_EXT_IV ;
@@ -262,14 +262,14 @@ int ieee80211_tkip_decrypt_data(struct crypto_blkcipher *tfm,
262
262
(iv32 < key -> u .tkip .rx [queue ].iv32 ||
263
263
(iv32 == key -> u .tkip .rx [queue ].iv32 &&
264
264
iv16 <= key -> u .tkip .rx [queue ].iv16 ))) {
265
- #ifdef CONFIG_TKIP_DEBUG
265
+ #ifdef CONFIG_MAC80211_TKIP_DEBUG
266
266
DECLARE_MAC_BUF (mac );
267
267
printk (KERN_DEBUG "TKIP replay detected for RX frame from "
268
268
"%s (RX IV (%04x,%02x) <= prev. IV (%04x,%02x)\n" ,
269
269
print_mac (mac , ta ),
270
270
iv32 , iv16 , key -> u .tkip .rx [queue ].iv32 ,
271
271
key -> u .tkip .rx [queue ].iv16 );
272
- #endif /* CONFIG_TKIP_DEBUG */
272
+ #endif
273
273
return TKIP_DECRYPT_REPLAY ;
274
274
}
275
275
@@ -283,7 +283,7 @@ int ieee80211_tkip_decrypt_data(struct crypto_blkcipher *tfm,
283
283
key -> u .tkip .rx [queue ].iv32 != iv32 ) {
284
284
/* IV16 wrapped around - perform TKIP phase 1 */
285
285
tkip_mixing_phase1 (tk , & key -> u .tkip .rx [queue ], ta , iv32 );
286
- #ifdef CONFIG_TKIP_DEBUG
286
+ #ifdef CONFIG_MAC80211_TKIP_DEBUG
287
287
{
288
288
int i ;
289
289
DECLARE_MAC_BUF (mac );
@@ -299,7 +299,7 @@ int ieee80211_tkip_decrypt_data(struct crypto_blkcipher *tfm,
299
299
printk ("%04x " , key -> u .tkip .rx [queue ].p1k [i ]);
300
300
printk ("\n" );
301
301
}
302
- #endif /* CONFIG_TKIP_DEBUG */
302
+ #endif
303
303
if (key -> local -> ops -> update_tkip_key &&
304
304
key -> flags & KEY_FLAG_UPLOADED_TO_HARDWARE ) {
305
305
u8 bcast [ETH_ALEN ] =
@@ -316,15 +316,15 @@ int ieee80211_tkip_decrypt_data(struct crypto_blkcipher *tfm,
316
316
}
317
317
318
318
tkip_mixing_phase2 (tk , & key -> u .tkip .rx [queue ], iv16 , rc4key );
319
- #ifdef CONFIG_TKIP_DEBUG
319
+ #ifdef CONFIG_MAC80211_TKIP_DEBUG
320
320
{
321
321
int i ;
322
322
printk (KERN_DEBUG "TKIP decrypt: Phase2 rc4key=" );
323
323
for (i = 0 ; i < 16 ; i ++ )
324
324
printk ("%02x " , rc4key [i ]);
325
325
printk ("\n" );
326
326
}
327
- #endif /* CONFIG_TKIP_DEBUG */
327
+ #endif
328
328
329
329
res = ieee80211_wep_decrypt_data (tfm , rc4key , 16 , pos , payload_len - 12 );
330
330
done :
0 commit comments