All of lore.kernel.org
 help / color / mirror / Atom feed
From: Matthias Schniedermeyer <ms@citd.de>
To: yakamo <yakamo@drahony.com>
Cc: dm-crypt@saout.de
Subject: Re: [dm-crypt] luks header
Date: Wed, 7 Jan 2015 12:31:38 +0100	[thread overview]
Message-ID: <20150107113138.GA7265@citd.de> (raw)
In-Reply-To: <20150106192300.2f61d3770e06705a9a52afc1@drahony.com>

On 06.01.2015 19:23, yakamo wrote:
> can you recommend an effective way to remove the luks header?
> i have tried cryptsetup luksFormat /dev/xxx --header ~/headerfile align-payload=0 but this still writes a header to the encrypted drive, is meant to happen?

From the man-page of a new enough version of cryptsetup:
- snip -
       erase <device>
       luksErase <device>

              Erase all keyslots and make the LUKS container permanently inaccessible.  You do not need to provide any password for this operation.

              WARNING: This operation is irreversible.
- snip -
Altough the warning is only 99% true, restoring a Header-Backup makes 
the device accessible again, but you would need to have made a Backup 
beforehand.

or just
dd if=/dev/zero of=/dev/<device> bs=1M count=100
Which erases the first 100MB of said device, the LUKS-Header is only a 
fraction of that, so this command also damages the data/filesystem 
inside the container!

For total erasure of the device/patition kjust leave out "count=100" and



-- 

Matthias

      reply	other threads:[~2015-01-07 11:31 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-01-06 19:23 [dm-crypt] luks header yakamo
2015-01-07 11:31 ` Matthias Schniedermeyer [this message]

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=20150107113138.GA7265@citd.de \
    --to=ms@citd.de \
    --cc=dm-crypt@saout.de \
    --cc=yakamo@drahony.com \
    /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.