grub2/0001-misc-fix-invalid-character-recongition-in-strto-l.patch
Michael Chang 069a417c4f Accepting request 416645 from home:michael-chang:branches:Base:System
- grub.default: Empty GRUB_CMDLINE_LINUX_DEFAULT, the value will be fully
  taken from YaST settings. (bsc#989803)

- Add patches from Roberto Sassu <rsassu@suse.de>
- Fix grub2-10_linux-avoid-multi-device-root-kernel-argument.patch,
  device path is not tested if GRUB_DISABLE_LINUX_UUID="true"
  - added grub2-fix-multi-device-root-kernel-argument.patch
  (bsc#960776)
- grub2-zipl-setup: avoid multi-device root= kernel argument
  * added grub2-zipl-setup-fix-btrfs-multipledev.patch
  (bsc#960776)
- Add SUSE_REMOVE_LINUX_ROOT_PARAM configuration option
  to /etc/default/grub, to remove root= and rootflags= from the
  kernel command line in /boot/grub2/grub.cfg and /boot/zipl/config
  - added grub2-suse-remove-linux-root-param.patch
  (bsc#962585)

- Support HTTP Boot IPv4 and IPv6 (fate#320129)
  * 0001-misc-fix-invalid-character-recongition-in-strto-l.patch
  * 0002-net-read-bracketed-ipv6-addrs-and-port-numbers.patch
  * 0003-bootp-New-net_bootp6-command.patch
  * 0004-efinet-UEFI-IPv6-PXE-support.patch
  * 0005-grub.texi-Add-net_bootp6-doument.patch
  * 0006-bootp-Add-processing-DHCPACK-packet-from-HTTP-Boot.patch
  * 0007-efinet-Setting-network-from-UEFI-device-path.patch
  * 0008-efinet-Setting-DNS-server-from-UEFI-protocol.patch
- Fix heap corruption after dns lookup
  * 0001-dns-fix-buffer-overflow-for-data-addresses-in-recv_h.patch

OBS-URL: https://build.opensuse.org/request/show/416645
OBS-URL: https://build.opensuse.org/package/show/Base:System/grub2?expand=0&rev=224
2016-08-05 07:32:20 +00:00

38 lines
1.2 KiB
Diff

From 0155e49166494624e9fb6ef113ed2c16d4accbb3 Mon Sep 17 00:00:00 2001
From: Michael Chang <mchang@suse.com>
Date: Fri, 29 Jul 2016 17:41:27 +0800
Subject: [PATCH 1/8] misc: fix invalid character recongition in strto*l
From: Aaron Miller <aaronmiller@fb.com>
Would previously allow digits larger than the base and didn't check that
subtracting the difference from 0-9 to lowercase letters for characters
larger than 9 didn't result in a value lower than 9, which allowed the
parses: ` = 9, _ = 8, ^ = 7, ] = 6, \ = 5, and [ = 4
---
grub-core/kern/misc.c | 6 +++++-
1 file changed, 5 insertions(+), 1 deletion(-)
diff --git a/grub-core/kern/misc.c b/grub-core/kern/misc.c
index d1a54df..3a14d67 100644
--- a/grub-core/kern/misc.c
+++ b/grub-core/kern/misc.c
@@ -394,9 +394,13 @@ grub_strtoull (const char *str, char **end, int base)
if (digit > 9)
{
digit += '0' - 'a' + 10;
- if (digit >= (unsigned long) base)
+ /* digit <= 9 check is needed to keep chars larger than
+ '9' but less than 'a' from being read as numbers */
+ if (digit >= (unsigned long) base || digit <= 9)
break;
}
+ if (digit >= (unsigned long) base)
+ break;
found = 1;
--
2.6.6