{"id":"CVE-2021-47159","published":"2024-03-25T09:16:13Z","modified":"2026-08-05T08:46:23Z","title":"net: dsa: fix a crash if ->get_sset_count() fails","vendor":"Linux","product":"Linux","tier":"tail","description":{"text":"In the Linux kernel, the following vulnerability has been resolved:\n\nnet: dsa: fix a crash if ->get_sset_count() fails\n\nIf ds->ops->get_sset_count() fails then it \"count\" is a negative error\ncode such as -EOPNOTSUPP.  Because \"i\" is an unsigned int, the negative\nerror code is type promoted to a very high value and the loop will\ncorrupt memory until the system crashes.\n\nFix this by checking for error codes and changing the type of \"i\" to\njust int.","provenance":"source","from":"CVE.org"},"cvss":{"score":7.8,"severity":"HIGH","version":"3.1","vector":"CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H","provenance":"source","from":"CVE.org CNA"},"epss":{"score":0.00247,"percentile":0.16285,"provenance":"source"},"cwes":[],"references":[{"url":"https://git.kernel.org/stable/c/0f2cb08c57edefb0e7b5045e0e3e9980a3d3aa37","tags":[]},{"url":"https://git.kernel.org/stable/c/ce5355f140a7987011388c7e30c4f8fbe180d3e8","tags":[]},{"url":"https://git.kernel.org/stable/c/caff86f85512b8e0d9830e8b8b0dfe13c68ce5b6","tags":[]},{"url":"https://git.kernel.org/stable/c/7b22466648a4f8e3e94f57ca428d1531866d1373","tags":[]},{"url":"https://git.kernel.org/stable/c/a269333fa5c0c8e53c92b5a28a6076a28cde3e83","tags":[]}],"priority":{"score":8.7,"factors":[{"name":"EPSS percentile","points":3.26},{"name":"CVSS severity","points":5.46}]},"vendorSlug":"linux","affectedVersions":[{"vendor":"Linux","product":"Linux","versions":[">= badf3ada60ab8f76f9488dc8f5c0c57f70682f5a, < 0f2cb08c57edefb0e7b5045e0e3e9980a3d3aa37",">= badf3ada60ab8f76f9488dc8f5c0c57f70682f5a, < ce5355f140a7987011388c7e30c4f8fbe180d3e8",">= badf3ada60ab8f76f9488dc8f5c0c57f70682f5a, < caff86f85512b8e0d9830e8b8b0dfe13c68ce5b6",">= badf3ada60ab8f76f9488dc8f5c0c57f70682f5a, < 7b22466648a4f8e3e94f57ca428d1531866d1373",">= badf3ada60ab8f76f9488dc8f5c0c57f70682f5a, < a269333fa5c0c8e53c92b5a28a6076a28cde3e83"]},{"vendor":"Linux","product":"Linux","versions":["4.7"]}],"ssvc":{"exploitation":"none","automatable":"no","technicalImpact":"partial","timestamp":"2024-09-10T15:54:44.376467Z","from":"CISA ADP","provenance":"source"},"euvd":{"id":"EUVD-2021-33807","exploited":false,"provenance":"source"}}