cve-2024-39296
Vulnerability from cvelistv5
Published
2024-06-25 14:22
Modified
2024-12-19 09:06
Severity ?
EPSS score ?
Summary
In the Linux kernel, the following vulnerability has been resolved:
bonding: fix oops during rmmod
"rmmod bonding" causes an oops ever since commit cc317ea3d927 ("bonding:
remove redundant NULL check in debugfs function"). Here are the relevant
functions being called:
bonding_exit()
bond_destroy_debugfs()
debugfs_remove_recursive(bonding_debug_root);
bonding_debug_root = NULL; <--------- SET TO NULL HERE
bond_netlink_fini()
rtnl_link_unregister()
__rtnl_link_unregister()
unregister_netdevice_many_notify()
bond_uninit()
bond_debug_unregister()
(commit removed check for bonding_debug_root == NULL)
debugfs_remove()
simple_recursive_removal()
down_write() -> OOPS
However, reverting the bad commit does not solve the problem completely
because the original code contains a race that could cause the same
oops, although it was much less likely to be triggered unintentionally:
CPU1
rmmod bonding
bonding_exit()
bond_destroy_debugfs()
debugfs_remove_recursive(bonding_debug_root);
CPU2
echo -bond0 > /sys/class/net/bonding_masters
bond_uninit()
bond_debug_unregister()
if (!bonding_debug_root)
CPU1
bonding_debug_root = NULL;
So do NOT revert the bad commit (since the removed checks were racy
anyway), and instead change the order of actions taken during module
removal. The same oops can also happen if there is an error during
module init, so apply the same fix there.
References
Impacted products
{ "containers": { "adp": [ { "metrics": [ { "other": { "content": { "id": "CVE-2024-39296", "options": [ { "Exploitation": "none" }, { "Automatable": "no" }, { "Technical Impact": "partial" } ], "role": "CISA Coordinator", "timestamp": "2024-06-25T20:46:46.560534Z", "version": "2.0.3" }, "type": "ssvc" } } ], "providerMetadata": { "dateUpdated": "2024-06-25T20:46:55.199Z", "orgId": "134c704f-9b21-4f2e-91b3-4a467353bcc0", "shortName": "CISA-ADP" }, "title": "CISA ADP Vulnrichment" }, { "providerMetadata": { "dateUpdated": "2024-08-02T04:19:20.715Z", "orgId": "af854a3a-2127-422b-91ae-364da2661108", "shortName": "CVE" }, "references": [ { "tags": [ "x_transferred" ], "url": "https://git.kernel.org/stable/c/f07224c16678a8af54ddc059b3d2d51885d7f35e" }, { "tags": [ "x_transferred" ], "url": "https://git.kernel.org/stable/c/cf48aee81103ca06d09d73d33fb72f1191069aa6" }, { "tags": [ "x_transferred" ], "url": "https://git.kernel.org/stable/c/a45835a0bb6ef7d5ddbc0714dd760de979cb6ece" } ], "title": "CVE Program Container" } ], "cna": { "affected": [ { "defaultStatus": "unaffected", "product": "Linux", "programFiles": [ "drivers/net/bonding/bond_main.c" ], "repo": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git", "vendor": "Linux", "versions": [ { "lessThan": "f07224c16678a8af54ddc059b3d2d51885d7f35e", "status": "affected", "version": "cc317ea3d9272fab4f6fef527c865f30ca479394", "versionType": "git" }, { "lessThan": "cf48aee81103ca06d09d73d33fb72f1191069aa6", "status": "affected", "version": "cc317ea3d9272fab4f6fef527c865f30ca479394", "versionType": "git" }, { "lessThan": "a45835a0bb6ef7d5ddbc0714dd760de979cb6ece", "status": "affected", "version": "cc317ea3d9272fab4f6fef527c865f30ca479394", "versionType": "git" } ] }, { "defaultStatus": "affected", "product": "Linux", "programFiles": [ "drivers/net/bonding/bond_main.c" ], "repo": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git", "vendor": "Linux", "versions": [ { "status": "affected", "version": "6.6" }, { "lessThan": "6.6", "status": "unaffected", "version": "0", "versionType": "semver" }, { "lessThanOrEqual": "6.6.*", "status": "unaffected", "version": "6.6.34", "versionType": "semver" }, { "lessThanOrEqual": "6.9.*", "status": "unaffected", "version": "6.9.5", "versionType": "semver" }, { "lessThanOrEqual": "*", "status": "unaffected", "version": "6.10", "versionType": "original_commit_for_fix" } ] } ], "descriptions": [ { "lang": "en", "value": "In the Linux kernel, the following vulnerability has been resolved:\n\nbonding: fix oops during rmmod\n\n\"rmmod bonding\" causes an oops ever since commit cc317ea3d927 (\"bonding:\nremove redundant NULL check in debugfs function\"). Here are the relevant\nfunctions being called:\n\nbonding_exit()\n bond_destroy_debugfs()\n debugfs_remove_recursive(bonding_debug_root);\n bonding_debug_root = NULL; \u003c--------- SET TO NULL HERE\n bond_netlink_fini()\n rtnl_link_unregister()\n __rtnl_link_unregister()\n unregister_netdevice_many_notify()\n bond_uninit()\n bond_debug_unregister()\n (commit removed check for bonding_debug_root == NULL)\n debugfs_remove()\n simple_recursive_removal()\n down_write() -\u003e OOPS\n\nHowever, reverting the bad commit does not solve the problem completely\nbecause the original code contains a race that could cause the same\noops, although it was much less likely to be triggered unintentionally:\n\nCPU1\n rmmod bonding\n bonding_exit()\n bond_destroy_debugfs()\n debugfs_remove_recursive(bonding_debug_root);\n\nCPU2\n echo -bond0 \u003e /sys/class/net/bonding_masters\n bond_uninit()\n bond_debug_unregister()\n if (!bonding_debug_root)\n\nCPU1\n bonding_debug_root = NULL;\n\nSo do NOT revert the bad commit (since the removed checks were racy\nanyway), and instead change the order of actions taken during module\nremoval. The same oops can also happen if there is an error during\nmodule init, so apply the same fix there." } ], "providerMetadata": { "dateUpdated": "2024-12-19T09:06:31.541Z", "orgId": "416baaa9-dc9f-4396-8d5f-8c081fb06d67", "shortName": "Linux" }, "references": [ { "url": "https://git.kernel.org/stable/c/f07224c16678a8af54ddc059b3d2d51885d7f35e" }, { "url": "https://git.kernel.org/stable/c/cf48aee81103ca06d09d73d33fb72f1191069aa6" }, { "url": "https://git.kernel.org/stable/c/a45835a0bb6ef7d5ddbc0714dd760de979cb6ece" } ], "title": "bonding: fix oops during rmmod", "x_generator": { "engine": "bippy-5f407fcff5a0" } } }, "cveMetadata": { "assignerOrgId": "416baaa9-dc9f-4396-8d5f-8c081fb06d67", "assignerShortName": "Linux", "cveId": "CVE-2024-39296", "datePublished": "2024-06-25T14:22:40.218Z", "dateReserved": "2024-06-24T13:54:11.074Z", "dateUpdated": "2024-12-19T09:06:31.541Z", "state": "PUBLISHED" }, "dataType": "CVE_RECORD", "dataVersion": "5.1", "meta": { "nvd": "{\"cve\":{\"id\":\"CVE-2024-39296\",\"sourceIdentifier\":\"416baaa9-dc9f-4396-8d5f-8c081fb06d67\",\"published\":\"2024-06-25T15:15:14.070\",\"lastModified\":\"2024-11-21T09:27:24.520\",\"vulnStatus\":\"Awaiting Analysis\",\"cveTags\":[],\"descriptions\":[{\"lang\":\"en\",\"value\":\"In the Linux kernel, the following vulnerability has been resolved:\\n\\nbonding: fix oops during rmmod\\n\\n\\\"rmmod bonding\\\" causes an oops ever since commit cc317ea3d927 (\\\"bonding:\\nremove redundant NULL check in debugfs function\\\"). Here are the relevant\\nfunctions being called:\\n\\nbonding_exit()\\n bond_destroy_debugfs()\\n debugfs_remove_recursive(bonding_debug_root);\\n bonding_debug_root = NULL; \u003c--------- SET TO NULL HERE\\n bond_netlink_fini()\\n rtnl_link_unregister()\\n __rtnl_link_unregister()\\n unregister_netdevice_many_notify()\\n bond_uninit()\\n bond_debug_unregister()\\n (commit removed check for bonding_debug_root == NULL)\\n debugfs_remove()\\n simple_recursive_removal()\\n down_write() -\u003e OOPS\\n\\nHowever, reverting the bad commit does not solve the problem completely\\nbecause the original code contains a race that could cause the same\\noops, although it was much less likely to be triggered unintentionally:\\n\\nCPU1\\n rmmod bonding\\n bonding_exit()\\n bond_destroy_debugfs()\\n debugfs_remove_recursive(bonding_debug_root);\\n\\nCPU2\\n echo -bond0 \u003e /sys/class/net/bonding_masters\\n bond_uninit()\\n bond_debug_unregister()\\n if (!bonding_debug_root)\\n\\nCPU1\\n bonding_debug_root = NULL;\\n\\nSo do NOT revert the bad commit (since the removed checks were racy\\nanyway), and instead change the order of actions taken during module\\nremoval. The same oops can also happen if there is an error during\\nmodule init, so apply the same fix there.\"},{\"lang\":\"es\",\"value\":\"En el kernel de Linux, se ha resuelto la siguiente vulnerabilidad: vinculaci\u00f3n: corrige errores durante rmmod \\\"rmmod bonding\\\" provoca un error desde el commit cc317ea3d927 (\\\"uni\u00f3n: elimina la comprobaci\u00f3n NULL redundante en la funci\u00f3n debugfs\\\"). Aqu\u00ed est\u00e1n las funciones relevantes que se llaman: bonding_exit() bond_destroy_debugfs() debugfs_remove_recursive(bonding_debug_root); bonding_debug_root = NULL; \u0026lt;--------- ESTABLECER EN NULL AQU\u00cd bond_netlink_fini() rtnl_link_unregister() __rtnl_link_unregister() unregister_netdevice_many_notify() bond_uninit() bond_debug_unregister() (confirmar verificaci\u00f3n eliminada para bonding_debug_root == NULL) debugfs_remove() simple_recursive_removal() down_write( ) -\u0026gt; OOPS Sin embargo, revertir el compromiso incorrecto no resuelve el problema por completo porque el c\u00f3digo original contiene una ejecuci\u00f3n que podr\u00eda causar el mismo error, aunque era mucho menos probable que se activara involuntariamente: CPU1 rmmod bonding bonding_exit() bond_destroy_debugfs() debugfs_remove_recursive(bonding_debug_root); CPU2 echo -bond0 \u0026gt; /sys/class/net/bonding_masters bond_uninit() bond_debug_unregister() if (!bonding_debug_root) CPU1 bonding_debug_root = NULL; Por lo tanto, NO revierta la confirmaci\u00f3n incorrecta (ya que las comprobaciones eliminadas eran picantes de todos modos) y, en su lugar, cambie el orden de las acciones tomadas durante la eliminaci\u00f3n del m\u00f3dulo. Lo mismo tambi\u00e9n puede suceder si hay un error durante el inicio del m\u00f3dulo, as\u00ed que aplique la misma soluci\u00f3n all\u00ed.\"}],\"metrics\":{},\"references\":[{\"url\":\"https://git.kernel.org/stable/c/a45835a0bb6ef7d5ddbc0714dd760de979cb6ece\",\"source\":\"416baaa9-dc9f-4396-8d5f-8c081fb06d67\"},{\"url\":\"https://git.kernel.org/stable/c/cf48aee81103ca06d09d73d33fb72f1191069aa6\",\"source\":\"416baaa9-dc9f-4396-8d5f-8c081fb06d67\"},{\"url\":\"https://git.kernel.org/stable/c/f07224c16678a8af54ddc059b3d2d51885d7f35e\",\"source\":\"416baaa9-dc9f-4396-8d5f-8c081fb06d67\"},{\"url\":\"https://git.kernel.org/stable/c/a45835a0bb6ef7d5ddbc0714dd760de979cb6ece\",\"source\":\"af854a3a-2127-422b-91ae-364da2661108\"},{\"url\":\"https://git.kernel.org/stable/c/cf48aee81103ca06d09d73d33fb72f1191069aa6\",\"source\":\"af854a3a-2127-422b-91ae-364da2661108\"},{\"url\":\"https://git.kernel.org/stable/c/f07224c16678a8af54ddc059b3d2d51885d7f35e\",\"source\":\"af854a3a-2127-422b-91ae-364da2661108\"}]}}" } }
Loading…
Loading…
Sightings
Author | Source | Type | Date |
---|
Nomenclature
- Seen: The vulnerability was mentioned, discussed, or seen somewhere by the user.
- Confirmed: The vulnerability is confirmed from an analyst perspective.
- Exploited: This vulnerability was exploited and seen by the user reporting the sighting.
- Patched: This vulnerability was successfully patched by the user reporting the sighting.
- Not exploited: This vulnerability was not exploited or seen by the user reporting the sighting.
- Not confirmed: The user expresses doubt about the veracity of the vulnerability.
- Not patched: This vulnerability was not successfully patched by the user reporting the sighting.