summaryrefslogtreecommitdiff
path: root/NetworkPkg/ArpDxe
diff options
context:
space:
mode:
authorKrzysztof Koch <krzysztof.koch@arm.com>2020-02-19 18:23:38 +0800
committermergify[bot] <37929162+mergify[bot]@users.noreply.github.com>2020-02-20 09:27:00 +0000
commitb85048261aa5dc0b8fd98ddc4431d8c2a6389b25 (patch)
tree8c5c1528ce334e0553000821b76af8729f06b35b /NetworkPkg/ArpDxe
parent70228e101e67445dadec2756c61785289b060402 (diff)
downloadedk2-b85048261aa5dc0b8fd98ddc4431d8c2a6389b25.zip
edk2-b85048261aa5dc0b8fd98ddc4431d8c2a6389b25.tar.gz
edk2-b85048261aa5dc0b8fd98ddc4431d8c2a6389b25.tar.bz2
ShellPkg: acpiview: Prevent infinite loop if structure length is 0
REF: https://bugzilla.tianocore.org/show_bug.cgi?id=2534 Extend validation of ACPI structure lengths which are read from the ACPI table being parsed. Additionally check if the structure 'Length' field value is positive. If not, stop parsing the faulting table. Some ACPI tables define internal structures of variable size. The 'Length' field inside the substructure is used to update a pointer used for table traversal. If the byte-length of the structure is equal to 0, acpiview can enter an infinite loop. This condition can occur if, for example, the zero-allocated ACPI table buffer is not fully populated. This is typically a bug on the ACPI table writer side. In short, this method helps acpiview recover gracefully from a zero-valued ACPI structure length. Signed-off-by: Krzysztof Koch <krzysztof.koch@arm.com> Reviewed-by: Sami Mujawar <sami.mujawar@arm.com> Reviewed-by: Zhichao Gao <zhichao.gao@intel.com>
Diffstat (limited to 'NetworkPkg/ArpDxe')
0 files changed, 0 insertions, 0 deletions