[riot-notifications] [RIOT-OS/RIOT] examples/suit_update: improve test script (#12149)

Francisco notifications at github.com
Mon Sep 2 14:42:54 CEST 2019


### Contribution description

This PR extends the  example test to verify sequence number and signature validation is performed correctly.

Because of #11988 we first ping the node. If not aiocoap resends the first "trigger" since it doesn't receive the `ACK` this results in receiving the same manifest twice which means the second test fails since the signature is still invalid.

### Testing procedure

Follow [examples/suit_update/README](https://github.com/fjmolinas/RIOT/blob/2fd54232108254b81f2b3afca4f5206ea93dbdd6/examples/suit_update/README.md) `Automatic test` section.

### Issues/PRs references

Depends on #11818 
Related to #11988
You can view, comment on, or merge this pull request online at:

  https://github.com/RIOT-OS/RIOT/pull/12149

-- Commit Summary --

  * tools/flake8: exclude suit_manifest_encoder_04 script
  * suit: add SUIT draft v4 manifest tools
  * sys/suit: add SUIT draft v4 firmware upgrade module
  * examples/suit_update: add SUIT draft v4 example & test
  * fixup! sys/suit: add SUIT draft v4 firmware upgrade module
  * fixup! sys/suit: add SUIT draft v4 firmware upgrade module
  * tools/suit_v4: remove click dependency from gen_manifest.py
  * fixup! examples/suit_update: add SUIT draft v4 example & test
  * fixup! fixup! examples/suit_update: add SUIT draft v4 example & test
  * fixup! fixup! sys/suit: add SUIT draft v4 firmware upgrade module
  * fixup! sys/suit: add SUIT draft v4 firmware upgrade module
  * fixup! fixup! sys/suit: add SUIT draft v4 firmware upgrade module
  * fixup! sys/suit: add SUIT draft v4 firmware upgrade module
  * fixup! sys/suit: add SUIT draft v4 firmware upgrade module
  * fixup! sys/suit: add SUIT draft v4 firmware upgrade module
  * fixup! fixup! sys/suit: add SUIT draft v4 firmware upgrade module
  * fixup! fixup! fixup! examples/suit_update: add SUIT draft v4 example & test
  * fixup! fixup! fixup! sys/suit: add SUIT draft v4 firmware upgrade module
  * fixup! fixup! fixup! sys/suit: add SUIT draft v4 firmware upgrade module
  * fixup! sys/suit: add SUIT draft v4 firmware upgrade module
  * fixup! fixup! sys/suit: add SUIT draft v4 firmware upgrade module
  * fixup! sys/suit: add SUIT draft v4 firmware upgrade module
  * fixup! fixup! fixup! fixup! sys/suit: add SUIT draft v4 firmware upgrade module
  * fixup! examples/suit_update: add SUIT draft v4 example & test
  * fixup! tools/suit_v4: remove click dependency from gen_manifest.py
  * fixup! fixup! fixup! fixup! examples/suit_update: add SUIT draft v4 example & test
  * fixup! fixup! sys/suit: add SUIT draft v4 firmware upgrade module
  * fixup! fixup! fixup! sys/suit: add SUIT draft v4 firmware upgrade module
  * fixup! fixup! fixup! fixup! fixup! examples/suit_update: add SUIT draft v4 example & test
  * examples/suit_update: improve test script

-- File Changes --

    M .gitignore (3)
    M Makefile.dep (25)
    M dist/tools/flake8/check.sh (7)
    A dist/tools/suit_v4/gen_key.py (33)
    A dist/tools/suit_v4/gen_manifest.py (94)
    A dist/tools/suit_v4/sign-04.py (154)
    A dist/tools/suit_v4/suit_manifest_encoder_04.py (411)
    A dist/tools/suit_v4/test-2img.json (33)
    A examples/suit_update/Makefile (106)
    A examples/suit_update/README.md (558)
    A examples/suit_update/coap_handler.c (32)
    A examples/suit_update/main.c (77)
    A examples/suit_update/tests/01-run.py (183)
    M makefiles/boot/riotboot.mk (7)
    M makefiles/pseudomodules.inc.mk (6)
    A makefiles/suit.v4.inc.mk (103)
    M sys/Makefile (3)
    M sys/auto_init/auto_init.c (5)
    A sys/include/suit/coap.h (108)
    A sys/include/suit/conditions.h (109)
    A sys/include/suit/v4/handlers.h (62)
    A sys/include/suit/v4/policy.h (58)
    A sys/include/suit/v4/suit.h (288)
    A sys/suit/Makefile (9)
    A sys/suit/coap.c (514)
    A sys/suit/conditions.c (67)
    A sys/suit/v4/Makefile (2)
    A sys/suit/v4/cbor.c (276)
    A sys/suit/v4/handlers.c (547)
    A sys/suit/v4/policy.c (37)

-- Patch Links --

https://github.com/RIOT-OS/RIOT/pull/12149.patch
https://github.com/RIOT-OS/RIOT/pull/12149.diff

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/RIOT-OS/RIOT/pull/12149
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.riot-os.org/pipermail/notifications/attachments/20190902/0c35d94c/attachment.htm>


More information about the notifications mailing list