ARTICLE AD BOX
A simple client/server (both C# and running on same machine, win11) works fine on .Net 9, but not on .Net 10.
When the client calls AuthenticateAsClient(serverHostname) a System.IO.IOException is thrown with the message "Received an unexpected EOF or 0 bytes from the transport stream". This doesn't happen if targeting .Net 9.
Calling the async version gives exact same result.
Anyone got a clue?
1781 gold badge3 silver badges12 bronze badges
9

We can't guess what's going on without any code, or at least the full exception text, not just the message. There may be an inner exception that explains what happened. Or the server may have crashed and closed the connection. If TLS was broken in .NET 10, HTTPS itself would break as well. Nor is .NET 10 new - it's been in development and very widespread testing for quite a while, especially in web apps and services
2025-11-27 14:25:45 +00:00
Commented 4 hours ago
As header states TCP client/server, I implied (or thought so) that https is not involved, just a simple SslStream which is used to AuthenticateAsClient(serverHostname). There was no inner exception at all. Perhaps the origin of trouble is on the server side? Did .Net 10 "require more" from the certificate(s). I could post the whole solution (just a few lines anyway), but worry a bit about exposing the certificate's private key.
2025-11-27 14:31:52 +00:00
Commented 4 hours ago
Post your code and the full exception instead of trying to describe it, or assume something already used by hundreds, if not thousands of developers is broken. You shouldn't have to disable TLS1.2 on Windows 11 anyway. Windows 10 didn't support it but Windows 11 does. Trying to restrict the TLS version could cause the problem.
2025-11-27 14:37:13 +00:00
Commented 4 hours ago
System.IO.IOException HResult=0x80131620 Message=Received an unexpected EOF or 0 bytes from the transport stream. Source=System.Net.Security
2025-11-27 14:37:41 +00:00
Commented 4 hours ago
Edit the question and add the information there. And post your code.
2025-11-27 14:39:07 +00:00
Commented 4 hours ago