Home > Back-end >  Zlib compression decompression failed success
Zlib compression decompression failed success

Time:09-16

Zlib, reading data from the file compression (compression is successful, the compressed size is 80), by the client to the server after the data change, size of 87, what reason cause the failure of decompression, you know?
This is the client, to compress the data, packaged in json send


This is the service side, unscramble the json data, and then extract, extract the fails, an error is that the data is damaged

CodePudding user response:


Binary base64 at least once,

CodePudding user response:

reference 1st floor smwhotjay response:

Binary base64 at least once,

First is encrypted and then compressed? Or compressed in the encryption

CodePudding user response:

refer to the second floor manjaro21 response:
Quote: refer to 1st floor smwhotjay response:

Binary base64 at least once,

First is encrypted and then compressed? Or compress the encryption
since be cleartext, it must be compressed to do coding, the service side received after decoding to extract the cough up,

CodePudding user response:

refer to fish out of water reply: 3/f
Quote: refer to the second floor manjaro21 response:
Quote: refer to 1st floor smwhotjay response:

Binary base64 at least once,

First is encrypted and then compressed? Or compressed in the encryption
since be cleartext, it must be compressed to do coding, the service side received after decoding to extract,

Ok thank you requested

CodePudding user response:

Compress - & gt; Base64 encode==& gt; Recv==& gt; Base64 decode==& gt; uncompress

CodePudding user response:

reference 5 floor smwhotjay reply:
compress - & gt; Base64 encode==& gt; Recv==& gt; Base64 decode==& gt; Uncompress

Bosses have any recommendation algorithm of base64 code I just found a use up decompression or failure

CodePudding user response:

Has been resolved thank you
  • Related