In the Linux kernel, the following vulnerability has been resolved:
blk-cgroup: Reinit blkgiostatset after clearing in blkcgresetstats()
When blkgalloc() is called to allocate a blkcggq structure with the associated blkgiostatset's, there are 2 fields within blkgiostatset that requires proper initialization - blkg & sync. The former field was introduced by commit 3b8cc6298724 ("blk-cgroup: Optimize blkcgrstatflush()") while the later one was introduced by commit f73316482977 ("blk-cgroup: reimplement basic IO stats using cgroup rstat").
Unfortunately those fields in the blkgiostatset's are not properly re-initialized when they are cleared in v1's blkcgresetstats(). This can lead to a kernel panic due to NULL pointer access of the blkg pointer. The missing initialization of sync is less problematic and can be a problem in a debug kernel due to missing lockdep initialization.
Fix these problems by re-initializing them after memory clearing.
[
{
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@3d2af77e31ade05ff7ccc3658c3635ec1bea0979",
"target": {
"file": "block/blk-cgroup.c"
},
"deprecated": false,
"id": "CVE-2023-53421-50e4cae1",
"signature_version": "v1",
"signature_type": "Line",
"digest": {
"threshold": 0.9,
"line_hashes": [
"290014902569720783643080683492689243244",
"120265781749003002339414864443251398349",
"64370558120763108421131524262904331666",
"139968794562554890116676860910266164692",
"89563489777820433419718449536727250593",
"117079074273518157438732668390719838026"
]
}
},
{
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@3d2af77e31ade05ff7ccc3658c3635ec1bea0979",
"target": {
"function": "blkcg_reset_stats",
"file": "block/blk-cgroup.c"
},
"deprecated": false,
"id": "CVE-2023-53421-82886a79",
"signature_version": "v1",
"signature_type": "Function",
"digest": {
"length": 724.0,
"function_hash": "157848674336094183397908253190475619184"
}
},
{
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@abbce7f82613ea5eeefd0fc3c1c8e449b9cef2a2",
"target": {
"file": "block/blk-cgroup.c"
},
"deprecated": false,
"id": "CVE-2023-53421-c785463d",
"signature_version": "v1",
"signature_type": "Line",
"digest": {
"threshold": 0.9,
"line_hashes": [
"290014902569720783643080683492689243244",
"120265781749003002339414864443251398349",
"64370558120763108421131524262904331666",
"139968794562554890116676860910266164692",
"89563489777820433419718449536727250593",
"117079074273518157438732668390719838026"
]
}
},
{
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@b0d26283af612b9e0cc3188b0b88ad7fdea447e8",
"target": {
"file": "block/blk-cgroup.c"
},
"deprecated": false,
"id": "CVE-2023-53421-dcf510bd",
"signature_version": "v1",
"signature_type": "Line",
"digest": {
"threshold": 0.9,
"line_hashes": [
"290014902569720783643080683492689243244",
"120265781749003002339414864443251398349",
"64370558120763108421131524262904331666",
"139968794562554890116676860910266164692",
"89563489777820433419718449536727250593",
"117079074273518157438732668390719838026"
]
}
},
{
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@b0d26283af612b9e0cc3188b0b88ad7fdea447e8",
"target": {
"function": "blkcg_reset_stats",
"file": "block/blk-cgroup.c"
},
"deprecated": false,
"id": "CVE-2023-53421-f12b4955",
"signature_version": "v1",
"signature_type": "Function",
"digest": {
"length": 724.0,
"function_hash": "157848674336094183397908253190475619184"
}
},
{
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@abbce7f82613ea5eeefd0fc3c1c8e449b9cef2a2",
"target": {
"function": "blkcg_reset_stats",
"file": "block/blk-cgroup.c"
},
"deprecated": false,
"id": "CVE-2023-53421-fdc4534f",
"signature_version": "v1",
"signature_type": "Function",
"digest": {
"length": 724.0,
"function_hash": "157848674336094183397908253190475619184"
}
}
]