In the Linux kernel, the following vulnerability has been resolved:
f2fs: fix null-ptr-deref in f2fssubmitpage_bio()
There's issue as follows when concurrently installing the f2fs.ko module and mounting the f2fs file system: KASAN: null-ptr-deref in range [0x0000000000000020-0x0000000000000027] RIP: 0010:_bioalloc+0x2fb/0x6c0 [f2fs] Call Trace: <TASK> f2fssubmitpagebio+0x126/0x8b0 [f2fs] _getmetapage+0x1d4/0x920 [f2fs] getcheckpointversion.constprop.0+0x2b/0x3c0 [f2fs] validatecheckpoint+0xac/0x290 [f2fs] f2fsgetvalidcheckpoint+0x207/0x950 [f2fs] f2fsfillsuper+0x1007/0x39b0 [f2fs] mountbdev+0x183/0x250 legacygettree+0xf4/0x1e0 vfsgettree+0x88/0x340 donewmount+0x283/0x5e0 pathmount+0x2b2/0x15b0 _x64sysmount+0x1fe/0x270 dosyscall64+0x5f/0x170 entrySYSCALL64after_hwframe+0x76/0x7e
Above issue happens as the biset of the f2fs file system is not initialized before register "f2fsfstype". To address above issue just register "f2fsfstype" at the last in initf2fsfs(). Ensure that all f2fs file system resources are initialized.
[
{
"deprecated": false,
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@32f5e291b7677495f98246eec573767430321c08",
"id": "CVE-2024-53221-11247771",
"digest": {
"function_hash": "106807216853565903986030263139043404500",
"length": 320.0
},
"target": {
"function": "exit_f2fs_fs",
"file": "fs/f2fs/super.c"
},
"signature_type": "Function",
"signature_version": "v1"
},
{
"deprecated": false,
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@8dddc12d03248755d9f709bc1eb9e3ea2bf1b322",
"id": "CVE-2024-53221-210a64d8",
"digest": {
"threshold": 0.9,
"line_hashes": [
"197428984891721513992052180786807527853",
"264526906478938701651398086227268168692",
"216401746300142410688813123321863584571",
"282064698472194236172806047935421910606",
"34744921831968617417193138354670835620",
"51920597178901014852960120669106654863",
"215450329749334698014160459907530877482",
"151280171241099641622308516746266867148",
"338584426288642914570281317685848078712",
"183873076575713051339049687071437239076",
"321082351227284287516120819335453141877",
"123044294220832488046121579058855599424",
"230688924434924034930919020769487404509",
"336103659773744278403960484715365136369",
"192643690235113611209460623533322311317",
"47933999036525837301130722504256951132",
"187556122208562118193600153819114314484",
"293060922969081909780546316556126170809",
"119100974522844016135542306295405536059",
"35401329348453973885771883378488916909",
"194141643607800812762132096265916319676",
"37035434969152836833724884917697153006",
"184282354213952405457896532887585832690",
"134199247063194300088471195109181906576"
]
},
"target": {
"file": "fs/f2fs/super.c"
},
"signature_type": "Line",
"signature_version": "v1"
},
{
"deprecated": false,
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@b7d0a97b28083084ebdd8e5c6bccd12e6ec18faa",
"id": "CVE-2024-53221-3162bc8a",
"digest": {
"function_hash": "106807216853565903986030263139043404500",
"length": 320.0
},
"target": {
"function": "exit_f2fs_fs",
"file": "fs/f2fs/super.c"
},
"signature_type": "Function",
"signature_version": "v1"
},
{
"deprecated": false,
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@b7d0a97b28083084ebdd8e5c6bccd12e6ec18faa",
"id": "CVE-2024-53221-3291bdf4",
"digest": {
"threshold": 0.9,
"line_hashes": [
"313524496021189044735498858041761229954",
"264526906478938701651398086227268168692",
"216401746300142410688813123321863584571",
"282064698472194236172806047935421910606",
"34744921831968617417193138354670835620",
"51920597178901014852960120669106654863",
"215450329749334698014160459907530877482",
"151280171241099641622308516746266867148",
"338584426288642914570281317685848078712",
"183873076575713051339049687071437239076",
"321082351227284287516120819335453141877",
"123044294220832488046121579058855599424",
"230688924434924034930919020769487404509",
"241766807673865665529857638905251542221",
"19080675173629417191328329984154326855",
"71442267890431660938869253511802653902",
"187556122208562118193600153819114314484",
"293060922969081909780546316556126170809",
"119100974522844016135542306295405536059",
"35401329348453973885771883378488916909",
"194141643607800812762132096265916319676",
"203571056647802760533117450706358603501",
"28531125965046639473262428177987825926",
"220958213151428875360479943611172785316"
]
},
"target": {
"file": "fs/f2fs/super.c"
},
"signature_type": "Line",
"signature_version": "v1"
},
{
"deprecated": false,
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@9e11b1d5fda972f6be60ab732976a7c8e064cd56",
"id": "CVE-2024-53221-5146ae5a",
"digest": {
"function_hash": "106807216853565903986030263139043404500",
"length": 320.0
},
"target": {
"function": "exit_f2fs_fs",
"file": "fs/f2fs/super.c"
},
"signature_type": "Function",
"signature_version": "v1"
},
{
"deprecated": false,
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@32f5e291b7677495f98246eec573767430321c08",
"id": "CVE-2024-53221-6af2e5a1",
"digest": {
"function_hash": "96640629657081291822458152596836511687",
"length": 1684.0
},
"target": {
"function": "init_f2fs_fs",
"file": "fs/f2fs/super.c"
},
"signature_type": "Function",
"signature_version": "v1"
},
{
"deprecated": false,
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@32f5e291b7677495f98246eec573767430321c08",
"id": "CVE-2024-53221-78af0911",
"digest": {
"threshold": 0.9,
"line_hashes": [
"313524496021189044735498858041761229954",
"264526906478938701651398086227268168692",
"216401746300142410688813123321863584571",
"282064698472194236172806047935421910606",
"34744921831968617417193138354670835620",
"51920597178901014852960120669106654863",
"215450329749334698014160459907530877482",
"151280171241099641622308516746266867148",
"338584426288642914570281317685848078712",
"183873076575713051339049687071437239076",
"321082351227284287516120819335453141877",
"123044294220832488046121579058855599424",
"230688924434924034930919020769487404509",
"241766807673865665529857638905251542221",
"19080675173629417191328329984154326855",
"71442267890431660938869253511802653902",
"187556122208562118193600153819114314484",
"293060922969081909780546316556126170809",
"119100974522844016135542306295405536059",
"35401329348453973885771883378488916909",
"194141643607800812762132096265916319676",
"203571056647802760533117450706358603501",
"28531125965046639473262428177987825926",
"220958213151428875360479943611172785316"
]
},
"target": {
"file": "fs/f2fs/super.c"
},
"signature_type": "Line",
"signature_version": "v1"
},
{
"deprecated": false,
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@9e11b1d5fda972f6be60ab732976a7c8e064cd56",
"id": "CVE-2024-53221-9843a63d",
"digest": {
"function_hash": "96640629657081291822458152596836511687",
"length": 1684.0
},
"target": {
"function": "init_f2fs_fs",
"file": "fs/f2fs/super.c"
},
"signature_type": "Function",
"signature_version": "v1"
},
{
"deprecated": false,
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@8dddc12d03248755d9f709bc1eb9e3ea2bf1b322",
"id": "CVE-2024-53221-c522f5fb",
"digest": {
"function_hash": "316224215458274137880148339061972950535",
"length": 341.0
},
"target": {
"function": "exit_f2fs_fs",
"file": "fs/f2fs/super.c"
},
"signature_type": "Function",
"signature_version": "v1"
},
{
"deprecated": false,
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@9e11b1d5fda972f6be60ab732976a7c8e064cd56",
"id": "CVE-2024-53221-cf9724d0",
"digest": {
"threshold": 0.9,
"line_hashes": [
"313524496021189044735498858041761229954",
"264526906478938701651398086227268168692",
"216401746300142410688813123321863584571",
"282064698472194236172806047935421910606",
"34744921831968617417193138354670835620",
"51920597178901014852960120669106654863",
"215450329749334698014160459907530877482",
"151280171241099641622308516746266867148",
"338584426288642914570281317685848078712",
"183873076575713051339049687071437239076",
"321082351227284287516120819335453141877",
"123044294220832488046121579058855599424",
"230688924434924034930919020769487404509",
"241766807673865665529857638905251542221",
"19080675173629417191328329984154326855",
"71442267890431660938869253511802653902",
"187556122208562118193600153819114314484",
"293060922969081909780546316556126170809",
"119100974522844016135542306295405536059",
"35401329348453973885771883378488916909",
"194141643607800812762132096265916319676",
"203571056647802760533117450706358603501",
"28531125965046639473262428177987825926",
"220958213151428875360479943611172785316"
]
},
"target": {
"file": "fs/f2fs/super.c"
},
"signature_type": "Line",
"signature_version": "v1"
},
{
"deprecated": false,
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@8dddc12d03248755d9f709bc1eb9e3ea2bf1b322",
"id": "CVE-2024-53221-f51f08df",
"digest": {
"function_hash": "157956582130520704157938219413275170359",
"length": 1888.0
},
"target": {
"function": "init_f2fs_fs",
"file": "fs/f2fs/super.c"
},
"signature_type": "Function",
"signature_version": "v1"
},
{
"deprecated": false,
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@b7d0a97b28083084ebdd8e5c6bccd12e6ec18faa",
"id": "CVE-2024-53221-f8bb406f",
"digest": {
"function_hash": "96640629657081291822458152596836511687",
"length": 1684.0
},
"target": {
"function": "init_f2fs_fs",
"file": "fs/f2fs/super.c"
},
"signature_type": "Function",
"signature_version": "v1"
}
]