In the Linux kernel, the following vulnerability has been resolved:
dma-buf: Fix NULL pointer dereference in sanitycheck()
If due to a memory allocation failure mockchain() returns NULL, it is passed to dmafenceenablesw_signaling() resulting in NULL pointer dereference there.
Call dmafenceenableswsignaling() only if mock_chain() succeeds.
Found by Linux Verification Center (linuxtesting.org) with SVACE.
[
{
"signature_type": "Line",
"deprecated": false,
"target": {
"file": "drivers/dma-buf/st-dma-fence-chain.c"
},
"signature_version": "v1",
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@156c226cbbdcf5f3bce7b2408a33b59fab7fae2c",
"digest": {
"line_hashes": [
"249841693038308009061269137382771593006",
"257821195211692184687636679722622392234",
"203868587428196183786989904951095278579",
"170249619505920775864933987682272409492",
"74116720861380688922706607465850670162",
"9172595770689384504577204356200934015"
],
"threshold": 0.9
},
"id": "CVE-2024-35916-30b74288"
},
{
"signature_type": "Function",
"deprecated": false,
"target": {
"file": "drivers/dma-buf/st-dma-fence-chain.c",
"function": "sanitycheck"
},
"signature_version": "v1",
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@2295bd846765c766701e666ed2e4b35396be25e6",
"digest": {
"length": 288.0,
"function_hash": "330483621667155223224766049915531542706"
},
"id": "CVE-2024-35916-97410ded"
},
{
"signature_type": "Line",
"deprecated": false,
"target": {
"file": "drivers/dma-buf/st-dma-fence-chain.c"
},
"signature_version": "v1",
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@2295bd846765c766701e666ed2e4b35396be25e6",
"digest": {
"line_hashes": [
"249841693038308009061269137382771593006",
"257821195211692184687636679722622392234",
"203868587428196183786989904951095278579",
"170249619505920775864933987682272409492",
"74116720861380688922706607465850670162",
"9172595770689384504577204356200934015"
],
"threshold": 0.9
},
"id": "CVE-2024-35916-9d47fd73"
},
{
"signature_type": "Function",
"deprecated": false,
"target": {
"file": "drivers/dma-buf/st-dma-fence-chain.c",
"function": "sanitycheck"
},
"signature_version": "v1",
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@156c226cbbdcf5f3bce7b2408a33b59fab7fae2c",
"digest": {
"length": 288.0,
"function_hash": "330483621667155223224766049915531542706"
},
"id": "CVE-2024-35916-e6337ae1"
},
{
"signature_type": "Function",
"deprecated": false,
"target": {
"file": "drivers/dma-buf/st-dma-fence-chain.c",
"function": "sanitycheck"
},
"signature_version": "v1",
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@eabf131cba1db12005a68378305f13b9090a7a6b",
"digest": {
"length": 288.0,
"function_hash": "330483621667155223224766049915531542706"
},
"id": "CVE-2024-35916-eb345137"
},
{
"signature_type": "Line",
"deprecated": false,
"target": {
"file": "drivers/dma-buf/st-dma-fence-chain.c"
},
"signature_version": "v1",
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@eabf131cba1db12005a68378305f13b9090a7a6b",
"digest": {
"line_hashes": [
"249841693038308009061269137382771593006",
"257821195211692184687636679722622392234",
"203868587428196183786989904951095278579",
"170249619505920775864933987682272409492",
"74116720861380688922706607465850670162",
"9172595770689384504577204356200934015"
],
"threshold": 0.9
},
"id": "CVE-2024-35916-f9cc006a"
}
]