Looks like [`System.Net.WebSockets.ManagedWebSocket.WriteFrameToSendBuffer`](https://github.com/dotnet/corefx/blob/b835f230039c4f44944b7fb3f8ce670ebf578ea4/src/System.Net.WebSockets.Client/src/System/Net/WebSockets/ManagedWebSocket.cs#L448) fails to actually write the payload if `_isServer` is set. It copies the payload into the send buffer in the same if-branch that handles masking (which is client-only :smile:). Discovered and fixed this while porting code to ASP.NET, so I'm going to port the fix over to corefx and open a PR. /cc @stephentoub @Tratcher