dahomey-technologies/Dahomey.Cbor

.net core Web API input request ReadAsync executed wrong

cemlee-84 opened this issue · 3 comments

in a specific case in .net core Web API reading the stream on deserialize is changing first byte value 164 (map size 4) to 161 (map size 1). The problem is in StreamExtension.cs ReadAsync methods.
The input stream must be CanSeek = false.
I suppose it is reproducible for streams bigger than 256
second problem - only first 256 bytes are read, the rest are empty.
Thank you

@cemlee-84 Could provide a code sample with your specific case, please?

ok, I managed to reproduice it!

@mcatanzariti Thank you !