From dd487d0d55c5c8828972cbff871252ba98f8d65c Mon Sep 17 00:00:00 2001 From: Simon Glass Date: Fri, 6 Mar 2026 11:12:36 -0700 Subject: binman: test: Move security test files to test/security/ Move about 20 test files for signing, encryption, hash, pre-load, x509, and Xilinx bootgen entries into a security/ subdirectory. Drop the numeric prefixes and update all references. Signed-off-by: Simon Glass --- tools/binman/ftest.py | 52 ++++++++--------- tools/binman/test/090_hash.dts | 12 ---- tools/binman/test/091_hash_no_algo.dts | 11 ---- tools/binman/test/092_hash_bad_algo.dts | 12 ---- tools/binman/test/099_hash_section.dts | 18 ------ .../test/165_section_ignore_hash_signature.dts | 40 ------------- tools/binman/test/230_pre_load.dts | 22 -------- tools/binman/test/231_pre_load_pkcs.dts | 23 -------- tools/binman/test/232_pre_load_pss.dts | 23 -------- tools/binman/test/233_pre_load_invalid_padding.dts | 23 -------- tools/binman/test/234_pre_load_invalid_sha.dts | 23 -------- tools/binman/test/235_pre_load_invalid_algo.dts | 23 -------- tools/binman/test/236_pre_load_invalid_key.dts | 23 -------- tools/binman/test/279_x509_cert.dts | 19 ------- tools/binman/test/281_sign_non_fit.dts | 65 ---------------------- tools/binman/test/301_encrypted_no_algo.dts | 15 ----- .../binman/test/302_encrypted_invalid_iv_file.dts | 18 ------ tools/binman/test/303_encrypted_missing_key.dts | 23 -------- tools/binman/test/304_encrypted_key_source.dts | 24 -------- tools/binman/test/305_encrypted_key_file.dts | 24 -------- tools/binman/test/306_spl_pubkey_dtb.dts | 16 ------ tools/binman/test/307_xilinx_bootgen_sign.dts | 22 -------- tools/binman/test/308_xilinx_bootgen_sign_enc.dts | 24 -------- .../test/348_key_name_hint_dir_spl_pubkey_dtb.dts | 16 ------ .../test/security/encrypted_invalid_iv_file.dts | 18 ++++++ tools/binman/test/security/encrypted_key_file.dts | 24 ++++++++ .../binman/test/security/encrypted_key_source.dts | 24 ++++++++ .../binman/test/security/encrypted_missing_key.dts | 23 ++++++++ tools/binman/test/security/encrypted_no_algo.dts | 15 +++++ tools/binman/test/security/hash.dts | 12 ++++ tools/binman/test/security/hash_bad_algo.dts | 12 ++++ tools/binman/test/security/hash_no_algo.dts | 11 ++++ tools/binman/test/security/hash_section.dts | 18 ++++++ .../security/key_name_hint_dir_spl_pubkey_dtb.dts | 16 ++++++ tools/binman/test/security/pre_load.dts | 22 ++++++++ .../binman/test/security/pre_load_invalid_algo.dts | 23 ++++++++ .../binman/test/security/pre_load_invalid_key.dts | 23 ++++++++ .../test/security/pre_load_invalid_padding.dts | 23 ++++++++ .../binman/test/security/pre_load_invalid_sha.dts | 23 ++++++++ tools/binman/test/security/pre_load_pkcs.dts | 23 ++++++++ tools/binman/test/security/pre_load_pss.dts | 23 ++++++++ .../security/section_ignore_hash_signature.dts | 40 +++++++++++++ tools/binman/test/security/sign_non_fit.dts | 65 ++++++++++++++++++++++ tools/binman/test/security/spl_pubkey_dtb.dts | 16 ++++++ tools/binman/test/security/x509_cert.dts | 19 +++++++ tools/binman/test/security/xilinx_bootgen_sign.dts | 22 ++++++++ .../test/security/xilinx_bootgen_sign_enc.dts | 24 ++++++++ 47 files changed, 545 insertions(+), 545 deletions(-) delete mode 100644 tools/binman/test/090_hash.dts delete mode 100644 tools/binman/test/091_hash_no_algo.dts delete mode 100644 tools/binman/test/092_hash_bad_algo.dts delete mode 100644 tools/binman/test/099_hash_section.dts delete mode 100644 tools/binman/test/165_section_ignore_hash_signature.dts delete mode 100644 tools/binman/test/230_pre_load.dts delete mode 100644 tools/binman/test/231_pre_load_pkcs.dts delete mode 100644 tools/binman/test/232_pre_load_pss.dts delete mode 100644 tools/binman/test/233_pre_load_invalid_padding.dts delete mode 100644 tools/binman/test/234_pre_load_invalid_sha.dts delete mode 100644 tools/binman/test/235_pre_load_invalid_algo.dts delete mode 100644 tools/binman/test/236_pre_load_invalid_key.dts delete mode 100644 tools/binman/test/279_x509_cert.dts delete mode 100644 tools/binman/test/281_sign_non_fit.dts delete mode 100644 tools/binman/test/301_encrypted_no_algo.dts delete mode 100644 tools/binman/test/302_encrypted_invalid_iv_file.dts delete mode 100644 tools/binman/test/303_encrypted_missing_key.dts delete mode 100644 tools/binman/test/304_encrypted_key_source.dts delete mode 100644 tools/binman/test/305_encrypted_key_file.dts delete mode 100644 tools/binman/test/306_spl_pubkey_dtb.dts delete mode 100644 tools/binman/test/307_xilinx_bootgen_sign.dts delete mode 100644 tools/binman/test/308_xilinx_bootgen_sign_enc.dts delete mode 100644 tools/binman/test/348_key_name_hint_dir_spl_pubkey_dtb.dts create mode 100644 tools/binman/test/security/encrypted_invalid_iv_file.dts create mode 100644 tools/binman/test/security/encrypted_key_file.dts create mode 100644 tools/binman/test/security/encrypted_key_source.dts create mode 100644 tools/binman/test/security/encrypted_missing_key.dts create mode 100644 tools/binman/test/security/encrypted_no_algo.dts create mode 100644 tools/binman/test/security/hash.dts create mode 100644 tools/binman/test/security/hash_bad_algo.dts create mode 100644 tools/binman/test/security/hash_no_algo.dts create mode 100644 tools/binman/test/security/hash_section.dts create mode 100644 tools/binman/test/security/key_name_hint_dir_spl_pubkey_dtb.dts create mode 100644 tools/binman/test/security/pre_load.dts create mode 100644 tools/binman/test/security/pre_load_invalid_algo.dts create mode 100644 tools/binman/test/security/pre_load_invalid_key.dts create mode 100644 tools/binman/test/security/pre_load_invalid_padding.dts create mode 100644 tools/binman/test/security/pre_load_invalid_sha.dts create mode 100644 tools/binman/test/security/pre_load_pkcs.dts create mode 100644 tools/binman/test/security/pre_load_pss.dts create mode 100644 tools/binman/test/security/section_ignore_hash_signature.dts create mode 100644 tools/binman/test/security/sign_non_fit.dts create mode 100644 tools/binman/test/security/spl_pubkey_dtb.dts create mode 100644 tools/binman/test/security/x509_cert.dts create mode 100644 tools/binman/test/security/xilinx_bootgen_sign.dts create mode 100644 tools/binman/test/security/xilinx_bootgen_sign_enc.dts diff --git a/tools/binman/ftest.py b/tools/binman/ftest.py index 612a1bdb8cb..9ceb85f2b28 100644 --- a/tools/binman/ftest.py +++ b/tools/binman/ftest.py @@ -2261,7 +2261,7 @@ class TestFunctional(unittest.TestCase): def testHash(self): """Test hashing of the contents of an entry""" - _, _, _, out_dtb_fname = self._DoReadFileDtb('090_hash.dts', + _, _, _, out_dtb_fname = self._DoReadFileDtb('security/hash.dts', use_real_dtb=True, update_dtb=True) dtb = fdt.Fdt(out_dtb_fname) dtb.Scan() @@ -2272,19 +2272,19 @@ class TestFunctional(unittest.TestCase): def testHashNoAlgo(self): with self.assertRaises(ValueError) as e: - self._DoReadFileDtb('091_hash_no_algo.dts', update_dtb=True) + self._DoReadFileDtb('security/hash_no_algo.dts', update_dtb=True) self.assertIn("Node \'/binman/u-boot\': Missing \'algo\' property for " 'hash node', str(e.exception)) def testHashBadAlgo(self): with self.assertRaises(ValueError) as e: - self._DoReadFileDtb('092_hash_bad_algo.dts', update_dtb=True) + self._DoReadFileDtb('security/hash_bad_algo.dts', update_dtb=True) self.assertIn("Node '/binman/u-boot': Unknown hash algorithm 'invalid'", str(e.exception)) def testHashSection(self): """Test hashing of the contents of an entry""" - _, _, _, out_dtb_fname = self._DoReadFileDtb('099_hash_section.dts', + _, _, _, out_dtb_fname = self._DoReadFileDtb('security/hash_section.dts', use_real_dtb=True, update_dtb=True) dtb = fdt.Fdt(out_dtb_fname) dtb.Scan() @@ -4166,7 +4166,7 @@ class TestFunctional(unittest.TestCase): def testSectionIgnoreHashSignature(self): """Test that sections ignore hash, signature nodes for its data""" - data = self._DoReadFile('165_section_ignore_hash_signature.dts') + data = self._DoReadFile('security/section_ignore_hash_signature.dts') expected = (U_BOOT_DATA + U_BOOT_DATA) self.assertEqual(expected, data) @@ -5822,7 +5822,7 @@ fdt fdtmap Extract the devicetree blob from the fdtmap 'pre-load-key-path': os.path.join(self._binman_dir, 'test'), } data = self._DoReadFileDtb( - '230_pre_load.dts', entry_args=entry_args, + 'security/pre_load.dts', entry_args=entry_args, extra_indirs=[os.path.join(self._binman_dir, 'test')])[0] image_fname = tools.get_output_filename('image.bin') @@ -5836,7 +5836,7 @@ fdt fdtmap Extract the devicetree blob from the fdtmap def testPreLoadNoKey(self): """Test an image with a pre-load heade0r with missing key""" with self.assertRaises(FileNotFoundError) as exc: - self._DoReadFile('230_pre_load.dts') + self._DoReadFile('security/pre_load.dts') self.assertIn("No such file or directory: 'dev.key'", str(exc.exception)) @@ -5845,7 +5845,7 @@ fdt fdtmap Extract the devicetree blob from the fdtmap entry_args = { 'pre-load-key-path': os.path.join(self._binman_dir, 'test'), } - data = self._DoReadFileDtb('231_pre_load_pkcs.dts', + data = self._DoReadFileDtb('security/pre_load_pkcs.dts', entry_args=entry_args)[0] self.assertEqual(PRE_LOAD_MAGIC, data[:len(PRE_LOAD_MAGIC)]) self.assertEqual(PRE_LOAD_VERSION, data[4:4 + len(PRE_LOAD_VERSION)]) @@ -5856,7 +5856,7 @@ fdt fdtmap Extract the devicetree blob from the fdtmap entry_args = { 'pre-load-key-path': os.path.join(self._binman_dir, 'test'), } - data = self._DoReadFileDtb('232_pre_load_pss.dts', + data = self._DoReadFileDtb('security/pre_load_pss.dts', entry_args=entry_args)[0] self.assertEqual(PRE_LOAD_MAGIC, data[:len(PRE_LOAD_MAGIC)]) self.assertEqual(PRE_LOAD_VERSION, data[4:4 + len(PRE_LOAD_VERSION)]) @@ -5868,7 +5868,7 @@ fdt fdtmap Extract the devicetree blob from the fdtmap 'pre-load-key-path': os.path.join(self._binman_dir, 'test'), } with self.assertRaises(ValueError) as e: - self._DoReadFileDtb('233_pre_load_invalid_padding.dts', + self._DoReadFileDtb('security/pre_load_invalid_padding.dts', entry_args=entry_args) def testPreLoadInvalidSha(self): @@ -5877,13 +5877,13 @@ fdt fdtmap Extract the devicetree blob from the fdtmap 'pre-load-key-path': os.path.join(self._binman_dir, 'test'), } with self.assertRaises(ValueError) as e: - self._DoReadFileDtb('234_pre_load_invalid_sha.dts', + self._DoReadFileDtb('security/pre_load_invalid_sha.dts', entry_args=entry_args) def testPreLoadInvalidAlgo(self): """Test an image with a pre-load header with an invalid algo""" with self.assertRaises(ValueError) as e: - data = self._DoReadFile('235_pre_load_invalid_algo.dts') + data = self._DoReadFile('security/pre_load_invalid_algo.dts') def testPreLoadInvalidKey(self): """Test an image with a pre-load header with an invalid key""" @@ -5891,7 +5891,7 @@ fdt fdtmap Extract the devicetree blob from the fdtmap 'pre-load-key-path': os.path.join(self._binman_dir, 'test'), } with self.assertRaises(ValueError) as e: - data = self._DoReadFileDtb('236_pre_load_invalid_key.dts', + data = self._DoReadFileDtb('security/pre_load_invalid_key.dts', entry_args=entry_args) def _CheckSafeUniqueNames(self, *images): @@ -6863,7 +6863,7 @@ fdt fdtmap Extract the devicetree blob from the fdtmap entry_args = { 'keyfile': keyfile, } - data = self._DoReadFileDtb('279_x509_cert.dts', + data = self._DoReadFileDtb('security/x509_cert.dts', entry_args=entry_args)[0] cert = data[:-4] self.assertEqual(U_BOOT_DATA, data[-4:]) @@ -6877,7 +6877,7 @@ fdt fdtmap Extract the devicetree blob from the fdtmap 'keyfile': 'keyfile', } with terminal.capture() as (_, stderr): - self._DoTestFile('279_x509_cert.dts', + self._DoTestFile('security/x509_cert.dts', force_missing_bintools='openssl', entry_args=entry_args) err = stderr.getvalue() @@ -6963,7 +6963,7 @@ fdt fdtmap Extract the devicetree blob from the fdtmap """Test a non-FIT entry cannot be signed""" is_signed = False fit, fname, private_key, _ = self._PrepareSignEnv( - '281_sign_non_fit.dts') + 'security/sign_non_fit.dts') # do sign with private key with self.assertRaises(ValueError) as e: @@ -7272,7 +7272,7 @@ fdt fdtmap Extract the devicetree blob from the fdtmap def testEncryptedNoAlgo(self): """Test encrypted node with missing required properties""" with self.assertRaises(ValueError) as e: - self._DoReadFileDtb('301_encrypted_no_algo.dts') + self._DoReadFileDtb('security/encrypted_no_algo.dts') self.assertIn( "Node '/binman/fit/images/u-boot/encrypted': 'encrypted' entry is missing properties: algo iv-filename", str(e.exception)) @@ -7280,21 +7280,21 @@ fdt fdtmap Extract the devicetree blob from the fdtmap def testEncryptedInvalidIvfile(self): """Test encrypted node with invalid iv file""" with self.assertRaises(ValueError) as e: - self._DoReadFileDtb('302_encrypted_invalid_iv_file.dts') + self._DoReadFileDtb('security/encrypted_invalid_iv_file.dts') self.assertIn("Filename 'invalid-iv-file' not found in input path", str(e.exception)) def testEncryptedMissingKey(self): """Test encrypted node with missing key properties""" with self.assertRaises(ValueError) as e: - self._DoReadFileDtb('303_encrypted_missing_key.dts') + self._DoReadFileDtb('security/encrypted_missing_key.dts') self.assertIn( "Node '/binman/fit/images/u-boot/encrypted': Provide either 'key-filename' or 'key-source'", str(e.exception)) def testEncryptedKeySource(self): """Test encrypted node with key-source property""" - data = self._DoReadFileDtb('304_encrypted_key_source.dts')[0] + data = self._DoReadFileDtb('security/encrypted_key_source.dts')[0] dtb = fdt.Fdt.FromData(data) dtb.Scan() @@ -7308,7 +7308,7 @@ fdt fdtmap Extract the devicetree blob from the fdtmap def testEncryptedKeyFile(self): """Test encrypted node with key-filename property""" - data = self._DoReadFileDtb('305_encrypted_key_file.dts')[0] + data = self._DoReadFileDtb('security/encrypted_key_file.dts')[0] dtb = fdt.Fdt.FromData(data) dtb.Scan() @@ -7324,7 +7324,7 @@ fdt fdtmap Extract the devicetree blob from the fdtmap def testKeyNameHintIsPathSplPubkeyDtb(self): """Test that binman errors out on key-name-hint being a path""" with self.assertRaises(ValueError) as e: - self._DoReadFile('348_key_name_hint_dir_spl_pubkey_dtb.dts') + self._DoReadFile('security/key_name_hint_dir_spl_pubkey_dtb.dts') self.assertIn( 'Node \'/binman/u-boot-spl-pubkey-dtb\': \'keys/key\' is a path not a filename', str(e.exception)) @@ -7333,7 +7333,7 @@ fdt fdtmap Extract the devicetree blob from the fdtmap """Test u_boot_spl_pubkey_dtb etype""" data = tools.read_file(self.TestFile("key.pem")) self._MakeInputFile("key.crt", data) - self._DoReadFileRealDtb('306_spl_pubkey_dtb.dts') + self._DoReadFileRealDtb('security/spl_pubkey_dtb.dts') image = control.images['image'] entries = image.GetEntries() dtb_entry = entries['u-boot-spl-pubkey-dtb'] @@ -7358,7 +7358,7 @@ fdt fdtmap Extract the devicetree blob from the fdtmap self._MakeInputFile("ssk.pem", data) self._SetupPmuFwlElf() self._SetupSplElf() - self._DoReadFileRealDtb('307_xilinx_bootgen_sign.dts') + self._DoReadFileRealDtb('security/xilinx_bootgen_sign.dts') image_fname = tools.get_output_filename('image.bin') # Read partition header table and check if authentication is enabled @@ -7387,7 +7387,7 @@ fdt fdtmap Extract the devicetree blob from the fdtmap self._MakeInputFile("ssk.pem", data) self._SetupPmuFwlElf() self._SetupSplElf() - self._DoReadFileRealDtb('308_xilinx_bootgen_sign_enc.dts') + self._DoReadFileRealDtb('security/xilinx_bootgen_sign_enc.dts') image_fname = tools.get_output_filename('image.bin') # Read boot header in order to verify encryption source and @@ -7420,7 +7420,7 @@ fdt fdtmap Extract the devicetree blob from the fdtmap self._SetupPmuFwlElf() self._SetupSplElf() with terminal.capture() as (_, stderr): - self._DoTestFile('307_xilinx_bootgen_sign.dts', + self._DoTestFile('security/xilinx_bootgen_sign.dts', force_missing_bintools='bootgen') err = stderr.getvalue() self.assertRegex(err, diff --git a/tools/binman/test/090_hash.dts b/tools/binman/test/090_hash.dts deleted file mode 100644 index 200304599dc..00000000000 --- a/tools/binman/test/090_hash.dts +++ /dev/null @@ -1,12 +0,0 @@ -// SPDX-License-Identifier: GPL-2.0+ -/dts-v1/; - -/ { - binman { - u-boot { - hash { - algo = "sha256"; - }; - }; - }; -}; diff --git a/tools/binman/test/091_hash_no_algo.dts b/tools/binman/test/091_hash_no_algo.dts deleted file mode 100644 index b64df205117..00000000000 --- a/tools/binman/test/091_hash_no_algo.dts +++ /dev/null @@ -1,11 +0,0 @@ -// SPDX-License-Identifier: GPL-2.0+ -/dts-v1/; - -/ { - binman { - u-boot { - hash { - }; - }; - }; -}; diff --git a/tools/binman/test/092_hash_bad_algo.dts b/tools/binman/test/092_hash_bad_algo.dts deleted file mode 100644 index d2402000db6..00000000000 --- a/tools/binman/test/092_hash_bad_algo.dts +++ /dev/null @@ -1,12 +0,0 @@ -// SPDX-License-Identifier: GPL-2.0+ -/dts-v1/; - -/ { - binman { - u-boot { - hash { - algo = "invalid"; - }; - }; - }; -}; diff --git a/tools/binman/test/099_hash_section.dts b/tools/binman/test/099_hash_section.dts deleted file mode 100644 index dcd8683d642..00000000000 --- a/tools/binman/test/099_hash_section.dts +++ /dev/null @@ -1,18 +0,0 @@ -// SPDX-License-Identifier: GPL-2.0+ -/dts-v1/; - -/ { - binman { - section { - u-boot { - }; - fill { - size = <0x10>; - fill-byte = [61]; - }; - hash { - algo = "sha256"; - }; - }; - }; -}; diff --git a/tools/binman/test/165_section_ignore_hash_signature.dts b/tools/binman/test/165_section_ignore_hash_signature.dts deleted file mode 100644 index 8adbe25512a..00000000000 --- a/tools/binman/test/165_section_ignore_hash_signature.dts +++ /dev/null @@ -1,40 +0,0 @@ -// SPDX-License-Identifier: GPL-2.0+ - -/dts-v1/; - -/ { - #address-cells = <1>; - #size-cells = <1>; - - binman { - section@0 { - u-boot { - }; - hash { - algo = "sha256"; - }; - signature { - algo = "sha256,rsa2048"; - key-name-hint = "dev"; - }; - }; - section@1 { - u-boot { - }; - hash-1 { - algo = "sha1"; - }; - hash-2 { - algo = "sha256"; - }; - signature-1 { - algo = "sha1,rsa2048"; - key-name-hint = "dev"; - }; - signature-2 { - algo = "sha256,rsa2048"; - key-name-hint = "dev"; - }; - }; - }; -}; diff --git a/tools/binman/test/230_pre_load.dts b/tools/binman/test/230_pre_load.dts deleted file mode 100644 index e6d9ef40c6c..00000000000 --- a/tools/binman/test/230_pre_load.dts +++ /dev/null @@ -1,22 +0,0 @@ -// SPDX-License-Identifier: GPL-2.0+ - -/dts-v1/; - -/ { - #address-cells = <1>; - #size-cells = <1>; - - binman { - pre-load { - content = <&image>; - algo-name = "sha256,rsa2048"; - key-name = "dev.key"; - header-size = <4096>; - version = <0x11223344>; - }; - - image: blob-ext { - filename = "refcode.bin"; - }; - }; -}; diff --git a/tools/binman/test/231_pre_load_pkcs.dts b/tools/binman/test/231_pre_load_pkcs.dts deleted file mode 100644 index 66268cdb212..00000000000 --- a/tools/binman/test/231_pre_load_pkcs.dts +++ /dev/null @@ -1,23 +0,0 @@ -// SPDX-License-Identifier: GPL-2.0+ - -/dts-v1/; - -/ { - #address-cells = <1>; - #size-cells = <1>; - - binman { - pre-load { - content = <&image>; - algo-name = "sha256,rsa2048"; - padding-name = "pkcs-1.5"; - key-name = "dev.key"; - header-size = <4096>; - version = <0x11223344>; - }; - - image: blob-ext { - filename = "refcode.bin"; - }; - }; -}; diff --git a/tools/binman/test/232_pre_load_pss.dts b/tools/binman/test/232_pre_load_pss.dts deleted file mode 100644 index 3008d3f4649..00000000000 --- a/tools/binman/test/232_pre_load_pss.dts +++ /dev/null @@ -1,23 +0,0 @@ -// SPDX-License-Identifier: GPL-2.0+ - -/dts-v1/; - -/ { - #address-cells = <1>; - #size-cells = <1>; - - binman { - pre-load { - content = <&image>; - algo-name = "sha256,rsa2048"; - padding-name = "pss"; - key-name = "dev.key"; - header-size = <4096>; - version = <0x11223344>; - }; - - image: blob-ext { - filename = "refcode.bin"; - }; - }; -}; diff --git a/tools/binman/test/233_pre_load_invalid_padding.dts b/tools/binman/test/233_pre_load_invalid_padding.dts deleted file mode 100644 index bbe2d1ba869..00000000000 --- a/tools/binman/test/233_pre_load_invalid_padding.dts +++ /dev/null @@ -1,23 +0,0 @@ -// SPDX-License-Identifier: GPL-2.0+ - -/dts-v1/; - -/ { - #address-cells = <1>; - #size-cells = <1>; - - binman { - pre-load { - content = <&image>; - algo-name = "sha256,rsa2048"; - padding-name = "padding"; - key-name = "dev.key"; - header-size = <4096>; - version = <1>; - }; - - image: blob-ext { - filename = "refcode.bin"; - }; - }; -}; diff --git a/tools/binman/test/234_pre_load_invalid_sha.dts b/tools/binman/test/234_pre_load_invalid_sha.dts deleted file mode 100644 index 29afd2e37e4..00000000000 --- a/tools/binman/test/234_pre_load_invalid_sha.dts +++ /dev/null @@ -1,23 +0,0 @@ -// SPDX-License-Identifier: GPL-2.0+ - -/dts-v1/; - -/ { - #address-cells = <1>; - #size-cells = <1>; - - binman { - pre-load { - content = <&image>; - algo-name = "sha2560,rsa2048"; - padding-name = "pkcs-1.5"; - key-name = "dev.key"; - header-size = <4096>; - version = <1>; - }; - - image: blob-ext { - filename = "refcode.bin"; - }; - }; -}; diff --git a/tools/binman/test/235_pre_load_invalid_algo.dts b/tools/binman/test/235_pre_load_invalid_algo.dts deleted file mode 100644 index d6f6dd20cd9..00000000000 --- a/tools/binman/test/235_pre_load_invalid_algo.dts +++ /dev/null @@ -1,23 +0,0 @@ -// SPDX-License-Identifier: GPL-2.0+ - -/dts-v1/; - -/ { - #address-cells = <1>; - #size-cells = <1>; - - binman { - pre-load { - content = <&image>; - algo-name = "sha256,rsa20480"; - padding-name = "pkcs-1.5"; - key-name = "dev.key"; - header-size = <4096>; - version = <1>; - }; - - image: blob-ext { - filename = "refcode.bin"; - }; - }; -}; diff --git a/tools/binman/test/236_pre_load_invalid_key.dts b/tools/binman/test/236_pre_load_invalid_key.dts deleted file mode 100644 index f93bc9792cd..00000000000 --- a/tools/binman/test/236_pre_load_invalid_key.dts +++ /dev/null @@ -1,23 +0,0 @@ -// SPDX-License-Identifier: GPL-2.0+ - -/dts-v1/; - -/ { - #address-cells = <1>; - #size-cells = <1>; - - binman { - pre-load { - content = <&image>; - algo-name = "sha256,rsa4096"; - padding-name = "pkcs-1.5"; - key-name = "dev.key"; - header-size = <4096>; - version = <1>; - }; - - image: blob-ext { - filename = "refcode.bin"; - }; - }; -}; diff --git a/tools/binman/test/279_x509_cert.dts b/tools/binman/test/279_x509_cert.dts deleted file mode 100644 index 71238172717..00000000000 --- a/tools/binman/test/279_x509_cert.dts +++ /dev/null @@ -1,19 +0,0 @@ -// SPDX-License-Identifier: GPL-2.0+ - -/dts-v1/; - -/ { - #address-cells = <1>; - #size-cells = <1>; - - binman { - x509-cert { - cert-ca = "IOT2050 Firmware Signature"; - cert-revision-int = <0>; - content = <&u_boot>; - }; - - u_boot: u-boot { - }; - }; -}; diff --git a/tools/binman/test/281_sign_non_fit.dts b/tools/binman/test/281_sign_non_fit.dts deleted file mode 100644 index e16c954246d..00000000000 --- a/tools/binman/test/281_sign_non_fit.dts +++ /dev/null @@ -1,65 +0,0 @@ -// SPDX-License-Identifier: GPL-2.0+ - -/dts-v1/; - -/ { - #address-cells = <1>; - #size-cells = <1>; - - binman { - size = <0x100000>; - allow-repack; - - u-boot { - }; - fit { - description = "U-Boot"; - offset = <0x10000>; - images { - u-boot-1 { - description = "U-Boot"; - type = "standalone"; - arch = "arm64"; - os = "u-boot"; - compression = "none"; - hash-1 { - algo = "sha256"; - }; - u-boot { - }; - }; - - fdt-1 { - description = "test.dtb"; - type = "flat_dt"; - arch = "arm64"; - compression = "none"; - hash-1 { - algo = "sha256"; - }; - u-boot-spl-dtb { - }; - }; - - }; - - configurations { - default = "conf-1"; - conf-1 { - description = "u-boot with fdt"; - firmware = "u-boot-1"; - fdt = "fdt-1"; - signature-1 { - algo = "sha256,rsa4096"; - key-name-hint = "test_key"; - sign-images = "firmware", "fdt"; - }; - - }; - }; - }; - - fdtmap { - }; - }; -}; diff --git a/tools/binman/test/301_encrypted_no_algo.dts b/tools/binman/test/301_encrypted_no_algo.dts deleted file mode 100644 index 03f7ffee90f..00000000000 --- a/tools/binman/test/301_encrypted_no_algo.dts +++ /dev/null @@ -1,15 +0,0 @@ -// SPDX-License-Identifier: GPL-2.0+ -/dts-v1/; - -/ { - binman { - fit { - images { - u-boot { - encrypted { - }; - }; - }; - }; - }; -}; diff --git a/tools/binman/test/302_encrypted_invalid_iv_file.dts b/tools/binman/test/302_encrypted_invalid_iv_file.dts deleted file mode 100644 index 388a0a6ad90..00000000000 --- a/tools/binman/test/302_encrypted_invalid_iv_file.dts +++ /dev/null @@ -1,18 +0,0 @@ -// SPDX-License-Identifier: GPL-2.0+ -/dts-v1/; - -/ { - binman { - fit { - images { - u-boot { - encrypted { - algo = "some-algo"; - key-source = "key"; - iv-filename = "invalid-iv-file"; - }; - }; - }; - }; - }; -}; diff --git a/tools/binman/test/303_encrypted_missing_key.dts b/tools/binman/test/303_encrypted_missing_key.dts deleted file mode 100644 index d1daaa08851..00000000000 --- a/tools/binman/test/303_encrypted_missing_key.dts +++ /dev/null @@ -1,23 +0,0 @@ -// SPDX-License-Identifier: GPL-2.0+ - -/dts-v1/; - -/ { - #address-cells = <1>; - #size-cells = <1>; - - binman { - fit { - description = "test desc"; - - images { - u-boot { - encrypted { - algo = "algo-name"; - iv-filename = "encrypted-file.iv"; - }; - }; - }; - }; - }; -}; diff --git a/tools/binman/test/304_encrypted_key_source.dts b/tools/binman/test/304_encrypted_key_source.dts deleted file mode 100644 index 884ec508db8..00000000000 --- a/tools/binman/test/304_encrypted_key_source.dts +++ /dev/null @@ -1,24 +0,0 @@ -// SPDX-License-Identifier: GPL-2.0+ - -/dts-v1/; - -/ { - #address-cells = <1>; - #size-cells = <1>; - - binman { - fit { - description = "test desc"; - - images { - u-boot { - encrypted { - algo = "algo-name"; - key-source = "key-source-value"; - iv-filename = "encrypted-file.iv"; - }; - }; - }; - }; - }; -}; diff --git a/tools/binman/test/305_encrypted_key_file.dts b/tools/binman/test/305_encrypted_key_file.dts deleted file mode 100644 index efd7ee5f35a..00000000000 --- a/tools/binman/test/305_encrypted_key_file.dts +++ /dev/null @@ -1,24 +0,0 @@ -// SPDX-License-Identifier: GPL-2.0+ - -/dts-v1/; - -/ { - #address-cells = <1>; - #size-cells = <1>; - - binman { - fit { - description = "test desc"; - - images { - u-boot { - encrypted { - algo = "algo-name"; - iv-filename = "encrypted-file.iv"; - key-filename = "encrypted-file.key"; - }; - }; - }; - }; - }; -}; diff --git a/tools/binman/test/306_spl_pubkey_dtb.dts b/tools/binman/test/306_spl_pubkey_dtb.dts deleted file mode 100644 index 3256ff970cd..00000000000 --- a/tools/binman/test/306_spl_pubkey_dtb.dts +++ /dev/null @@ -1,16 +0,0 @@ -// SPDX-License-Identifier: GPL-2.0+ - -/dts-v1/; - -/ { - #address-cells = <1>; - #size-cells = <1>; - - binman { - u-boot-spl-pubkey-dtb { - algo = "sha384,rsa4096"; - required = "conf"; - key-name-hint = "key"; - }; - }; -}; diff --git a/tools/binman/test/307_xilinx_bootgen_sign.dts b/tools/binman/test/307_xilinx_bootgen_sign.dts deleted file mode 100644 index 02acf8652a5..00000000000 --- a/tools/binman/test/307_xilinx_bootgen_sign.dts +++ /dev/null @@ -1,22 +0,0 @@ -// SPDX-License-Identifier: GPL-2.0+ - -/dts-v1/; - -/ { - #address-cells = <1>; - #size-cells = <1>; - - binman { - xilinx-bootgen { - auth-params = "ppk_select=0", "spk_id=0x00000000"; - pmufw-filename = "pmu-firmware.elf"; - psk-key-name-hint = "psk"; - ssk-key-name-hint = "ssk"; - - u-boot-spl-nodtb { - }; - u-boot-spl-dtb { - }; - }; - }; -}; diff --git a/tools/binman/test/308_xilinx_bootgen_sign_enc.dts b/tools/binman/test/308_xilinx_bootgen_sign_enc.dts deleted file mode 100644 index 5d7ce4c1f5a..00000000000 --- a/tools/binman/test/308_xilinx_bootgen_sign_enc.dts +++ /dev/null @@ -1,24 +0,0 @@ -// SPDX-License-Identifier: GPL-2.0+ - -/dts-v1/; - -/ { - #address-cells = <1>; - #size-cells = <1>; - - binman { - xilinx-bootgen { - auth-params = "ppk_select=0", "spk_id=0x00000000"; - fsbl-config = "auth_only"; - keysrc-enc = "efuse_red_key"; - pmufw-filename = "pmu-firmware.elf"; - psk-key-name-hint = "psk"; - ssk-key-name-hint = "ssk"; - - u-boot-spl-nodtb { - }; - u-boot-spl-dtb { - }; - }; - }; -}; diff --git a/tools/binman/test/348_key_name_hint_dir_spl_pubkey_dtb.dts b/tools/binman/test/348_key_name_hint_dir_spl_pubkey_dtb.dts deleted file mode 100644 index 85ebd58b6c0..00000000000 --- a/tools/binman/test/348_key_name_hint_dir_spl_pubkey_dtb.dts +++ /dev/null @@ -1,16 +0,0 @@ -// SPDX-License-Identifier: GPL-2.0+ - -/dts-v1/; - -/ { - #address-cells = <1>; - #size-cells = <1>; - - binman { - u-boot-spl-pubkey-dtb { - algo = "sha384,rsa4096"; - required = "conf"; - key-name-hint = "keys/key"; - }; - }; -}; diff --git a/tools/binman/test/security/encrypted_invalid_iv_file.dts b/tools/binman/test/security/encrypted_invalid_iv_file.dts new file mode 100644 index 00000000000..388a0a6ad90 --- /dev/null +++ b/tools/binman/test/security/encrypted_invalid_iv_file.dts @@ -0,0 +1,18 @@ +// SPDX-License-Identifier: GPL-2.0+ +/dts-v1/; + +/ { + binman { + fit { + images { + u-boot { + encrypted { + algo = "some-algo"; + key-source = "key"; + iv-filename = "invalid-iv-file"; + }; + }; + }; + }; + }; +}; diff --git a/tools/binman/test/security/encrypted_key_file.dts b/tools/binman/test/security/encrypted_key_file.dts new file mode 100644 index 00000000000..efd7ee5f35a --- /dev/null +++ b/tools/binman/test/security/encrypted_key_file.dts @@ -0,0 +1,24 @@ +// SPDX-License-Identifier: GPL-2.0+ + +/dts-v1/; + +/ { + #address-cells = <1>; + #size-cells = <1>; + + binman { + fit { + description = "test desc"; + + images { + u-boot { + encrypted { + algo = "algo-name"; + iv-filename = "encrypted-file.iv"; + key-filename = "encrypted-file.key"; + }; + }; + }; + }; + }; +}; diff --git a/tools/binman/test/security/encrypted_key_source.dts b/tools/binman/test/security/encrypted_key_source.dts new file mode 100644 index 00000000000..884ec508db8 --- /dev/null +++ b/tools/binman/test/security/encrypted_key_source.dts @@ -0,0 +1,24 @@ +// SPDX-License-Identifier: GPL-2.0+ + +/dts-v1/; + +/ { + #address-cells = <1>; + #size-cells = <1>; + + binman { + fit { + description = "test desc"; + + images { + u-boot { + encrypted { + algo = "algo-name"; + key-source = "key-source-value"; + iv-filename = "encrypted-file.iv"; + }; + }; + }; + }; + }; +}; diff --git a/tools/binman/test/security/encrypted_missing_key.dts b/tools/binman/test/security/encrypted_missing_key.dts new file mode 100644 index 00000000000..d1daaa08851 --- /dev/null +++ b/tools/binman/test/security/encrypted_missing_key.dts @@ -0,0 +1,23 @@ +// SPDX-License-Identifier: GPL-2.0+ + +/dts-v1/; + +/ { + #address-cells = <1>; + #size-cells = <1>; + + binman { + fit { + description = "test desc"; + + images { + u-boot { + encrypted { + algo = "algo-name"; + iv-filename = "encrypted-file.iv"; + }; + }; + }; + }; + }; +}; diff --git a/tools/binman/test/security/encrypted_no_algo.dts b/tools/binman/test/security/encrypted_no_algo.dts new file mode 100644 index 00000000000..03f7ffee90f --- /dev/null +++ b/tools/binman/test/security/encrypted_no_algo.dts @@ -0,0 +1,15 @@ +// SPDX-License-Identifier: GPL-2.0+ +/dts-v1/; + +/ { + binman { + fit { + images { + u-boot { + encrypted { + }; + }; + }; + }; + }; +}; diff --git a/tools/binman/test/security/hash.dts b/tools/binman/test/security/hash.dts new file mode 100644 index 00000000000..200304599dc --- /dev/null +++ b/tools/binman/test/security/hash.dts @@ -0,0 +1,12 @@ +// SPDX-License-Identifier: GPL-2.0+ +/dts-v1/; + +/ { + binman { + u-boot { + hash { + algo = "sha256"; + }; + }; + }; +}; diff --git a/tools/binman/test/security/hash_bad_algo.dts b/tools/binman/test/security/hash_bad_algo.dts new file mode 100644 index 00000000000..d2402000db6 --- /dev/null +++ b/tools/binman/test/security/hash_bad_algo.dts @@ -0,0 +1,12 @@ +// SPDX-License-Identifier: GPL-2.0+ +/dts-v1/; + +/ { + binman { + u-boot { + hash { + algo = "invalid"; + }; + }; + }; +}; diff --git a/tools/binman/test/security/hash_no_algo.dts b/tools/binman/test/security/hash_no_algo.dts new file mode 100644 index 00000000000..b64df205117 --- /dev/null +++ b/tools/binman/test/security/hash_no_algo.dts @@ -0,0 +1,11 @@ +// SPDX-License-Identifier: GPL-2.0+ +/dts-v1/; + +/ { + binman { + u-boot { + hash { + }; + }; + }; +}; diff --git a/tools/binman/test/security/hash_section.dts b/tools/binman/test/security/hash_section.dts new file mode 100644 index 00000000000..dcd8683d642 --- /dev/null +++ b/tools/binman/test/security/hash_section.dts @@ -0,0 +1,18 @@ +// SPDX-License-Identifier: GPL-2.0+ +/dts-v1/; + +/ { + binman { + section { + u-boot { + }; + fill { + size = <0x10>; + fill-byte = [61]; + }; + hash { + algo = "sha256"; + }; + }; + }; +}; diff --git a/tools/binman/test/security/key_name_hint_dir_spl_pubkey_dtb.dts b/tools/binman/test/security/key_name_hint_dir_spl_pubkey_dtb.dts new file mode 100644 index 00000000000..85ebd58b6c0 --- /dev/null +++ b/tools/binman/test/security/key_name_hint_dir_spl_pubkey_dtb.dts @@ -0,0 +1,16 @@ +// SPDX-License-Identifier: GPL-2.0+ + +/dts-v1/; + +/ { + #address-cells = <1>; + #size-cells = <1>; + + binman { + u-boot-spl-pubkey-dtb { + algo = "sha384,rsa4096"; + required = "conf"; + key-name-hint = "keys/key"; + }; + }; +}; diff --git a/tools/binman/test/security/pre_load.dts b/tools/binman/test/security/pre_load.dts new file mode 100644 index 00000000000..e6d9ef40c6c --- /dev/null +++ b/tools/binman/test/security/pre_load.dts @@ -0,0 +1,22 @@ +// SPDX-License-Identifier: GPL-2.0+ + +/dts-v1/; + +/ { + #address-cells = <1>; + #size-cells = <1>; + + binman { + pre-load { + content = <&image>; + algo-name = "sha256,rsa2048"; + key-name = "dev.key"; + header-size = <4096>; + version = <0x11223344>; + }; + + image: blob-ext { + filename = "refcode.bin"; + }; + }; +}; diff --git a/tools/binman/test/security/pre_load_invalid_algo.dts b/tools/binman/test/security/pre_load_invalid_algo.dts new file mode 100644 index 00000000000..d6f6dd20cd9 --- /dev/null +++ b/tools/binman/test/security/pre_load_invalid_algo.dts @@ -0,0 +1,23 @@ +// SPDX-License-Identifier: GPL-2.0+ + +/dts-v1/; + +/ { + #address-cells = <1>; + #size-cells = <1>; + + binman { + pre-load { + content = <&image>; + algo-name = "sha256,rsa20480"; + padding-name = "pkcs-1.5"; + key-name = "dev.key"; + header-size = <4096>; + version = <1>; + }; + + image: blob-ext { + filename = "refcode.bin"; + }; + }; +}; diff --git a/tools/binman/test/security/pre_load_invalid_key.dts b/tools/binman/test/security/pre_load_invalid_key.dts new file mode 100644 index 00000000000..f93bc9792cd --- /dev/null +++ b/tools/binman/test/security/pre_load_invalid_key.dts @@ -0,0 +1,23 @@ +// SPDX-License-Identifier: GPL-2.0+ + +/dts-v1/; + +/ { + #address-cells = <1>; + #size-cells = <1>; + + binman { + pre-load { + content = <&image>; + algo-name = "sha256,rsa4096"; + padding-name = "pkcs-1.5"; + key-name = "dev.key"; + header-size = <4096>; + version = <1>; + }; + + image: blob-ext { + filename = "refcode.bin"; + }; + }; +}; diff --git a/tools/binman/test/security/pre_load_invalid_padding.dts b/tools/binman/test/security/pre_load_invalid_padding.dts new file mode 100644 index 00000000000..bbe2d1ba869 --- /dev/null +++ b/tools/binman/test/security/pre_load_invalid_padding.dts @@ -0,0 +1,23 @@ +// SPDX-License-Identifier: GPL-2.0+ + +/dts-v1/; + +/ { + #address-cells = <1>; + #size-cells = <1>; + + binman { + pre-load { + content = <&image>; + algo-name = "sha256,rsa2048"; + padding-name = "padding"; + key-name = "dev.key"; + header-size = <4096>; + version = <1>; + }; + + image: blob-ext { + filename = "refcode.bin"; + }; + }; +}; diff --git a/tools/binman/test/security/pre_load_invalid_sha.dts b/tools/binman/test/security/pre_load_invalid_sha.dts new file mode 100644 index 00000000000..29afd2e37e4 --- /dev/null +++ b/tools/binman/test/security/pre_load_invalid_sha.dts @@ -0,0 +1,23 @@ +// SPDX-License-Identifier: GPL-2.0+ + +/dts-v1/; + +/ { + #address-cells = <1>; + #size-cells = <1>; + + binman { + pre-load { + content = <&image>; + algo-name = "sha2560,rsa2048"; + padding-name = "pkcs-1.5"; + key-name = "dev.key"; + header-size = <4096>; + version = <1>; + }; + + image: blob-ext { + filename = "refcode.bin"; + }; + }; +}; diff --git a/tools/binman/test/security/pre_load_pkcs.dts b/tools/binman/test/security/pre_load_pkcs.dts new file mode 100644 index 00000000000..66268cdb212 --- /dev/null +++ b/tools/binman/test/security/pre_load_pkcs.dts @@ -0,0 +1,23 @@ +// SPDX-License-Identifier: GPL-2.0+ + +/dts-v1/; + +/ { + #address-cells = <1>; + #size-cells = <1>; + + binman { + pre-load { + content = <&image>; + algo-name = "sha256,rsa2048"; + padding-name = "pkcs-1.5"; + key-name = "dev.key"; + header-size = <4096>; + version = <0x11223344>; + }; + + image: blob-ext { + filename = "refcode.bin"; + }; + }; +}; diff --git a/tools/binman/test/security/pre_load_pss.dts b/tools/binman/test/security/pre_load_pss.dts new file mode 100644 index 00000000000..3008d3f4649 --- /dev/null +++ b/tools/binman/test/security/pre_load_pss.dts @@ -0,0 +1,23 @@ +// SPDX-License-Identifier: GPL-2.0+ + +/dts-v1/; + +/ { + #address-cells = <1>; + #size-cells = <1>; + + binman { + pre-load { + content = <&image>; + algo-name = "sha256,rsa2048"; + padding-name = "pss"; + key-name = "dev.key"; + header-size = <4096>; + version = <0x11223344>; + }; + + image: blob-ext { + filename = "refcode.bin"; + }; + }; +}; diff --git a/tools/binman/test/security/section_ignore_hash_signature.dts b/tools/binman/test/security/section_ignore_hash_signature.dts new file mode 100644 index 00000000000..8adbe25512a --- /dev/null +++ b/tools/binman/test/security/section_ignore_hash_signature.dts @@ -0,0 +1,40 @@ +// SPDX-License-Identifier: GPL-2.0+ + +/dts-v1/; + +/ { + #address-cells = <1>; + #size-cells = <1>; + + binman { + section@0 { + u-boot { + }; + hash { + algo = "sha256"; + }; + signature { + algo = "sha256,rsa2048"; + key-name-hint = "dev"; + }; + }; + section@1 { + u-boot { + }; + hash-1 { + algo = "sha1"; + }; + hash-2 { + algo = "sha256"; + }; + signature-1 { + algo = "sha1,rsa2048"; + key-name-hint = "dev"; + }; + signature-2 { + algo = "sha256,rsa2048"; + key-name-hint = "dev"; + }; + }; + }; +}; diff --git a/tools/binman/test/security/sign_non_fit.dts b/tools/binman/test/security/sign_non_fit.dts new file mode 100644 index 00000000000..e16c954246d --- /dev/null +++ b/tools/binman/test/security/sign_non_fit.dts @@ -0,0 +1,65 @@ +// SPDX-License-Identifier: GPL-2.0+ + +/dts-v1/; + +/ { + #address-cells = <1>; + #size-cells = <1>; + + binman { + size = <0x100000>; + allow-repack; + + u-boot { + }; + fit { + description = "U-Boot"; + offset = <0x10000>; + images { + u-boot-1 { + description = "U-Boot"; + type = "standalone"; + arch = "arm64"; + os = "u-boot"; + compression = "none"; + hash-1 { + algo = "sha256"; + }; + u-boot { + }; + }; + + fdt-1 { + description = "test.dtb"; + type = "flat_dt"; + arch = "arm64"; + compression = "none"; + hash-1 { + algo = "sha256"; + }; + u-boot-spl-dtb { + }; + }; + + }; + + configurations { + default = "conf-1"; + conf-1 { + description = "u-boot with fdt"; + firmware = "u-boot-1"; + fdt = "fdt-1"; + signature-1 { + algo = "sha256,rsa4096"; + key-name-hint = "test_key"; + sign-images = "firmware", "fdt"; + }; + + }; + }; + }; + + fdtmap { + }; + }; +}; diff --git a/tools/binman/test/security/spl_pubkey_dtb.dts b/tools/binman/test/security/spl_pubkey_dtb.dts new file mode 100644 index 00000000000..3256ff970cd --- /dev/null +++ b/tools/binman/test/security/spl_pubkey_dtb.dts @@ -0,0 +1,16 @@ +// SPDX-License-Identifier: GPL-2.0+ + +/dts-v1/; + +/ { + #address-cells = <1>; + #size-cells = <1>; + + binman { + u-boot-spl-pubkey-dtb { + algo = "sha384,rsa4096"; + required = "conf"; + key-name-hint = "key"; + }; + }; +}; diff --git a/tools/binman/test/security/x509_cert.dts b/tools/binman/test/security/x509_cert.dts new file mode 100644 index 00000000000..71238172717 --- /dev/null +++ b/tools/binman/test/security/x509_cert.dts @@ -0,0 +1,19 @@ +// SPDX-License-Identifier: GPL-2.0+ + +/dts-v1/; + +/ { + #address-cells = <1>; + #size-cells = <1>; + + binman { + x509-cert { + cert-ca = "IOT2050 Firmware Signature"; + cert-revision-int = <0>; + content = <&u_boot>; + }; + + u_boot: u-boot { + }; + }; +}; diff --git a/tools/binman/test/security/xilinx_bootgen_sign.dts b/tools/binman/test/security/xilinx_bootgen_sign.dts new file mode 100644 index 00000000000..02acf8652a5 --- /dev/null +++ b/tools/binman/test/security/xilinx_bootgen_sign.dts @@ -0,0 +1,22 @@ +// SPDX-License-Identifier: GPL-2.0+ + +/dts-v1/; + +/ { + #address-cells = <1>; + #size-cells = <1>; + + binman { + xilinx-bootgen { + auth-params = "ppk_select=0", "spk_id=0x00000000"; + pmufw-filename = "pmu-firmware.elf"; + psk-key-name-hint = "psk"; + ssk-key-name-hint = "ssk"; + + u-boot-spl-nodtb { + }; + u-boot-spl-dtb { + }; + }; + }; +}; diff --git a/tools/binman/test/security/xilinx_bootgen_sign_enc.dts b/tools/binman/test/security/xilinx_bootgen_sign_enc.dts new file mode 100644 index 00000000000..5d7ce4c1f5a --- /dev/null +++ b/tools/binman/test/security/xilinx_bootgen_sign_enc.dts @@ -0,0 +1,24 @@ +// SPDX-License-Identifier: GPL-2.0+ + +/dts-v1/; + +/ { + #address-cells = <1>; + #size-cells = <1>; + + binman { + xilinx-bootgen { + auth-params = "ppk_select=0", "spk_id=0x00000000"; + fsbl-config = "auth_only"; + keysrc-enc = "efuse_red_key"; + pmufw-filename = "pmu-firmware.elf"; + psk-key-name-hint = "psk"; + ssk-key-name-hint = "ssk"; + + u-boot-spl-nodtb { + }; + u-boot-spl-dtb { + }; + }; + }; +}; -- cgit v1.3.1