HTTPS sample, Modem

*** Booting nRF Connect SDK 4040aa0bf581 ***
[00:00:00.282,501] <dbg> pdn: pdn_default_ctx_cb_reg: Default PDP ctx callback 0x95d5 registered
HTTPS client sample started
Bringing network interface up
[00:00:00.282,714] <inf> nrf_modem: Initializing libmodem 2.6.1-lte-11b6ed4846a8
[00:00:00.283,111] <dbg> nrf_modem: Control region at 0x20008000 (0x4e8 bytes)
[00:00:00.283,142] <dbg> nrf_modem: TX region at 0x200084e8 (0x2000 bytes)
[00:00:00.283,172] <dbg> nrf_modem: RX region at 0x2000a568 (0x2000 bytes)
[00:00:00.283,203] <dbg> nrf_modem: Trace region at 0x0 (0x0 bytes)
[00:00:00.514,495] <dbg> nrf_modem: Handshake completed
[00:00:00.514,556] <dbg> nrf_modem: Modem data list size: 16
[00:00:00.514,587] <dbg> nrf_modem: Modem control list size: 16
[00:00:00.514,617] <inf> nrf_modem: RPC ready
[00:00:00.514,984] <dbg> nrf_modem: nrf_modem_lib_init: Modem init callback: 0x158a9
[00:00:00.515,106] <dbg> nrf_modem: AT%XMAGPIO=1,0,0,1,1,1574,1577
[00:00:00.521,728] <dbg> nrf_modem: AT%XCOEX0=1,1,1565,1586
[00:00:00.522,094] <dbg> nrf_modem: nrf_modem_lib_init: Modem init callback: 0x15245
[00:00:00.522,186] <dbg> nrf_modem: AT%XSYSTEMMODE=1,1,1,3
[00:00:00.524,139] <dbg> lte_lc: lte_lc_system_mode_set: System mode set to 7, preference 3
[00:00:00.524,200] <dbg> lte_lc: lte_lc_psm_param_set: RPTAU set to 00000011
[00:00:00.524,230] <dbg> lte_lc: lte_lc_psm_param_set: RAT set to 00100001
[00:00:00.524,291] <dbg> lte_lc: on_modem_init: PSM configs set from string: tau=00000011, rat=00100
001
[00:00:00.524,322] <dbg> lte_lc: lte_lc_psm_req: enable=0, tau=00000011, rat=00100001
[00:00:00.524,414] <dbg> nrf_modem: AT+CPSMS=
[00:00:00.530,975] <dbg> nrf_modem: AT%FEACONF=0,0,0
[00:00:00.531,494] <dbg> nrf_modem: AT+CEDRXS=3
[00:00:00.531,860] <dbg> nrf_modem: AT%RAI=0
[00:00:00.532,287] <dbg> nrf_modem: nrf_modem_lib_init: Modem init callback: 0x20917
[00:00:00.532,348] <dbg> nrf_modem: AT%XEPCO=1
Provisioning certificate
[00:00:00.532,867] <dbg> nrf_modem: AT+CMEE?
[00:00:00.533,203] <dbg> nrf_modem: AT+CMEE=1
[00:00:00.533,569] <dbg> nrf_modem: AT%CMNG=1,42,0
[00:00:00.564,666] <dbg> nrf_modem: AT+CMEE=0
[00:00:00.565,002] <dbg> nrf_modem: AT+CMEE?
[00:00:00.565,399] <dbg> nrf_modem: AT+CMEE=1
[00:00:00.565,765] <dbg> nrf_modem: AT%CMNG=2,42,0
[00:00:00.571,746] <err> nrf_modem: Modem fault occurred, gpmem1: 0x10004, gpmem2: 0xecb64
[00:00:00.571,777] <err> nrf_modem_lib_netif: Modem error: 0x4, PC: 0xecb64
[00:00:00.571,807] <err> lte_lc: Failed to set functional mode. Please check XSYSTEMMODE.
[00:00:00.571,838] <err> nrf_modem_lib_netif: lte_lc_func_mode_set, error: -14
Fatal error received from the connectivity layer
[00:00:00.571,899] <err> conn_mgr_conn: Unknown fatal connectivity error on iface 1 (0x2000caf0).
Certificate mismatch
[00:00:00.571,960] <wrn> modem_key_mgmt: Failed to retrieve CMEE status, err -1
Failed to delete existing certificate, err -1
Provisioning certificate
[00:00:00.572,021] <wrn> modem_key_mgmt: Failed to retrieve CMEE status, err -1
Failed to provision certificate, err -1

Document: HTTPS_SAMPLE_2024_09_19T02_55_15_089Z.txt
I was programming the HTTPS sample with default parameters. I managed to connect to "example.com successfully". I managed to connect to a custom server with a PEM certificate successfully. However when I attempted to connect to another server, the certificate was too large, so I increased the size. The modem failed to process the certificate and has entered an error mode. I have tried, factory resetting the modem, reloading firmware and testing AT commands but I still get an error, after setting the HTTPS sample back to its default configuration. 



Parents
  • Hello, 

    Could you please provide more information on what version of the nRF Connect SDK and modem FW you are running? I assume that you are using the HTTPS client from our networking samples?  Just to verify modem functionality, can you provide a modem trace?. What SIM are you using? 

    The nRF9160 has limit in the modem FW - from the release notes:

    - TLS/DTLS
        - Secure socket buffer size is 2kB.
        - Maximum length of DTLS datagram is 1kB.
        - One TLS handshake at a time is supported.
        - Concurrent secure connections
            - Maximum server certificate chain size has a limit of 4kB.
            - Two active connections are supported when serialized DTLS connection exists.
            - Two active connections are supported when client certificate size is over 1kB.
            - Two active connections are supported when GNSS acquisition is active.
            - Three active connections are supported when client certificate size is 1kB or less.
            - Four serialized DTLS connections are supported.
        - Server certificate expiry time is not verified.
        - pkcs#8 is not supported.
        - Maximum number of supported credentials is 32. The actual amount depends on size of
          credentials as memory area reserved for credentials may be a limiting factor as well.


    Thanks! 

    Kind regards,
    Øyvind

  • SDK 2.62, Modem firmware, 1.36.trace-2024-09-19T14-02-41.947Z.mtraceI am using an iBasis sim. I can successfully program the asset tracker V2 and connect to nrf could.

Reply Children
Related