oreocw.blogg.se

Web base64 encoding
Web base64 encoding











web base64 encoding

We were hoping that someone could provide some information or guidance that could help to identify what might be going on.įor reference, here is the. Base64 is an encoding method that uses 7-bit printable ASCII characters. We’ve also tested the same server with a C# client standing in for the grpc-web client and have not observed the same errors. Base64 encoding is commonly used when there is a need to transmit binary data over media that do not correctly handle binary data and is designed to deal with textual data belonging to the 7. It represents binary data in a printable ASCII string format by translating it into a radix-64 representation. It usually takes several sequences of image file transmissions before the error starts happening, with the total being around several hundreds of MB of image data (~1mb at a time), and we’re closing and reopening the client/server connection between each sequence. Base64 is a binary-to-text encoding scheme.

web base64 encoding

It would seem that something is corrupting the base64 encoded data that the grpc-web client is receiving but we haven’t been able to determine where this corruption may be coming from. The area highlighted in grey is where the data received by the grpc-web client starts to diverge from the data that the gRPC service had sent and eventually the unknown base64 character shows up in the data on the left: Below is a comparison of the base64 encoded data that is received by the grpc-web client on the left and what the gRPC service had sent on the right. When this unknown base64 error occurs, all subsequent images sent from the gRPC service will no longer be displayed in the grpc-web browser client.įurther analysis of the base64 encoded data from what the gRPC service is sending to what is displayed in the Chrome console when the issue occurs indicates that the base64 data is correct for a while, but then starts to diverge until the unknown base64 encoded character is encountered. Occasionally there is an uncaught error that shows up in the Chrome console that has the following message: “Uncaught Error: Unknown base64 encoding at char:”, followed by another error that reads: “Error: The stream is broken Error: invalid frame byte. We have a C# Grpc.AspNetCore version 2.27.0 service that sends image data to a grpc-web client using grpc-web version 1.3.1 and google-protobuf version 3.14.0, to an AngularJS application running in a Chrome browser that displays images on the page as they are sent from the gRPC service.













Web base64 encoding