hi.
I found that current .netstandard 2.0 System.Net.WebSocket.ClientWebSocket has a critical bug.
(this affects all platform. windows,mac,ios,android etc…)
see details
“If WebSocket receive buffer splits message in the middle of UTF8 character error is thrown.”
https://github.com/dotnet/corefx/issues/29834
this is critical bug of .netcore System.Net.WebSocket.ClientWebsocket
(especially when server send non-latin utf8 text message, client throw error and disconnected)
.net core team already fixed this bug.
https://github.com/dotnet/corefx/pull/29840
but this PR was applied .netstandard 2.1 not .netstandard 2.0 (Unity use .netstandard 2.0)
The fix would be to pass header.Fin && header.PayloadLength == 0 into TryValidateUtf8 instead of passing header.Fin
(ReceveAsyncPrivate method in ManagedWebsocket class)
https://github.com/dotnet/corefx/issues/29834#issuecomment-390798318
Currently, solution I have found is that decompile & patch all System.dll (> 2mb) in Unity Editor folder using dnSpy tool, and use custom patched System.dll.
this is very annoying.
please, fix this bug.
regards.