]> git.ipfire.org Git - thirdparty/util-linux.git/commitdiff
libblkid: bitlocker: fix unaligned access
authorThomas Weißschuh <thomas@t-8ch.de>
Mon, 14 Nov 2022 03:18:57 +0000 (04:18 +0100)
committerThomas Weißschuh <thomas@t-8ch.de>
Mon, 14 Nov 2022 03:18:57 +0000 (04:18 +0100)
Value of 64 has been chose arbitrarily

libblkid/src/superblocks/bitlocker.c

index 111edf39bc64ac63feb28443b9a131e812fc91f2..a9a7bfb8f52f481da3326607377ce4c37be95d28 100644 (file)
@@ -113,7 +113,7 @@ static int get_bitlocker_headers(blkid_probe pr,
                goto nothing;
        }
 
-       if (!off)
+       if (!off || off % 64)
                goto nothing;
        if (buf_hdr)
                *buf_hdr = buf;