* partmap/pc.c (pc_partition_map_iterate): Check that boot flags are
valid.
+2009-07-31 Vladimir Serbinenko <phcoder@gmail.com>
+
+ * partmap/pc.c (pc_partition_map_iterate): Check that boot flags are
+ valid.
+
2009-07-31 Bean <bean123ch@gmail.com>
* fs/xfs.c (grub_xfs_sblock): Change unused5 field to log2_sect and
if (mbr.signature != grub_cpu_to_le16 (GRUB_PC_PARTITION_SIGNATURE))
return grub_error (GRUB_ERR_BAD_PART_TABLE, "no signature");
+ for (i = 0; i < 4; i++)
+ if (mbr.entries[i].flag & 0x7f)
+ return grub_error (GRUB_ERR_BAD_PART_TABLE, "bad boot flag");
+
/* Analyze DOS partitions. */
for (p.index = 0; p.index < 4; p.index++)
{