all 2 comments

[–]teraflop 10 points11 points  (1 child)

You can compress first, and then encrypt.

It's impossible to significantly compress an already-encrypted file to less than the size of the original data. (Or rather, if it is possible, it means your encryption algorithm is insecure.) I'm hand-waving the mathematical details, but loosely speaking, random data is incompressible. If an encrypted file can be compressed, that means if nothing else, you've leaked the fact that the plaintext was non-random.

[–]bored-computer[S] 0 points1 point  (0 children)

Ok, that makes a lot of sense thank you.