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

Thread SDK / OTA bug

I merged in some of my code to the examples/thread/dfu/client in the v4.1.0 SDK for Thread and Zigbee. After getting OTA DFU working, I moved onto some commissioning related stuff. I spent several days trying to figure out why I could not join my 52840DK to the Border Router. No matter what I did, I would get 'Join failed [Security]'. Wireshark shows failure in the DTLS handshake. I thought I had done something wrong, but turns out something in Nordic code has broken openthread.

For me this was very easy to reproduce. Simply take the examples/thread/dfu/client, and modify main.c to change ' .autocommissioning = true,' to ' .autocommissioning = false, .autostart_disable = true' so you can join a thread network rather than using built in hardcoded credentials.

Program the device (being sure to follow nordic instructions for mbr, bootloader, and this app), connect using the UART, and try to join a border router that is ready to accept the device.

> ifconfig up
Done
> joiner start TEST1234
Done
> Join failed [Security]

On a packet sniffer note that DTLS handshake fails.

I saw some other UNANSWERED devzone messages with a theme of nrf crypto breaking openthread DTLS. Not sure if that related, but one big difference between the thread/dfu/client and thread/cli example is the inclusion of nrf crypto related libraries. Also the thread/dfu/bootloader is part of the picture.

I am completely stuck at this point.

Parents Reply
  • The thread/cli example (which does not use the nrf_crypto libraries) works fine. That was my initial baseline, but I had to rebase my code to the thread/dfu/client to add background OTA DFU behavior. It was a lot of work too because it meant I needed to rewrite all my code to use the IoT CoAP stack rather than the Openthread CoAP stack to coexists. Regardless, I found the problem easy to reproduce as I describe above. Thanks and looking forward to a solution so i can continue development.

Children
No Data
Related