This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

DFU keys update

Hi,

I tried to update DFU keys via update on SDK-4.1 and I didin't to do it. Its possible to change DFU keys via upgrade. I did this process on SDK-2 and there was no validation of dfu key via Bootloader but not in SDK-4. 

My steps:

  1. Prepare key pair version 1
  2. Prepare key pair version 2
  3. Flash board with dfu keys ver 1
  4. Change public key dfu_public_key.c to ver 2
  5. Prepare DFU package SW v2 (signed by old key - ver1)
  6. Update with SW v2
  7. Prepare DFU package SW v3 (signed by new key - ver2)
  8. Update with SW v3

In step 8, after download image and reboot, bootloader fail new app on verification of signature.

Please, let me know if its possible to do DFU keys update on sdk-4.1ff

Thanks

Parents
  • Hi Terje,

    Little update:

    I try to update like this (SDK4):

    1. Prepare keys pair 1 (let's call them pub1 and priv1) and pair 2 (pub2 and priv2)
    2. On SoC: Bootloader 1, Application 1, compiled with public key 1 (pub1), signed with private key 1 (priv1).
    3. Prepare bootlader dfu package (compiled with pub2, signed with priv1)
    4. DFU is performed
    5. Prepare application dfu package (compiled with pub2, signed with priv1)
    6. DFU is performed
      1. application is downloaded correctly
      2. reboot after DFU
      3. bootloader - signature error 

    In case 9.c I got bootloader error debug:

    <error> nrf_dfu_validation: Signature failed (err_code: 0x8542)
    
    I know that it should not update bootloader and keys but is there any other way to change the keys via dfu?

    Regards 

    Piotr

Reply
  • Hi Terje,

    Little update:

    I try to update like this (SDK4):

    1. Prepare keys pair 1 (let's call them pub1 and priv1) and pair 2 (pub2 and priv2)
    2. On SoC: Bootloader 1, Application 1, compiled with public key 1 (pub1), signed with private key 1 (priv1).
    3. Prepare bootlader dfu package (compiled with pub2, signed with priv1)
    4. DFU is performed
    5. Prepare application dfu package (compiled with pub2, signed with priv1)
    6. DFU is performed
      1. application is downloaded correctly
      2. reboot after DFU
      3. bootloader - signature error 

    In case 9.c I got bootloader error debug:

    <error> nrf_dfu_validation: Signature failed (err_code: 0x8542)
    
    I know that it should not update bootloader and keys but is there any other way to change the keys via dfu?

    Regards 

    Piotr

Children
No Data
Related