From 87d7ec3737b0b3c25727b6598e04287bc8b34b58 Mon Sep 17 00:00:00 2001 From: google Date: Wed, 6 Dec 2017 11:15:29 -0800 Subject: [PATCH] qcacld-2.0: Fix incorrect frame length of encrypted auth frame STA is not able to connect to AP configured with WEP shared due to incorrect frame length of encrypted auth frame. Fix this by using the correct frame length. Bug: 67754642 Change-Id: Ida8d78b512ecf79314200a7c96f5b5c293e5474e Signed-off-by: Srinivas Girigowda --- drivers/staging/prima/CORE/MAC/src/pe/lim/limSecurityUtils.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/staging/prima/CORE/MAC/src/pe/lim/limSecurityUtils.c b/drivers/staging/prima/CORE/MAC/src/pe/lim/limSecurityUtils.c index 51171eafc7d4..6b8a9bd527f2 100644 --- a/drivers/staging/prima/CORE/MAC/src/pe/lim/limSecurityUtils.c +++ b/drivers/staging/prima/CORE/MAC/src/pe/lim/limSecurityUtils.c @@ -571,9 +571,9 @@ limEncryptAuthFrame(tpAniSirGlobal pMac, tANI_U8 keyId, tANI_U8 *pKey, tANI_U8 * palCopyMemory( pMac->hHdd, (tANI_U8 *) &seed[3], pKey, keyLength - 3); // Compute CRC-32 and place them in last 4 bytes of plain text - limComputeCrc32(icv, pPlainText, sizeof(tSirMacAuthFrameBody)); + limComputeCrc32(icv, pPlainText, framelen); - palCopyMemory( pMac->hHdd, pPlainText + sizeof(tSirMacAuthFrameBody), + palCopyMemory( pMac->hHdd, pPlainText + framelen, icv, SIR_MAC_WEP_ICV_LENGTH); // Run RC4 on plain text with the seed