Skip to content

The message received was unexpected or badly formatted. #2411

Discussion options

You must be logged in to vote

@seanmonstar I didn't find any conclusive thing for this error on Windows. If I understand correctly it's a problem with the TLS handshake between the client/server.
Knowing this, I looked at the features flags for the Reqwest crate and I tried different settings.

  • default-tls does not work
  • native-tls does not work either
  • rustls-tls works !

I can make it work with rustls feature and the use_rustls_tls() in ClientBuilder. I don't really know what rustls is doing behind the scenes for this behaviour to happen.

Thanks for the great library and have a good day !

Replies: 2 comments

Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Answer selected by SauvageThomas
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants
Converted from issue

This discussion was converted from issue #2409 on September 08, 2024 12:07.