mirror of
https://github.com/Fishwaldo/u-boot.git
synced 2025-06-06 14:51:35 +00:00
efi_loader: avoid out of bound access in efi_get_variable()
In efi_get_variable() a string is longer than the allocated space which results in overwriting the linked list of malloc(). The prefixes used for variables are 41 characters long, e.g. efi_67029eb5-0af2-f6b1-da53-fcb566dd1ce6_ Change PREFIX_LEN to 41. Fixes: faff21556748 ("efi_loader: remove limit on variable length") Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de> Signed-off-by: Alexander Graf <agraf@suse.de>
This commit is contained in:
parent
60ce592cd0
commit
506dc52d5d
1 changed files with 1 additions and 1 deletions
|
@ -44,7 +44,7 @@
|
||||||
* converted to utf16?
|
* converted to utf16?
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#define PREFIX_LEN (strlen("efi_xxxxxxxx-xxxx-xxxx-xxxxxxxxxxxxxxxx_"))
|
#define PREFIX_LEN (strlen("efi_xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx_"))
|
||||||
|
|
||||||
static int hex(int ch)
|
static int hex(int ch)
|
||||||
{
|
{
|
||||||
|
|
Loading…
Add table
Reference in a new issue