Skip to content

Commit 3be9d9e

Browse files
committed
i40e: fix input validation logic for action_meta
jira KERNEL-238 cve CVE-2025-39970 Rebuild_History Non-Buildable kernel-6.12.0-124.16.1.el10_1 commit-author Lukasz Czapnik <lukasz.czapnik@intel.com> commit 9739d58 Fix condition to check 'greater or equal' to prevent OOB dereference. Fixes: e284fc2 ("i40e: Add and delete cloud filter") Cc: stable@vger.kernel.org Signed-off-by: Lukasz Czapnik <lukasz.czapnik@intel.com> Reviewed-by: Aleksandr Loktionov <aleksandr.loktionov@intel.com> Signed-off-by: Przemek Kitszel <przemyslaw.kitszel@intel.com> Reviewed-by: Simon Horman <horms@kernel.org> Tested-by: Rafal Romanowski <rafal.romanowski@intel.com> Signed-off-by: Tony Nguyen <anthony.l.nguyen@intel.com> (cherry picked from commit 9739d58) Signed-off-by: Jonathan Maple <jmaple@ciq.com>
1 parent 6e9b8a6 commit 3be9d9e

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

drivers/net/ethernet/intel/i40e/i40e_virtchnl_pf.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3605,7 +3605,7 @@ static int i40e_validate_cloud_filter(struct i40e_vf *vf,
36053605

36063606
/* action_meta is TC number here to which the filter is applied */
36073607
if (!tc_filter->action_meta ||
3608-
tc_filter->action_meta > vf->num_tc) {
3608+
tc_filter->action_meta >= vf->num_tc) {
36093609
dev_info(&pf->pdev->dev, "VF %d: Invalid TC number %u\n",
36103610
vf->vf_id, tc_filter->action_meta);
36113611
goto err;

0 commit comments

Comments
 (0)