[<prev] [next>] [day] [month] [year] [list]
Message-ID: <CAFSR4ctCsEriCnsJ3wWi_gGNwER5Adohn7p+=zvWqVqz2R0kYw@mail.gmail.com>
Date: Sun, 3 May 2020 15:33:21 +0800
From: Dongyang Zhan <zdyzztq@...il.com>
To: linux-kernel@...r.kernel.org
Subject: Possible null pointer dereference in smp_init_package_map()
Hi,
I am a security researcher, my name is Dongyang Zhan. I found a potential bug.
I hope you can help me to confirm it.
Thank you.
In Linux 4.10.17, smp_init_package_map() in /arch/x86/kernel/smpboot.c
does not handle the failure of memory allocation, which may cause a
null pointer dereference bug.
Source code link:
https://elixir.bootlin.com/linux/v4.10.17/source/arch/x86/kernel/smpboot.c#L326
Source code and comments:
physical_to_logical_pkg = kmalloc(size, GFP_KERNEL);
memset(physical_to_logical_pkg, 0xff, size); // does not check if kmalloc fails
Powered by blists - more mailing lists