Re: How to compress LUKS v2 header?

Michael Kjörling <michael-/[email protected]>
Newsgroups gmane.linux.kernel.device-mapper.dm-crypt
Message-ID <4znhwwdjmp4rtw4jmrtp93xg@localhost>
On 26 Dec 2019 20:20 +0000, from [email protected] (Julio Cesar Faracco - [email protected]):
> I'm using `cryptsetup luksHeaderBackup /dev/sda2 --header-backup-file /tmp/backup.header`
> I used ZIP and GZIP, but I got 0% of reduction of `backup.header`. :-(
> Do you have any suggestions of what algorithm should be used to
> compress this type of file?

Why are you trying to compress the header backup in the first place?

As a general rule, encrypted data (such as the parts of the LUKS
header that aren't already random by design) does not compress well;
if data that has been encrypted can be compressed to any notable
degree, that usually means the encryption is somehow flawed, because
it's leaving patterns in the encrypted data. Properly encrypted data
should look completely random, which means that there's very little,
if anything, for compression utilities to find reducible patterns in.

-- 
Michael Kjörling • https://michael.kjorling.se • [email protected]
 “Remember when, on the Internet, nobody cared that you were a dog?”

_______________________________________________
dm-crypt mailing list
[email protected]
https://www.saout.de/mailman/listinfo/dm-crypt
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.