Re: [PATCH 2/9] luks: Fix out-of-bounds copy of UUID

2020-08-26 Thread Patrick Steinhardt
On Sun, Aug 23, 2020 at 11:34:51PM +0200, Denis 'GNUtoo' Carikli wrote: > On Sun, 23 Aug 2020 12:59:57 +0200 > Patrick Steinhardt wrote: > > > When configuring a LUKS disk, we copy over the UUID from the LUKS > > header into the new `grub_cryptodisk_t` structure via `grub_memcpy > > ()`. As size

Re: [PATCH 2/9] luks: Fix out-of-bounds copy of UUID

2020-08-23 Thread Denis 'GNUtoo' Carikli
On Sun, 23 Aug 2020 12:59:57 +0200 Patrick Steinhardt wrote: > When configuring a LUKS disk, we copy over the UUID from the LUKS > header into the new `grub_cryptodisk_t` structure via `grub_memcpy > ()`. As size we mistakenly use the size of the `grub_cryptodisk_t` > UUID field, which is

[PATCH 2/9] luks: Fix out-of-bounds copy of UUID

2020-08-23 Thread Patrick Steinhardt
When configuring a LUKS disk, we copy over the UUID from the LUKS header into the new `grub_cryptodisk_t` structure via `grub_memcpy ()`. As size we mistakenly use the size of the `grub_cryptodisk_t` UUID field, which is guaranteed to be strictly bigger than the LUKS UUID field we're copying. As a