In the Linux kernel, the following vulnerability has been resolved:
fs/ntfs3: Fix null-ptr-deref on inode->iop in ntfslookup()
Syzbot reported a null-ptr-deref bug:
ntfs3: loop0: Different NTFS' sector size (1024) and media sector size (512) ntfs3: loop0: Mark volume as dirty due to NTFS errors general protection fault, probably for non-canonical address 0xdffffc0000000001: 0000 [#1] PREEMPT SMP KASAN KASAN: null-ptr-deref in range [0x0000000000000008-0x000000000000000f] RIP: 0010:dflagsfor_inode fs/dcache.c:1980 [inline] RIP: 0010:__dadd+0x5ce/0x800 fs/dcache.c:2796 Call Trace: <TASK> dsplicealias+0x122/0x3b0 fs/dcache.c:3191 lookupopen fs/namei.c:3391 [inline] openlastlookups fs/namei.c:3481 [inline] pathopenat+0x10e6/0x2df0 fs/namei.c:3688 dofilpopen+0x264/0x4f0 fs/namei.c:3718 dosysopenat2+0x124/0x4e0 fs/open.c:1310 dosys_open fs/open.c:1326 [inline] __dosysopen fs/open.c:1334 [inline] __sesysopen fs/open.c:1330 [inline] __x64sysopen+0x221/0x270 fs/open.c:1330 dosyscallx64 arch/x86/entry/common.c:50 [inline] dosyscall64+0x3d/0xb0 arch/x86/entry/common.c:80 entrySYSCALL64afterhwframe+0x63/0xcd
If the MFT record of ntfs inode is not a base record, inode->i_op can be NULL. And a null-ptr-deref may happen:
ntfslookup() dirsearchu() # inode->iop is set to NULL dsplicealias() __dadd() dflagsforinode() # inode->iop->getlink null-ptr-deref
Fix this by adding a Check on inode->iop before calling the dsplice_alias() function.
{
"cna_assigner": "Linux",
"osv_generated_from": "https://github.com/CVEProject/cvelistV5/tree/main/cves/2023/53xxx/CVE-2023-53294.json"
}[
{
"digest": {
"function_hash": "254707678378968428247450693255876595570",
"length": 525.0
},
"deprecated": false,
"signature_type": "Function",
"signature_version": "v1",
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@254e69f284d7270e0abdc023ee53b71401c3ba0c",
"id": "CVE-2023-53294-2a3c7025",
"target": {
"function": "ntfs_lookup",
"file": "fs/ntfs3/namei.c"
}
},
{
"digest": {
"line_hashes": [
"182756738179771726541236642479862436732",
"88055823424821808319483903283705918293",
"34969045355162484097119332951960298633"
],
"threshold": 0.9
},
"deprecated": false,
"signature_type": "Line",
"signature_version": "v1",
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@d69d5e2a81df94534bdb468bcdd26060fcb7191a",
"id": "CVE-2023-53294-3fc3f879",
"target": {
"file": "fs/ntfs3/namei.c"
}
},
{
"digest": {
"function_hash": "254707678378968428247450693255876595570",
"length": 525.0
},
"deprecated": false,
"signature_type": "Function",
"signature_version": "v1",
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@e78240bc4b94fc42854d65e657bb998100cc8e1b",
"id": "CVE-2023-53294-4cf34661",
"target": {
"function": "ntfs_lookup",
"file": "fs/ntfs3/namei.c"
}
},
{
"digest": {
"function_hash": "254707678378968428247450693255876595570",
"length": 525.0
},
"deprecated": false,
"signature_type": "Function",
"signature_version": "v1",
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@d69d5e2a81df94534bdb468bcdd26060fcb7191a",
"id": "CVE-2023-53294-6cf0fb3a",
"target": {
"function": "ntfs_lookup",
"file": "fs/ntfs3/namei.c"
}
},
{
"digest": {
"line_hashes": [
"182756738179771726541236642479862436732",
"88055823424821808319483903283705918293",
"170049215870624927416810474196859007966"
],
"threshold": 0.9
},
"deprecated": false,
"signature_type": "Line",
"signature_version": "v1",
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@254e69f284d7270e0abdc023ee53b71401c3ba0c",
"id": "CVE-2023-53294-6fdc46b3",
"target": {
"file": "fs/ntfs3/namei.c"
}
},
{
"digest": {
"line_hashes": [
"182756738179771726541236642479862436732",
"88055823424821808319483903283705918293",
"34969045355162484097119332951960298633"
],
"threshold": 0.9
},
"deprecated": false,
"signature_type": "Line",
"signature_version": "v1",
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@2ba22cbc6a1cf4b58195adbee0b80262e53992d3",
"id": "CVE-2023-53294-8c05a372",
"target": {
"file": "fs/ntfs3/namei.c"
}
},
{
"digest": {
"line_hashes": [
"182756738179771726541236642479862436732",
"88055823424821808319483903283705918293",
"34969045355162484097119332951960298633"
],
"threshold": 0.9
},
"deprecated": false,
"signature_type": "Line",
"signature_version": "v1",
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@f8d9e062a695a3665c4635c4f216a75912687598",
"id": "CVE-2023-53294-ac5f12de",
"target": {
"file": "fs/ntfs3/namei.c"
}
},
{
"digest": {
"function_hash": "254707678378968428247450693255876595570",
"length": 525.0
},
"deprecated": false,
"signature_type": "Function",
"signature_version": "v1",
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@f8d9e062a695a3665c4635c4f216a75912687598",
"id": "CVE-2023-53294-b362bfb0",
"target": {
"function": "ntfs_lookup",
"file": "fs/ntfs3/namei.c"
}
},
{
"digest": {
"line_hashes": [
"182756738179771726541236642479862436732",
"88055823424821808319483903283705918293",
"170049215870624927416810474196859007966"
],
"threshold": 0.9
},
"deprecated": false,
"signature_type": "Line",
"signature_version": "v1",
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@e78240bc4b94fc42854d65e657bb998100cc8e1b",
"id": "CVE-2023-53294-d1e27771",
"target": {
"file": "fs/ntfs3/namei.c"
}
},
{
"digest": {
"function_hash": "254707678378968428247450693255876595570",
"length": 525.0
},
"deprecated": false,
"signature_type": "Function",
"signature_version": "v1",
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@2ba22cbc6a1cf4b58195adbee0b80262e53992d3",
"id": "CVE-2023-53294-eb2a99e1",
"target": {
"function": "ntfs_lookup",
"file": "fs/ntfs3/namei.c"
}
}
]
"https://storage.googleapis.com/osv-test-cve-osv-conversion/osv-output/CVE-2023-53294.json"