mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-14 08:36:12 -04:00
qcacld-3.0: Fix TLV length check issue in unpack tlv
In unpack tlv, length of tag and length fields are not considered while checking for min length for the tag, this result into failure in unpacking the TLV. Fix it by including length of tag and length fields while checking for min length. Change-Id: Icf06b935a883e41426f5fcd1668ad8461b58349f CRs-Fixed: 2070452
This commit is contained in:
parent
4db8c1521c
commit
f3cc07311a
1 changed files with 2 additions and 2 deletions
|
|
@ -33,7 +33,7 @@
|
|||
*
|
||||
*
|
||||
* This file was automatically generated by 'framesc'
|
||||
* Fri Jul 14 12:29:59 2017 from the following file(s):
|
||||
* Wed Jul 26 14:38:34 2017 from the following file(s):
|
||||
*
|
||||
* dot11f.frms
|
||||
*
|
||||
|
|
@ -12111,7 +12111,7 @@ static uint32_t unpack_tlv_core(tpAniSirGlobal pCtx,
|
|||
|
||||
/* Now, *if* we found a hit... */
|
||||
if (pTlv) {
|
||||
if (len < pTlv->minSize - npec) {
|
||||
if (len + (pTlv->sType + pTlv->sLen) < pTlv->minSize - npec) {
|
||||
FRAMES_LOG3(pCtx, FRLOGW, FRFL("The IE %s must be "
|
||||
"at least %d bytes in size, but the size is only "
|
||||
"%d bytes.\n"),
|
||||
|
|
|
|||
Loading…
Reference in a new issue