In the Linux kernel, the following vulnerability has been resolved:
drm/amd/display: Do not return negative stream id for array
[WHY] resourcestreamtostreamidx returns an array index and it return -1 when not found; however, -1 is not a valid array index number.
[HOW] When this happens, call ASSERT(), and return a zero instead.
This fixes an OVERRUN and an NEGATIVE_RETURNS issues reported by Coverity.
[
{
"signature_type": "Function",
"deprecated": false,
"signature_version": "v1",
"digest": {
"length": 216.0,
"function_hash": "251981065733176407400459005397939079282"
},
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@a76fa9c4f0fc0aa6f517da3fa7d7c23e8a32c7d0",
"target": {
"file": "drivers/gpu/drm/amd/display/dc/core/dc_resource.c",
"function": "resource_stream_to_stream_idx"
},
"id": "CVE-2024-42118-00faf921"
},
{
"signature_type": "Function",
"deprecated": false,
"signature_version": "v1",
"digest": {
"length": 216.0,
"function_hash": "251981065733176407400459005397939079282"
},
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@3ac31c9a707dd1c7c890b95333182f955e9dcb57",
"target": {
"file": "drivers/gpu/drm/amd/display/dc/core/dc_resource.c",
"function": "resource_stream_to_stream_idx"
},
"id": "CVE-2024-42118-49070ce4"
},
{
"signature_type": "Line",
"deprecated": false,
"signature_version": "v1",
"digest": {
"line_hashes": [
"235693729205639228391750421861418344753",
"278943477716875900042239502659029715456",
"5553980351730179171734167349505237313",
"107433688815963892872116732409393220937"
],
"threshold": 0.9
},
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@a76fa9c4f0fc0aa6f517da3fa7d7c23e8a32c7d0",
"target": {
"file": "drivers/gpu/drm/amd/display/dc/core/dc_resource.c"
},
"id": "CVE-2024-42118-bd4461a3"
},
{
"signature_type": "Line",
"deprecated": false,
"signature_version": "v1",
"digest": {
"line_hashes": [
"235693729205639228391750421861418344753",
"278943477716875900042239502659029715456",
"5553980351730179171734167349505237313",
"107433688815963892872116732409393220937"
],
"threshold": 0.9
},
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@3ac31c9a707dd1c7c890b95333182f955e9dcb57",
"target": {
"file": "drivers/gpu/drm/amd/display/dc/core/dc_resource.c"
},
"id": "CVE-2024-42118-f202dea8"
}
]