From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from pio-pvt-msa1.bahnhof.se (pio-pvt-msa1.bahnhof.se [79.136.2.40]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by mail.server123.net (Postfix) with ESMTPS for ; Thu, 26 Dec 2019 22:38:44 +0100 (CET) Received: from localhost (localhost [127.0.0.1]) by pio-pvt-msa1.bahnhof.se (Postfix) with ESMTP id 5345740737 for ; Thu, 26 Dec 2019 22:38:43 +0100 (CET) Received: from pio-pvt-msa1.bahnhof.se ([127.0.0.1]) by localhost (pio-pvt-msa1.bahnhof.se [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id gnaq7kuGai-S for ; Thu, 26 Dec 2019 22:38:42 +0100 (CET) Received: from localhost (unknown [85.24.253.35]) (Authenticated sender: mc616801) by pio-pvt-msa1.bahnhof.se (Postfix) with ESMTPA id 3CE1B40734 for ; Thu, 26 Dec 2019 22:38:42 +0100 (CET) Received: from localhost (localhost [127.0.0.1]) by localhost (Postfix) with ESMTPS id A568B2E02DA for ; Thu, 26 Dec 2019 22:38:41 +0100 (CET) Date: Thu, 26 Dec 2019 21:38:40 +0000 From: Michael =?utf-8?B?S2rDtnJsaW5n?= Message-ID: <4znhwwdjmp4rtw4jmrtp93xg@localhost> References: MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: Subject: Re: [dm-crypt] How to compress LUKS v2 header? List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: dm-crypt@saout.de On 26 Dec 2019 20:20 +0000, from jfaracco@br.ibm.com (Julio Cesar Faracco - jfaracco@br.ibm.com): > 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 • michael@kjorling.se “Remember when, on the Internet, nobody cared that you were a dog?”