diff --git a/suit_generator/suit/envelope.py b/suit_generator/suit/envelope.py index c7ccf9e..c446bd8 100644 --- a/suit_generator/suit/envelope.py +++ b/suit_generator/suit/envelope.py @@ -24,6 +24,7 @@ suit_candidate_verification, suit_payload_fetch, suit_install, + suit_install_legacy, suit_text, suit_integrated_payloads, suit_integrated_dependencies, @@ -42,6 +43,7 @@ class SuitEnvelopeSimplified(SuitKeyValue): suit_payload_fetch: SuitBstr, suit_candidate_verification: SuitBstr, suit_install: SuitBstr, + suit_install_legacy: SuitBstr, suit_text: SuitBstr, suit_integrated_payloads: SuitIntegratedPayloadMap, suit_integrated_dependencies: SuitIntegratedPayloadMap, @@ -62,6 +64,7 @@ class SuitEnvelope(SuitKeyValue): suit_payload_fetch: cbstr(SuitCommandSequence), suit_candidate_verification: cbstr(SuitCommandSequence), suit_install: cbstr(SuitCommandSequence), + suit_install_legacy: cbstr(SuitCommandSequence), suit_text: cbstr(SuitTextMap), suit_integrated_payloads: SuitIntegratedPayloadMap, suit_integrated_dependencies: SuitIntegratedPayloadMap, @@ -104,6 +107,7 @@ def update_severable_digests(self): suit_payload_fetch, suit_candidate_verification, suit_install, + suit_install_legacy, ] for severable_element in severable_elements: if severable_element in self.SuitEnvelopeTagged.value.SuitEnvelope[suit_manifest].SuitManifest and hasattr( diff --git a/suit_generator/suit/manifest.py b/suit_generator/suit/manifest.py index 5ba5435..67c1e72 100644 --- a/suit_generator/suit/manifest.py +++ b/suit_generator/suit/manifest.py @@ -92,6 +92,7 @@ suit_invoke, suit_payload_fetch, suit_install, + suit_install_legacy, suit_text_manifest_description, suit_text_manifest_json_source, suit_text_manifest_yaml_source, @@ -468,6 +469,7 @@ class SuitManifest(SuitKeyValue): suit_invoke: cbstr(SuitCommandSequence), suit_payload_fetch: SuitSeverableCommandSequence, suit_install: SuitSeverableCommandSequence, + suit_install_legacy: SuitSeverableCommandSequence, suit_text: SuitSeverableText, suit_dependency_resolution: SuitSeverableCommandSequence, suit_candidate_verification: SuitSeverableCommandSequence, diff --git a/suit_generator/suit/types/keys.py b/suit_generator/suit/types/keys.py index 8a7bf3d..8fba815 100644 --- a/suit_generator/suit/types/keys.py +++ b/suit_generator/suit/types/keys.py @@ -302,10 +302,17 @@ class suit_payload_fetch(suit_key): name = "suit-payload-fetch" +class suit_install_legacy(suit_key): + """suit-install metadata (before v27).""" + + id = 17 + name = "suit-install-legacy" + + class suit_install(suit_key): """suit-install metadata.""" - id = 17 + id = 20 name = "suit-install" diff --git a/tests/test_suit_envelope_severable.py b/tests/test_suit_envelope_severable.py index 1c003ba..429709d 100644 --- a/tests/test_suit_envelope_severable.py +++ b/tests/test_suit_envelope_severable.py @@ -376,9 +376,9 @@ "ENVELOPE_2_SEVERED_TEXT_FETCH_INSTALL": ( "d86ba602458143822f400358cea601010201035857a2028384414d4218ff451a0e054000451a0005600084414" "d410e451a2e054000451a000560008241444100045829840c0114a201507617daa571fd5a858f94e28d735ce9" - "f40250d622bafd4337518590bc6368cda7fbca11822f5820f0b65173c03a9c481a0fe3ea62ed744bcfb0bef21" + "f40250d622bafd4337518590bc6368cda7fbca14822f5820f0b65173c03a9c481a0fe3ea62ed744bcfb0bef21" "43d4380e52dd67d5ee4200d10822f5820814a3a9e09cf691e5fa77c315c0a69a9929ee86601d5dfdca8b24819" - "e0be745917822f5820aac171d7a184ecd31c01495ac6b656b2e60a5aa43de6f6d1c9acdac29bb540c211581e9" + "e0be745917822f5820aac171d7a184ecd31c01495ac6b656b2e60a5aa43de6f6d1c9acdac29bb540c214581e9" "00c0214a115692366696c652e62696e150003000c0114a11602160003001050840c0214a115692366696c652e" "62696e175896a162656ea184414d4102451a0e0aa000451a00056000a60178184e6f726469632053656d69636" "f6e647563746f7220415341026e6e5246353432305f637075617070036e6e6f7264696373656d692e636f6d04"