-
Notifications
You must be signed in to change notification settings - Fork 6.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
LWM2M bootstrap with dtls fails when using HL7800 modem #81672
Comments
@jbr-ia I will take a look at this when I can. In the mean time, check these kconfigs, these are the values we use:
|
@rerickson1 Thanks for the reply. I have tested it with these values, but unfortunatelly it still does not work for me. For this test, I tried without bootstrapping this time, so compiling with:
It still failed to connect. When I change in hl7800.c Lines 1606 to 1607 in 7271000
to this:
than it works for me with dtls and dns. But this only works because I use 8.8.8.8 as DNS-server, and the IP-address seems to be at this location in the sock->dst.data, so if the DNS-server ever changes it no longer works. So this is no real solution (only for testing). |
@jbr-ia can you provide the debug logs from boot until the issue happens? |
@rerickson1 Attached the log of the failing connection (pinnacle_100_dvk_dtls_failed_to_connect.txt). This is with zephyr revision: 6843240, with added to prj.conf:
compiled with: For comparison also a log with a successfull connection (pinnacle_100_dvk_dtls_successfull_connect.txt). For that situation, I added the if-statement with hardcoded dns-entry from my previous comment. pinnacle_100_dvk_dtls_failed_to_connect.txt |
@jbr-ia I have made some progress. I see TLS issues and dont think there is anything wrong with the HL7800 driver. Using latest main zephyr branch, apply this diff: Build command: logs and pcap: For some reason MBED TLS is not processing the received |
Thanks for looking into it. I also see that MBED TLS seems to not process the reaction from the server correctly. When I remove in hl7800.c the lines with
, than mbedtls seems to accept the response (but DNS does not work anymore). Therefore my assumption was that it had something to do with the modemdriver. But it can also be something in mbedtls, or another part of the networkstack. |
Thanks for the reminder on that, I'll give that a try too. |
Describe the bug
Using lwm2m with dtls and preshared keys fails when using the HL7800 modemdriver.
I am trying to use lwm2m with dtls and preshared keys with an HL7800 modem. The DTLS handshake does not succeed. This seems to be the case since commit: 7bef3fd
When I undo the change of that commit, the dtls handshake can succeed, but DNS does not work anymore (that commit fixes DNS problems), so I need to specify the IP-address of the lwm2m-bootstrap server instead of the dns-name.
To Reproduce
Steps to reproduce the behavior:
west build -b pinnacle_100_dvk samples/net/lwm2m_client/ -- -DOVERLAY_CONFIG="overlay-lwm2m-1.1.conf;overlay-bootstrap.conf;overlay-dtls.conf"
west flash
Expected behavior
A successfull connection to the bootstrapserver with dtls (with preshared keys)
Logs and console output
In zephyr I see that lwm2m_engine reports Cannot connect UDP (-11)
In wireshark, I see repeated attempts to start a handshake
Environment (please complete the following information):
Additional context
The text was updated successfully, but these errors were encountered: