[PATCH 2/4] dmi: dmicheck: check reserved bits of offset 0x5 in type 13
Alex Hung
alex.hung at canonical.com
Fri May 12 02:06:20 UTC 2017
Bits[1:7] of Flags (offset 0x5) should be reserved.
Signed-off-by: Alex Hung <alex.hung at canonical.com>
---
src/dmi/dmicheck/dmicheck.c | 3 +++
1 file changed, 3 insertions(+)
diff --git a/src/dmi/dmicheck/dmicheck.c b/src/dmi/dmicheck/dmicheck.c
index 5a09ea4..3234153 100644
--- a/src/dmi/dmicheck/dmicheck.c
+++ b/src/dmi/dmicheck/dmicheck.c
@@ -1364,6 +1364,9 @@ static void dmicheck_entry(fwts_framework *fw,
case 13: /* 7.14 */
table = "BIOS Language Information (Type 13)";
+ if (hdr->length < 0x6)
+ break;
+ dmi_reserved_bits_check(fw, table, addr, "Flags", hdr, sizeof(uint8_t), 0x5, 1, 7);
if (hdr->length < 0x16)
break;
for (i = 1; i <= hdr->data[4]; i++) {
--
2.7.4
More information about the fwts-devel
mailing list