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

HTTPS client over builtin TCP/IP fails unit tests, passes with no optimization #2838

Open
scaprile opened this issue Jul 22, 2024 Discussed in #2837 · 2 comments
Open

HTTPS client over builtin TCP/IP fails unit tests, passes with no optimization #2838

scaprile opened this issue Jul 22, 2024 Discussed in #2837 · 2 comments

Comments

@scaprile
Copy link
Collaborator

scaprile commented Jul 22, 2024

Discussed in #2837

Confirmed no Client Hello

@scaprile scaprile self-assigned this Jul 22, 2024
@scaprile scaprile changed the title no tls client hello message is being sent (TLS_BUILTIN over builtin TCP/IP) MQTTS client, TLS_BUILTIN over builtin TCP/IP (no tls client hello message is being sent) Jul 22, 2024
@scaprile scaprile changed the title MQTTS client, TLS_BUILTIN over builtin TCP/IP (no tls client hello message is being sent) TLS client over builtin TCP/IP fails unit tests (no tls client hello message is being sent) Jul 23, 2024
@scaprile
Copy link
Collaborator Author

Client Hello fixed in #2842

@scaprile scaprile changed the title TLS client over builtin TCP/IP fails unit tests (no tls client hello message is being sent) HTTPS client over builtin TCP/IP fails unit tests, passes with no optimization Jul 24, 2024
@scaprile
Copy link
Collaborator Author

scaprile commented Jul 24, 2024

The most noticeable case is with built-in TLS. Seems to work OK with MbedTLS
The very same test code passes with sockets on Linux, and with -O0. Tried disabling optimization only for test code and still fails, so it looks like a library bug. However, optimization seems to hide a TCP-related story.

Following capture file shows 4 failures in a row, 1 success, 1 failure, 1 success:
capture.zip
All failures have the disconnect notification piggybacked to the server response
First success: disconnect notification is on a separate frame
Second success: Wireshark shows a TCP segment reassembled from two frames, it is not clear where the disconnect notification starts.

Following capture file shows 5 successful connections in a row (built with -O0):
capture2.zip
In all cases, disconnect notification is on a separate frame

@scaprile scaprile removed their assignment Jul 24, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant