{"id":"MGASA-2021-0315","summary":"Updated grub2 packages fix security vulnerabilities","details":"All CVEs below are against the SecureBoot functionality in GRUB2.\nWe do not ship this as part of Mageia. Therefore, we ship an updated grub2\npackage to 2.06 for Mageia 8 fixing upstream bugfixes.\n\nA flaw was found in grub2, prior to version 2.06. An attacker may use the\nGRUB 2 flaw to hijack and tamper the GRUB verification process. This flaw also\nallows the bypass of Secure Boot protections. In order to load an untrusted or\nmodified kernel, an attacker would first need to establish access to the system\nsuch as gaining physical access, obtain the ability to alter a\npxe-boot network, or have remote access to a networked system with root access.\nWith this access, an attacker could then craft a string to cause a buffer\noverflow by injecting a malicious payload that leads to arbitrary code execution\nwithin GRUB. The highest threat from this vulnerability is to data\nconfidentiality and integrity as well as system availability (CVE-2020-10713).\n\nIn grub2 versions before 2.06 the grub memory allocator doesn't check for\npossible arithmetic overflows on the requested allocation size. This leads the\nfunction to return invalid memory allocations which can be further used to cause\npossible integrity, confidentiality and availability impacts during the boot\nprocess (CVE-2020-14308).\n\nThere's an issue with grub2 in all versions before 2.06 when handling squashfs\nfilesystems containing a symbolic link with name length of UINT32 bytes in size.\nThe name size leads to an arithmetic overflow leading to a zero-size allocation\nfurther causing a heap-based buffer overflow with attacker controlled data\n(CVE-2020-14309).\n\nThere is an issue on grub2 before version 2.06 at function\nread_section_as_string(). It expects a font name to be at max UINT32_MAX - 1\nlength in bytes but it doesn't verify it before proceed with buffer allocation\nto read the value from the font value. An attacker may leverage that by\ncrafting a malicious font file which has a name with UINT32_MAX, leading to\nread_section_as_string() to an arithmetic overflow, zero-sized allocation and\nfurther heap-based buffer overflow (CVE-2020-14310).\n\nThere is an issue with grub2 before version 2.06 while handling symlink on ext\nfilesystems. A filesystem containing a symbolic link with an inode size of\nUINT32_MAX causes an arithmetic overflow leading to a zero-sized memory\nallocation with subsequent heap-based buffer overflow (CVE-2020-14311).\n\nA flaw was found in grub2 in versions prior to 2.06, where it incorrectly\nenables the usage of the ACPI command when Secure Boot is enabled. This flaw \nallows an attacker with privileged access to craft a Secondary System Description\nTable (SSDT) containing code to overwrite the Linux kernel lockdown variable\ncontent directly into memory. The table is further loaded and executed by the\nkernel, defeating its Secure Boot lockdown and allowing the attacker to load\nunsigned code. The highest threat from this vulnerability is to data\nconfidentiality and integrity, as well as system availability (CVE-2020-14372).\n\nGRUB2 fails to validate kernel signature when booted directly without shim,\nallowing secure boot to be bypassed. This only affects systems where the kernel\nsigning certificate has been imported directly into the secure boot database\nand the GRUB image is booted directly without the use of shim. This issue\naffects GRUB2 version 2.04 and prior versions (CVE-2020-15705).\n\nGRUB2 contains a race condition in grub_script_function_create() leading to a\nuse-after-free vulnerability which can be triggered by redefining a function\nwhilst the same function is already executing, leading to arbitrary code\nexecution and secure boot restriction bypass. This issue affects GRUB2 version\n2.04 and prior versions (CVE-2020-15706).\n\nInteger overflows were discovered in the functions grub_cmd_initrd and\ngrub_initrd_init in the efilinux component of GRUB2, as shipped in Debian,\nRed Hat, and Ubuntu (the functionality is not included in GRUB2 upstream), \nleading to a heap-based buffer overflow. These could be triggered by an extremely\nlarge number of arguments to the initrd command on 32-bit architectures, or a\ncrafted filesystem with very large files on any architecture. An attacker could\nuse this to execute arbitrary code and bypass UEFI Secure Boot restrictions.\nThis issue affects GRUB2 version 2.04 and prior versions (CVE-2020-15707).\n\nA flaw was found in grub2 in versions prior to 2.06. The option parser allows an\nattacker to write past the end of a heap-allocated buffer by calling certain\ncommands with a large number of specific short forms of options. The highest\nthreat from this vulnerability is to data confidentiality and integrity as well\nas system availability (CVE-2021-20225).\n\nA flaw was found in grub2 in versions prior to 2.06. Setparam_prefix() in the\nmenu rendering code performs a length calculation on the assumption that\nexpressing a quoted single quote will require 3 characters, while it actuall\nrequires 4 characters which allows an attacker to corrupt memory by one byte for\neach quote in the input. The highest threat from this vulnerability is to data\nconfidentiality and integrity as well as system availability (CVE-2021-20233).\n\nA flaw was found in grub2 in versions prior to 2.06. The rmmod implementation\nallows the unloading of a module used as a dependency without checking if any\nother dependent module is still loaded leading to a use-after-free scenario.\nThis could allow arbitrary code to be executed or a bypass of SecureBoot\nprotections. The highest threat from this vulnerability is to data\nconfidentiality and integrity as well as system availability (CVE-2020-25632).\n\nA flaw was found in grub2 in versions prior to 2.06. During USB device\ninitialization, descriptors are read with very little bounds checking and assumes\nthe USB device is providing sane values. If properly exploited, an attacker\ncould trigger memory corruption leading to arbitrary code execution allowing a\nbypass of the Secure Boot mechanism. The highest threat from this vulnerability\nis to data confidentiality and integrity as well as system availability\n(CVE-2020-25647).\n\nA flaw was found in grub2 in versions prior to 2.06. Variable names present are\nexpanded in the supplied command line into their corresponding variable contents\nusing a 1kB stack buffer for temporary storage, without sufficient bounds\nchecking. If the function is called with a command line that references a\nvariable with a sufficiently large payload, it is possible to overflow the stack\nbuffer, corrupt the stack frame and control execution which could also circumvent\nSecure Boot protections. The highest threat from this vulnerability is to data\nconfidentiality and integrity as well as system availability (CVE-2020-27749).\n\nA flaw was found in grub2 in versions prior to 2.06. The cutmem command does not\nhonor secure boot locking allowing an privileged attacker to remove address\nranges from memory creating an opportunity to circumvent SecureBoot protections\nafter proper triage about grub's memory layout. The highest threat from this\nvulnerability is to data confidentiality and integrity as well as system\navailability (CVE-2020-27779).\n","modified":"2026-02-02T15:17:51.412270Z","published":"2021-07-08T22:43:19Z","related":["CVE-2020-10713","CVE-2020-14308","CVE-2020-14309","CVE-2020-14310","CVE-2020-14311","CVE-2020-14372","CVE-2020-15705","CVE-2020-15706","CVE-2020-15707","CVE-2020-25632","CVE-2020-25647","CVE-2020-27749","CVE-2020-27779","CVE-2021-20225","CVE-2021-20233"],"references":[{"type":"ADVISORY","url":"https://advisories.mageia.org/MGASA-2021-0315.html"},{"type":"REPORT","url":"https://bugs.mageia.org/show_bug.cgi?id=27018"},{"type":"REPORT","url":"https://lists.gnu.org/archive/html/grub-devel/2021-03/msg00007.html"},{"type":"REPORT","url":"https://lists.gnu.org/archive/html/grub-devel/2021-06/msg00022.html"},{"type":"REPORT","url":"https://lists.fedoraproject.org/archives/list/package-announce@lists.fedoraproject.org/thread/SPZHLZ3UEVV7HQ6ETAHB7NRBRTPLHCNF/"},{"type":"REPORT","url":"https://lists.opensuse.org/archives/list/security-announce@lists.opensuse.org/thread/XXPYL42MSKRB4D7LRFMW7PBGGLKSJKPS/"},{"type":"REPORT","url":"https://ubuntu.com/security/notices/USN-4992-1"}],"affected":[{"package":{"name":"grub2","ecosystem":"Mageia:8","purl":"pkg:rpm/mageia/grub2?arch=source&distro=mageia-8"},"ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"2.06-1.1.mga8"}]}],"ecosystem_specific":{"section":"core"},"database_specific":{"source":"https://advisories.mageia.org/MGASA-2021-0315.json"}}],"schema_version":"1.7.3","credits":[{"name":"Mageia","contact":["https://wiki.mageia.org/en/Packages_Security_Team"],"type":"COORDINATOR"}]}