ソースを参照

qcacld-3.0: Fix out-of-bounds access in ol_rx_indication_handler

Fix overrunning callee's array of size 19 by evaluating argument tid
not to pass the maximum number.

Change-Id: I993339f4b9aea51e9566d213c9828825c5f2bf66
CRs-Fixed: 2232744
Yun Park 6 年 前
コミット
4dcc193aa8
1 ファイル変更6 行追加0 行削除
  1. 6 0
      core/dp/txrx/ol_rx.c

+ 6 - 0
core/dp/txrx/ol_rx.c

@@ -538,6 +538,12 @@ ol_rx_indication_handler(ol_txrx_pdev_handle pdev,
 			 */
 			ol_rx_reorder_peer_cleanup(vdev, peer);
 		} else {
+			if (tid >= OL_TXRX_NUM_EXT_TIDS) {
+				ol_txrx_err("%s:  invalid tid, %u\n",
+					    __func__, tid);
+				WARN_ON(1);
+				return;
+			}
 			ol_rx_reorder_flush(vdev, peer, tid, seq_num_start,
 					    seq_num_end, htt_rx_flush_release);
 		}