In the Linux kernel, the following vulnerability has been resolved:
ubi: Fix unreferenced object reported by kmemleak in ubiresizevolume()
There is a memory leaks problem reported by kmemleak:
unreferenced object 0xffff888102007a00 (size 128): comm "ubirsvol", pid 32090, jiffies 4298464136 (age 2361.231s) hex dump (first 32 bytes): ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ................ ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ................ backtrace: [<ffffffff8176cecd>] _kmalloc+0x4d/0x150 [<ffffffffa02a9a36>] ubiebacreatetable+0x76/0x170 [ubi] [<ffffffffa029764e>] ubiresizevolume+0x1be/0xbc0 [ubi] [<ffffffffa02a3321>] ubicdevioctl+0x701/0x1850 [ubi] [<ffffffff81975d2d>] _x64sysioctl+0x11d/0x170 [<ffffffff83c142a5>] dosyscall64+0x35/0x80 [<ffffffff83e0006a>] entrySYSCALL64after_hwframe+0x46/0xb0
This is due to a mismatch between create and destroy interfaces, and in detail that "newebatbl" created by ubiebacreatetable() but destroyed by kfree(), while will causing "neweba_tbl->entries" not freed.
Fix it by replacing kfree(newebatbl) with ubiebadestroytable(neweba_tbl)
{
"cna_assigner": "Linux",
"osv_generated_from": "https://github.com/CVEProject/cvelistV5/tree/main/cves/2023/53xxx/CVE-2023-53271.json"
}"https://storage.googleapis.com/cve-osv-conversion/osv-output/CVE-2023-53271.json"
[
{
"id": "CVE-2023-53271-769d0010",
"digest": {
"threshold": 0.9,
"line_hashes": [
"248478191638914364829287144783756843983",
"232307358800352695038801912863573949892",
"9198411428920604010538993679887897623",
"133904820232346996069971447887961045685"
]
},
"signature_type": "Line",
"target": {
"file": "drivers/mtd/ubi/vmt.c"
},
"signature_version": "v1",
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@31d60afe2cc2b712dbefcaab6b7d6a47036f844e",
"deprecated": false
},
{
"id": "CVE-2023-53271-a653d487",
"digest": {
"threshold": 0.9,
"line_hashes": [
"248478191638914364829287144783756843983",
"232307358800352695038801912863573949892",
"9198411428920604010538993679887897623",
"133904820232346996069971447887961045685"
]
},
"signature_type": "Line",
"target": {
"file": "drivers/mtd/ubi/vmt.c"
},
"signature_version": "v1",
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@95a72417dd13ebcdcb1bd0c5d4d15f7c5bfbb288",
"deprecated": false
},
{
"id": "CVE-2023-53271-b2c843e1",
"digest": {
"threshold": 0.9,
"line_hashes": [
"248478191638914364829287144783756843983",
"232307358800352695038801912863573949892",
"9198411428920604010538993679887897623",
"133904820232346996069971447887961045685"
]
},
"signature_type": "Line",
"target": {
"file": "drivers/mtd/ubi/vmt.c"
},
"signature_version": "v1",
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@26ec2d66aecab8ff997b912c20247fedba4f5740",
"deprecated": false
},
{
"id": "CVE-2023-53271-b8c3e6e1",
"digest": {
"threshold": 0.9,
"line_hashes": [
"248478191638914364829287144783756843983",
"232307358800352695038801912863573949892",
"9198411428920604010538993679887897623",
"133904820232346996069971447887961045685"
]
},
"signature_type": "Line",
"target": {
"file": "drivers/mtd/ubi/vmt.c"
},
"signature_version": "v1",
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@1e591ea072df7211f64542a09482b5f81cb3ad27",
"deprecated": false
},
{
"id": "CVE-2023-53271-d3d13d3b",
"digest": {
"threshold": 0.9,
"line_hashes": [
"248478191638914364829287144783756843983",
"232307358800352695038801912863573949892",
"9198411428920604010538993679887897623",
"133904820232346996069971447887961045685"
]
},
"signature_type": "Line",
"target": {
"file": "drivers/mtd/ubi/vmt.c"
},
"signature_version": "v1",
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@07b60f7452d2fa731737552937cb81821919f874",
"deprecated": false
},
{
"id": "CVE-2023-53271-e663f921",
"digest": {
"threshold": 0.9,
"line_hashes": [
"248478191638914364829287144783756843983",
"232307358800352695038801912863573949892",
"9198411428920604010538993679887897623",
"133904820232346996069971447887961045685"
]
},
"signature_type": "Line",
"target": {
"file": "drivers/mtd/ubi/vmt.c"
},
"signature_version": "v1",
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@09780a44093b53f9cbca76246af2e4ff0884e512",
"deprecated": false
},
{
"id": "CVE-2023-53271-e82dc972",
"digest": {
"threshold": 0.9,
"line_hashes": [
"248478191638914364829287144783756843983",
"232307358800352695038801912863573949892",
"9198411428920604010538993679887897623",
"133904820232346996069971447887961045685"
]
},
"signature_type": "Line",
"target": {
"file": "drivers/mtd/ubi/vmt.c"
},
"signature_version": "v1",
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@27b760b81951d8d5e5c952a696af8574052b0709",
"deprecated": false
}
]