In the Linux kernel, the following vulnerability has been resolved:
sockmap: fix a NULL pointer dereference in sockmaplinkupdate_prog()
The following race condition could trigger a NULL pointer dereference:
sockmaplinkdetach(): sockmaplinkupdateprog(): mutexlock(&sockmapmutex); ... sockmaplink->map = NULL; mutexunlock(&sockmapmutex); mutexlock(&sockmapmutex); ... sockmapproglinklookup(sockmaplink->map); mutexunlock(&sockmap_mutex); <continue>
Fix it by adding a NULL pointer check. In this specific case, it makes no sense to update a link which is being released.
[
{
"id": "CVE-2024-50260-5097cfb8",
"target": {
"file": "net/core/sock_map.c",
"function": "sock_map_link_update_prog"
},
"digest": {
"length": 899.0,
"function_hash": "242692540685651836591780878112768379637"
},
"deprecated": false,
"signature_type": "Function",
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@740be3b9a6d73336f8c7d540842d0831dc7a808b",
"signature_version": "v1"
},
{
"id": "CVE-2024-50260-776272fd",
"target": {
"file": "net/core/sock_map.c"
},
"digest": {
"threshold": 0.9,
"line_hashes": [
"7279477638862195173141896212216468962",
"70221972606552464355417679058654069516",
"305200229438868051125581561111212777729",
"117604425645086674897584206098726096581"
]
},
"deprecated": false,
"signature_type": "Line",
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@740be3b9a6d73336f8c7d540842d0831dc7a808b",
"signature_version": "v1"
},
{
"id": "CVE-2024-50260-7972f29e",
"target": {
"file": "net/core/sock_map.c",
"function": "sock_map_link_update_prog"
},
"digest": {
"length": 899.0,
"function_hash": "242692540685651836591780878112768379637"
},
"deprecated": false,
"signature_type": "Function",
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@9afe35fdda16e09d5bd3c49a68ba8c680dd678bd",
"signature_version": "v1"
},
{
"id": "CVE-2024-50260-da431158",
"target": {
"file": "net/core/sock_map.c"
},
"digest": {
"threshold": 0.9,
"line_hashes": [
"7279477638862195173141896212216468962",
"70221972606552464355417679058654069516",
"305200229438868051125581561111212777729",
"117604425645086674897584206098726096581"
]
},
"deprecated": false,
"signature_type": "Line",
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@9afe35fdda16e09d5bd3c49a68ba8c680dd678bd",
"signature_version": "v1"
}
]