From: Robert Nichols <rnicholsNOSPAM@comcast.net>
To: dm-crypt@saout.de
Subject: Re: [dm-crypt] Broken LUKS header
Date: Wed, 03 Sep 2014 09:56:40 -0500 [thread overview]
Message-ID: <lu7a79$6e8$1@ger.gmane.org> (raw)
In-Reply-To: <BLU184-W956C554A2837B7CB6A0EDDE8C40@phx.gbl>
On 09/03/2014 04:03 AM, Andreas Aßmann wrote:
> A few days ago, I tried to add a key file to all three volumes using 'cryptsetup
> luksAddKey'. The command succeeded for sda2 and sda3. Adding the key file to
> sdb1, however, failed with 'Invalid Key Slot 6, Invalid Key Slot 7'. It seems
> the LUKS header of sdb1 was corrupted in the process. Probing the header using
> 'cryptsetup luksDump' fails with the same error message.
>
> Fortunately, sdb1 was unlocked and mounted when this happened - I was still able
> to access data on this volume and from what I've seen, everything is still
> intact, so I created a complete backup right away using rsync. However, I would
> feel much better if I could repair the header to verify that the backup I made
> actually contains all data from sdb1.
>
> I also created a 1:1 backup of sdb1 using dd. On this backup, I tried
> 'keyslot_checker' and 'cryptsetup repair'. The first didn't work at all, the
> latter reported invalid offsets for key slots 6 and 7 and fixed them. However, I
> was unable to open the volume using my normal passphrase afterwards, so that
> didn't work out as expected.
Do you still have sdb1 unlocked? If so, you can recover the master key and
also make a backup image of the decrypted volume. Instructions for recovering
the master key are in section 6.10 of the Cryptsetup FAQ at
<http://code.google.com/p/cryptsetup/wiki/FrequentlyAskedQuestions>
To save an image of the decrypted volume just use dd to copy the
/dev/mapper/xxx device to a file somewhere.
--
Bob Nichols "NOSPAM" is really part of my email address.
Do NOT delete it.
next prev parent reply other threads:[~2014-09-03 14:56 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-09-03 9:03 [dm-crypt] Broken LUKS header Andreas Aßmann
2014-09-03 11:32 ` Arno Wagner
2014-09-03 14:56 ` Robert Nichols [this message]
-- strict thread matches above, loose matches on Subject: below --
2014-09-03 9:00 Andreas Aßmann
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to='lu7a79$6e8$1@ger.gmane.org' \
--to=rnicholsnospam@comcast.net \
--cc=dm-crypt@saout.de \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.