mirror of
https://github.com/dgibson/dtc.git
synced 2026-05-12 19:53:02 -04:00
libfdt: Check that there is only one root node
At present it is possible to have two root nodes and even access nodes in the 'second' root. Such trees should not be considered valid. This was discovered as part of a security investigation into U-Boot verified boot. Add a check for this to fdt_check_full(). Signed-off-by: Simon Glass <sjg@chromium.org> Reported-by: Arie Haenel <arie.haenel@intel.com> Reported-by: Julien Lenoir <julien.lenoir@intel.com> Message-Id: <20210323000926.3210733-1-sjg@chromium.org> Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
This commit is contained in:
parent
34d708249a
commit
4ca61f84dc
6 changed files with 32 additions and 2 deletions
|
|
@ -32,7 +32,9 @@ LIB_TESTS_L = get_mem_rsv \
|
|||
fs_tree1
|
||||
LIB_TESTS = $(LIB_TESTS_L:%=$(TESTS_PREFIX)%)
|
||||
|
||||
LIBTREE_TESTS_L = truncated_property truncated_string truncated_memrsv
|
||||
LIBTREE_TESTS_L = truncated_property truncated_string truncated_memrsv \
|
||||
two_roots
|
||||
|
||||
LIBTREE_TESTS = $(LIBTREE_TESTS_L:%=$(TESTS_PREFIX)%)
|
||||
|
||||
DL_LIB_TESTS_L = asm_tree_dump value-labels
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue