Servers didn't propagate exceptions in handler code to the client.
System.IO.BufferedStream inside this transport made it strongly tied to underlying transport's stream state.
More concretely, when used on top of TTLSSocket it crashed because underlying SslStream is disposed by the socket while BufferedStream kept trying to touch the disposed stream after that.
So I removed BufferedStream and made it use System.IO.MemoryBuffer instead.
- Can now work on top of TTLSSocket
- Underlying transport no longer needs to be a TStreamTransport
It was allocating new MemoryBuffer for nealy every write and read of frames.
I made it allocate only once.
- Can now handle Base64 with padding for binary fields (Fixes C# part of
- Make client certificate optional
With this patch applied, all the cross test apps should be mostly valid.
- Fix SSL setup
- Semantic return code
- Add testException and testMultiException
- Add missing assertions