In the Linux kernel, the following vulnerability has been resolved:
net: stmmac: Fix zero-division error when disabling tc cbs
The commit b8c43360f6e4 ("net: stmmac: No need to calculate speed divider when offload is disabled") allows the "porttransmitratekbps" to be set to a value of 0, which is then passed to the "divs64" function when tc-cbs is disabled. This leads to a zero-division error.
When tc-cbs is disabled, the idleslope, sendslope, and credit values the credit values are not required to be configured. Therefore, adding a return statement after setting the txQ mode to DCB when tc-cbs is disabled would prevent a zero-division error.
{
"cna_assigner": "Linux",
"osv_generated_from": "https://github.com/CVEProject/cvelistV5/tree/main/cves/2024/49xxx/CVE-2024-49977.json"
}"https://storage.googleapis.com/osv-test-cve-osv-conversion/osv-output/CVE-2024-49977.json"
[
{
"digest": {
"line_hashes": [
"80765680087690387416019767583151597225",
"244686010175476655364469732328177495673",
"198013920777896522483254785046360044847",
"90238269916925214130203985516212899399"
],
"threshold": 0.9
},
"signature_version": "v1",
"target": {
"file": "drivers/net/ethernet/stmicro/stmmac/stmmac_tc.c"
},
"signature_type": "Line",
"id": "CVE-2024-49977-29d009d2",
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@e33fe25b1efe4f2e6a5858786dbc82ae4c44ed4c",
"deprecated": false
},
{
"digest": {
"function_hash": "55205898283756482749739187460034065242",
"length": 2145.0
},
"signature_version": "v1",
"target": {
"file": "drivers/net/ethernet/stmicro/stmmac/stmmac_tc.c",
"function": "tc_setup_cbs"
},
"signature_type": "Function",
"id": "CVE-2024-49977-39ee52da",
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@b0da9504a528f05f97d926b4db74ff21917a33e9",
"deprecated": false
},
{
"digest": {
"line_hashes": [
"80765680087690387416019767583151597225",
"244686010175476655364469732328177495673",
"198013920777896522483254785046360044847",
"90238269916925214130203985516212899399"
],
"threshold": 0.9
},
"signature_version": "v1",
"target": {
"file": "drivers/net/ethernet/stmicro/stmmac/stmmac_tc.c"
},
"signature_type": "Line",
"id": "CVE-2024-49977-5e43be2b",
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@675faf5a14c14a2be0b870db30a70764df81e2df",
"deprecated": false
},
{
"digest": {
"function_hash": "55205898283756482749739187460034065242",
"length": 2145.0
},
"signature_version": "v1",
"target": {
"file": "drivers/net/ethernet/stmicro/stmmac/stmmac_tc.c",
"function": "tc_setup_cbs"
},
"signature_type": "Function",
"id": "CVE-2024-49977-89f2561b",
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@837d9df9c0792902710149d1a5e0991520af0f93",
"deprecated": false
},
{
"digest": {
"function_hash": "55205898283756482749739187460034065242",
"length": 2145.0
},
"signature_version": "v1",
"target": {
"file": "drivers/net/ethernet/stmicro/stmmac/stmmac_tc.c",
"function": "tc_setup_cbs"
},
"signature_type": "Function",
"id": "CVE-2024-49977-89f39df7",
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@e297a2bf56d12fd7f91a0c209eb6ea84361f3368",
"deprecated": false
},
{
"digest": {
"line_hashes": [
"80765680087690387416019767583151597225",
"244686010175476655364469732328177495673",
"198013920777896522483254785046360044847",
"90238269916925214130203985516212899399"
],
"threshold": 0.9
},
"signature_version": "v1",
"target": {
"file": "drivers/net/ethernet/stmicro/stmmac/stmmac_tc.c"
},
"signature_type": "Line",
"id": "CVE-2024-49977-9c3a66bf",
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@03582f4752427f60817d896f1a827aff772bd31e",
"deprecated": false
},
{
"digest": {
"line_hashes": [
"80765680087690387416019767583151597225",
"244686010175476655364469732328177495673",
"198013920777896522483254785046360044847",
"90238269916925214130203985516212899399"
],
"threshold": 0.9
},
"signature_version": "v1",
"target": {
"file": "drivers/net/ethernet/stmicro/stmmac/stmmac_tc.c"
},
"signature_type": "Line",
"id": "CVE-2024-49977-abaeb5b1",
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@837d9df9c0792902710149d1a5e0991520af0f93",
"deprecated": false
},
{
"digest": {
"line_hashes": [
"80765680087690387416019767583151597225",
"244686010175476655364469732328177495673",
"198013920777896522483254785046360044847",
"90238269916925214130203985516212899399"
],
"threshold": 0.9
},
"signature_version": "v1",
"target": {
"file": "drivers/net/ethernet/stmicro/stmmac/stmmac_tc.c"
},
"signature_type": "Line",
"id": "CVE-2024-49977-b749c7f5",
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@e297a2bf56d12fd7f91a0c209eb6ea84361f3368",
"deprecated": false
},
{
"digest": {
"line_hashes": [
"80765680087690387416019767583151597225",
"244686010175476655364469732328177495673",
"198013920777896522483254785046360044847",
"90238269916925214130203985516212899399"
],
"threshold": 0.9
},
"signature_version": "v1",
"target": {
"file": "drivers/net/ethernet/stmicro/stmmac/stmmac_tc.c"
},
"signature_type": "Line",
"id": "CVE-2024-49977-ddcde003",
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@b0da9504a528f05f97d926b4db74ff21917a33e9",
"deprecated": false
},
{
"digest": {
"line_hashes": [
"80765680087690387416019767583151597225",
"244686010175476655364469732328177495673",
"198013920777896522483254785046360044847",
"90238269916925214130203985516212899399"
],
"threshold": 0.9
},
"signature_version": "v1",
"target": {
"file": "drivers/net/ethernet/stmicro/stmmac/stmmac_tc.c"
},
"signature_type": "Line",
"id": "CVE-2024-49977-e163b8e0",
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@5d43e1ad4567d67af2b42d3ab7c14152ffed25c6",
"deprecated": false
},
{
"digest": {
"function_hash": "55205898283756482749739187460034065242",
"length": 2145.0
},
"signature_version": "v1",
"target": {
"file": "drivers/net/ethernet/stmicro/stmmac/stmmac_tc.c",
"function": "tc_setup_cbs"
},
"signature_type": "Function",
"id": "CVE-2024-49977-e23c75c0",
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@5d43e1ad4567d67af2b42d3ab7c14152ffed25c6",
"deprecated": false
},
{
"digest": {
"function_hash": "55205898283756482749739187460034065242",
"length": 2145.0
},
"signature_version": "v1",
"target": {
"file": "drivers/net/ethernet/stmicro/stmmac/stmmac_tc.c",
"function": "tc_setup_cbs"
},
"signature_type": "Function",
"id": "CVE-2024-49977-ee3816df",
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@03582f4752427f60817d896f1a827aff772bd31e",
"deprecated": false
},
{
"digest": {
"function_hash": "55205898283756482749739187460034065242",
"length": 2145.0
},
"signature_version": "v1",
"target": {
"file": "drivers/net/ethernet/stmicro/stmmac/stmmac_tc.c",
"function": "tc_setup_cbs"
},
"signature_type": "Function",
"id": "CVE-2024-49977-fc85e87a",
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@e33fe25b1efe4f2e6a5858786dbc82ae4c44ed4c",
"deprecated": false
},
{
"digest": {
"function_hash": "55205898283756482749739187460034065242",
"length": 2145.0
},
"signature_version": "v1",
"target": {
"file": "drivers/net/ethernet/stmicro/stmmac/stmmac_tc.c",
"function": "tc_setup_cbs"
},
"signature_type": "Function",
"id": "CVE-2024-49977-fee92d3e",
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@675faf5a14c14a2be0b870db30a70764df81e2df",
"deprecated": false
}
]