[dm-crypt] Restore LUKS partition
arno at wagner.name
Thu Dec 15 23:27:33 CET 2016
So you have the master-key? In that case, most data should be
recoverable. First, you need to recreate the partition entry
at the right place and then you can use the procedure described
in FAQ-Item 6.10 to create a new header.
The FAQ is here:
The trick would be to put the partition start at the right
place. If your device is still mapped, then there should
be some way to dump the partition table as the kernel currently
sees it though.
If it was indeed sdb1, then the start is probably at 1MB
from the beginning.
On Thu, Dec 15, 2016 at 22:37:53 CET, Sven Eschenberg wrote:
> In case the first partition was encrypted, you won't stand a chance
> in restoring it, since the first partition starts on sector 2048
> (1MByte from the bstart of the device). For obvious reasons the
> header would be gone and certainly some important parts of the FS.
> If your encrypted partition was 8,17, as your data suggests, then
> the first partition was encrypted and is thus severly damaged.
> So, if you do not have a header backup of the drives masterkey at
> hand, then this is a goner.
> Am 15.12.2016 um 21:36 schrieb Oskar Jauch:
> >I've accidentally overwritten the first 1.1 GB of my external hard drive
> >with dd. As far as I remember the drive contained two partitions from
> >which one was encrypted with LUKS. I'm not sure if the encrypted one was
> >the first or the second one...
> >I dumped the hole disc with ddrescue.
> >I was able to extract the following from my laptop:
> >luks-afe73a24-e4ab-4d49-90b9-119da11bc7c6: 0 5860526990 crypt
> >aes-xts-plain64 [key (don't want to share it in this mail)] 0 8:17 4096
> >Is there any possibility to restore anything of the encrypted data?
> >Thank you in advance!
> >dm-crypt mailing list
> >dm-crypt at saout.de
> dm-crypt mailing list
> dm-crypt at saout.de
Arno Wagner, Dr. sc. techn., Dipl. Inform., Email: arno at wagner.name
GnuPG: ID: CB5D9718 FP: 12D6 C03B 1B30 33BB 13CF B774 E35C 5FA1 CB5D 9718
A good decision is based on knowledge and not on numbers. -- Plato
If it's in the news, don't worry about it. The very definition of
"news" is "something that hardly ever happens." -- Bruce Schneier
More information about the dm-crypt