Skip to content
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

Accept() error in secure sockets. #71525

Closed
Nulllix opened this issue Apr 15, 2024 Discussed in #66405 · 3 comments
Closed

Accept() error in secure sockets. #71525

Nulllix opened this issue Apr 15, 2024 Discussed in #66405 · 3 comments

Comments

@Nulllix
Copy link

Nulllix commented Apr 15, 2024

Discussed in #66405

Originally posted by Nulllix December 11, 2023

Introduction

Hey, everybody!
I have an nRF52840-DK debug board on which I am trying to run BSD Secure Sockets on up the IPSP.
I used the echo server (advanced) example as a basis.
My code on which the problem is stably reproduced is here.

Problem

I have written a small python script that I'm trying to use to connect to my server. When I try to connect to nRF52840 with it, HardFault occurs in accept(...) function:
image
I have enabled additional logs inside the bluetooth stack and as you can see, at some point the pointer to user_data takes an invalid value.

Callstack which leads to HardFault:
image

Using a debugger I was able to get the full callstask which causes this error (inside bt_conn_send_cb(...) the functions you see in the screenshot above are called):

BIG SCREENSHOTS WITH CALLSTACK

The full log with the error and callstack in text form, can be found here.

How to reproduce?

  1. Clone my repository.
  2. Build and load firmware to nRF52840 from it.
  3. Connect BLE adapter to PC (i use TL-LINK UB400)
  4. Use script board_connect.sh to activate the 6lowpan and connect it to the board.
  5. Use python script test_conn.py to connect to the sockets.

Has anyone ever encountered anything like this?

Copy link

Hi @Nulllix! We appreciate you submitting your first issue for our open-source project. 🌟

Even though I'm a bot, I can assure you that the whole community is genuinely grateful for your time and effort. 🤖💙

@jukkar
Copy link
Member

jukkar commented Apr 15, 2024

Note that IPSP support was just recently removed from upstream Zephyr. There were lot of issues with it, not sure if they were related to the issue you are seeing.
See for example #68629 and #68627 for more details.

@Nulllix
Copy link
Author

Nulllix commented Apr 16, 2024

@jukkar Thanks for the info.

@Nulllix Nulllix closed this as completed Apr 16, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants