nRF9160 KEYGEN AT Command Issue

Hello, we are seeing an issue when using the KEYGEN AT command to generate a CBOR object as dictated in the provisioning steps for nRF Cloud: https://docs.nrfcloud.com/Guides/GettingStarted/Devices

I see that the key is written to memory by checking AT%CMNG=1, but I do not get an output string in response and thus cannot continue with provisioning. Our FAE helped us identify that the AT Monitor is trying to allocate heap space for the response, and we tried increasing heap size by using `CONFIG_AT_MONITOR_HEAP_SIZE=1024` in the `prj.conf` with no effect. On the nrf91 logs, I am not seeing any error messages about heap size. We are using the SLM program.

Modem FW Version 1.3.1
NCS Version 2.0.0

Parents
  • Hi,

     

    Are you certain that you're using mfw v1.3.1 on the device you're testing with?

    You will need to run this sequence with mfw v1.3.x branch.

     

    I tested the serial_lte_modem, without any changes at all (I kept "CONFIG_AT_MONITOR_HEAP_SIZE" to default 256 size), and this was the output after issuing the AT command:

    AT%KEYGEN=16842753,2,0
    
    %KEYGEN: "MIIBCTC..redacted_key"
    

     

    Have you tried to issue the same with the "at_client" sample instead? 

     

    Kind regards,

    Håkon

Reply
  • Hi,

     

    Are you certain that you're using mfw v1.3.1 on the device you're testing with?

    You will need to run this sequence with mfw v1.3.x branch.

     

    I tested the serial_lte_modem, without any changes at all (I kept "CONFIG_AT_MONITOR_HEAP_SIZE" to default 256 size), and this was the output after issuing the AT command:

    AT%KEYGEN=16842753,2,0
    
    %KEYGEN: "MIIBCTC..redacted_key"
    

     

    Have you tried to issue the same with the "at_client" sample instead? 

     

    Kind regards,

    Håkon

Children
  • I am running mfw v1.3.4.  I tried to do the same thing with at%keygen=11,2,0.  The output shows the entire key.  It doesn't look like a CBOR format "xxxxxxxx.xxxxxxx" at all.  It also writes the key into sec tag 11.  Did I miss something?

    Regards,

    Floyd

  • Wait.  Here is the entire output:

    %KEYGEN:"MIIBCTCBrwIBADAvMS0wKwYDVQQDDCQ1MDRiNTgzOS0zNzM1LTRkNzEtODA2OC0xNDE2NGM3NGE0NGQwWTATBgcqhkjOPQIBBggqhkjOPQMBBwNCAATlKIQdFYs4sUZy4BW6Zcvsge2lzKha2LMiW-lNM4dFbfedPIk6v-oFLjgRdquYuW_go0sdAHYeFbW2kLRUIKEToB4wHAYJKoZIhvcNAQkOMQ8wDTALBgNVHQ8EBAMCA-gwDAYIKoZIzj0EAwIFAANHADBEAiA9xlIJW0l25i9pM3OxTOWQVy5fV2rGDsKkMwCsLWD3TwIgGBmmdumjX6jWe5kmLUgx7T2-u4sgvaLu4KVkWoCYWFc.0oRDoQEmoQRBIVhL2dn3hQlQUEtYOTc1TXGAaBQWTHSkTUELWCBhM5caHRDBXSsuyOhyX_ovdeibUKQ-xognwA-uWTUWnFAV_0IlB1Kb3Ia_38b93rflWEDxBkoNJeJNlAZTZdCETVBOKLWxDuKt-J3CuW17rUWsEuvRiArHUzgsNyBRepuXm7ITslxOw3CtwWuoDjh64gB6"

    I can see a dot about 2/3 down the string, Fc.0o.  Is what I am getting correct?

Related