All of lore.kernel.org
 help / color / mirror / Atom feed
* [dm-crypt] Bug in cryptsetup?
@ 2010-06-19 17:20 Si St
  2010-06-19 20:16 ` Heinz Diehl
  2010-06-19 21:50 ` Milan Broz
  0 siblings, 2 replies; 7+ messages in thread
From: Si St @ 2010-06-19 17:20 UTC (permalink / raw)
  To: dm-crypt

--cryptsetup version 1.0.3 , OS = SLED_10_SP3--

Upon this command:

cryptsetup luksDelKey 1 /dev/hda5

I receive this message:

WARNING!
========

This is the last keyslot. Device will become unusable after purging this key.

Are you sure? (Type uppercase yes):

But upon this command:

cryptsetup luksDelKey /dev/hda5 1

I receive only that I succeeded, and the actual Key in Slot 1 is disabled testing it with luksDump.

Of course I did not dare to proceed after the frightening message in the first place and exited with Ctrl-C.

Is there a bug here or is it just like the message explains. In this instance it is easy to mistake by putting the keyslot number in the front and proceed thinking that everything is okey.

Any good explanation here?

SS-NORWAY


-- 
_______________________________________________
Surf the Web in a faster, safer and easier way:
Download Opera 9 at http://www.opera.com

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: [dm-crypt] Bug in cryptsetup?
  2010-06-19 17:20 [dm-crypt] Bug in cryptsetup? Si St
@ 2010-06-19 20:16 ` Heinz Diehl
  2010-06-19 21:50 ` Milan Broz
  1 sibling, 0 replies; 7+ messages in thread
From: Heinz Diehl @ 2010-06-19 20:16 UTC (permalink / raw)
  To: dm-crypt

On 19.06.2010, Si St wrote: 

> Upon this command:
> cryptsetup luksDelKey 1 /dev/hda5
> I receive this message:
> 
> WARNING!
> ========
> 
> This is the last keyslot. Device will become unusable after purging this key.


I consider this a bug. The manpage says:

 luksKillSlot <device> <key slot number>
 wipe key with number <key slot> from LUKS device. A
 remaining passphrase or key file (via --key-file) must be supplied.

 luksDelKey <device> <key slot number>
 identical to luksKillSlot, but deprecated action name.

I think cryptsetup should have bailed out and exited,
because "1" is not a device.

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: [dm-crypt] Bug in cryptsetup?
  2010-06-19 17:20 [dm-crypt] Bug in cryptsetup? Si St
  2010-06-19 20:16 ` Heinz Diehl
@ 2010-06-19 21:50 ` Milan Broz
  2010-06-19 22:13   ` Arno Wagner
  1 sibling, 1 reply; 7+ messages in thread
From: Milan Broz @ 2010-06-19 21:50 UTC (permalink / raw)
  To: Si St; +Cc: dm-crypt

On 06/19/2010 07:20 PM, Si St wrote:
> --cryptsetup version 1.0.3 , OS = SLED_10_SP3--

Quite old version, it works for me in 1.1.2

> cryptsetup luksDelKey /dev/hda5 1
> 
> I receive only that I succeeded, and the actual Key in Slot 1 is disabled testing it with luksDump.

# cryptsetup luksDelKey 0 /dev/sde
luksDelKey is a deprecated action name.
Please use luksKillSlot.
Device 0 doesn't exist or access denied.

# cryptsetup luksDelKey /dev/sde 0
luksDelKey is a deprecated action name.
Please use luksKillSlot.

WARNING!
========
This is the last keyslot. Device will become unusable after purging this key.
...

# cryptsetup luksKillSlot /dev/sde 1
Key 1 not active. Can't wipe.

# cryptsetup --version            
cryptsetup 1.1.2


Can you reproduce it with recent version?
And I think we already found more problems with SLED10.

Milan

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: [dm-crypt] Bug in cryptsetup?
  2010-06-19 21:50 ` Milan Broz
@ 2010-06-19 22:13   ` Arno Wagner
  2010-06-19 22:26     ` Christoph Anton Mitterer
  0 siblings, 1 reply; 7+ messages in thread
From: Arno Wagner @ 2010-06-19 22:13 UTC (permalink / raw)
  To: dm-crypt

Added a warning to the FAQ.

Arno


On Sat, Jun 19, 2010 at 11:50:04PM +0200, Milan Broz wrote:
> On 06/19/2010 07:20 PM, Si St wrote:
> > --cryptsetup version 1.0.3 , OS = SLED_10_SP3--
> 
> Quite old version, it works for me in 1.1.2
> 
> > cryptsetup luksDelKey /dev/hda5 1
> > 
> > I receive only that I succeeded, and the actual Key in Slot 1 is disabled testing it with luksDump.
> 
> # cryptsetup luksDelKey 0 /dev/sde
> luksDelKey is a deprecated action name.
> Please use luksKillSlot.
> Device 0 doesn't exist or access denied.
> 
> # cryptsetup luksDelKey /dev/sde 0
> luksDelKey is a deprecated action name.
> Please use luksKillSlot.
> 
> WARNING!
> ========
> This is the last keyslot. Device will become unusable after purging this key.
> ...
> 
> # cryptsetup luksKillSlot /dev/sde 1
> Key 1 not active. Can't wipe.
> 
> # cryptsetup --version            
> cryptsetup 1.1.2
> 
> 
> Can you reproduce it with recent version?
> And I think we already found more problems with SLED10.
> 
> Milan
> _______________________________________________
> dm-crypt mailing list
> dm-crypt@saout.de
> http://www.saout.de/mailman/listinfo/dm-crypt
> 

-- 
Arno Wagner, Dr. sc. techn., Dipl. Inform., CISSP -- Email: arno@wagner.name 
GnuPG:  ID: 1E25338F  FP: 0C30 5782 9D93 F785 E79C  0296 797F 6B50 1E25 338F
----
Cuddly UI's are the manifestation of wishful thinking. -- Dylan Evans

If it's in the news, don't worry about it.  The very definition of 
"news" is "something that hardly ever happens." -- Bruce Schneier 

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: [dm-crypt] Bug in cryptsetup?
  2010-06-19 22:13   ` Arno Wagner
@ 2010-06-19 22:26     ` Christoph Anton Mitterer
  2010-06-20 19:54       ` Arno Wagner
  0 siblings, 1 reply; 7+ messages in thread
From: Christoph Anton Mitterer @ 2010-06-19 22:26 UTC (permalink / raw)
  To: dm-crypt

[-- Attachment #1: Type: text/plain, Size: 1041 bytes --]

Hi Arno.

Nice to see that you've used a separate section for legacy stuff in the
FAQ :)

I guess for something like crpytsetup (with its active development and
changes to crypto theory) it's important for a FAQ that it's really
always up to date and double checked for correctness by the developers.

Therefore, may I suggest to add information to each FAQ point for/during
which version of cryptsetup it was created?
Of course this would required to check all entries again when a new
version comes out (whether they still are correct) and update the
version info.


btw: May I suggest to add the questions I put up here some weeks ago ...
about which is the "securest" algo, keysizes when using XTS,
essiv/benbi/plain when using XTS, how the masterkey is generated
using /dev/urandom (at least currently) and that one should not manually
use /dev/random as Milan said, etc.

It may also be nice to add that LRW is insecure, at least this is the
case AFAIK, and that therefore XFS was created.


Cheers,
Chris.

[-- Attachment #2: smime.p7s --]
[-- Type: application/x-pkcs7-signature, Size: 3387 bytes --]

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: [dm-crypt] Bug in cryptsetup?
  2010-06-19 22:26     ` Christoph Anton Mitterer
@ 2010-06-20 19:54       ` Arno Wagner
  0 siblings, 0 replies; 7+ messages in thread
From: Arno Wagner @ 2010-06-20 19:54 UTC (permalink / raw)
  To: dm-crypt

Hi Chris

I think adding a trace to each FAQ article is overkill.
I also do not expect to put a lot into the version specific 
section. 

While the FAQ should be correct, current, etc. it is 
significantly better to have one that is actually there than 
one that is overengineered enought that it never gets written.
I also think that I do a pretty good job of checking what I 
put in there without being one of the developers...

As to the security questions you raidse, you are welcome to
contribute the relevant articles to the FAQ, just send them 
to me or to wait until I find the time to add them. Could 
take a while thogh.

Arno




On Sun, Jun 20, 2010 at 12:26:15AM +0200, Christoph Anton Mitterer wrote:
> Hi Arno.
> 
> Nice to see that you've used a separate section for legacy stuff in the
> FAQ :)
> 
> I guess for something like crpytsetup (with its active development and
> changes to crypto theory) it's important for a FAQ that it's really
> always up to date and double checked for correctness by the developers.
> 
> Therefore, may I suggest to add information to each FAQ point for/during
> which version of cryptsetup it was created?
> Of course this would required to check all entries again when a new
> version comes out (whether they still are correct) and update the
> version info.
> 
> 
> btw: May I suggest to add the questions I put up here some weeks ago ...
> about which is the "securest" algo, keysizes when using XTS,
> essiv/benbi/plain when using XTS, how the masterkey is generated
> using /dev/urandom (at least currently) and that one should not manually
> use /dev/random as Milan said, etc.
> 
> It may also be nice to add that LRW is insecure, at least this is the
> case AFAIK, and that therefore XFS was created.
> 
> 
> Cheers,
> Chris.



> _______________________________________________
> dm-crypt mailing list
> dm-crypt@saout.de
> http://www.saout.de/mailman/listinfo/dm-crypt


-- 
Arno Wagner, Dr. sc. techn., Dipl. Inform., CISSP -- Email: arno@wagner.name 
GnuPG:  ID: 1E25338F  FP: 0C30 5782 9D93 F785 E79C  0296 797F 6B50 1E25 338F
----
Cuddly UI's are the manifestation of wishful thinking. -- Dylan Evans

If it's in the news, don't worry about it.  The very definition of 
"news" is "something that hardly ever happens." -- Bruce Schneier 

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: [dm-crypt] Bug in cryptsetup?
@ 2010-06-20 12:54 Si St
  0 siblings, 0 replies; 7+ messages in thread
From: Si St @ 2010-06-20 12:54 UTC (permalink / raw)
  To: dm-crypt

I could try some newer version of cryptsetup if they will install. You probably remember that we tried out som debugging with cryptsetup 1.1.1 on my SLED_10, the apitest. The conclusion was that that an SLED_10 used a different patch....:
(excerpt from MilanBroz' returnmail):
--BEGIN
"> 0 18968 crypt cbc(aes)-cbc-essiv:sha256 
> 00000000000000000000000000000000 0 7:5 1032
> cipher: cbc(aes)-cbc-essiv:sha256

Great! thanks. Seems SuSe have some non-standard patch applied here,"
--END

But this might not apply to your question(?)
I have taken care of all the emails concerning this matter:apitest

But I could also try out this on my new SLED_11_SP1. Havent checked into the cryptsetup there,yet.
Let me hear from you in case.

SS

/* OFFTOPIC; To Heinz Diehl:Thanks for your answer, Heinz Diehl!) */

SS-NORWAY
---------------------------------------------------------------------


> ----- Original Message -----
> From: Milan Broz <mbroz@redhat.com>
> To: Si St <sigbj-st@operamail.com>
> Cc: dm-crypt@saout.de
> Subject: Re: [dm-crypt] Bug in cryptsetup?
> Date: Sat, 19 Jun 2010 23:50:04 +0200
> 
> 
> On 06/19/2010 07:20 PM, Si St wrote:
> > --cryptsetup version 1.0.3 , OS = SLED_10_SP3--
> 
> Quite old version, it works for me in 1.1.2
> 
> > cryptsetup luksDelKey /dev/hda5 1
> >
> > I receive only that I succeeded, and the actual Key in Slot 1 is 
> > disabled testing it with luksDump.
> 
> # cryptsetup luksDelKey 0 /dev/sde
> luksDelKey is a deprecated action name.
> Please use luksKillSlot.
> Device 0 doesn't exist or access denied.
> 
> # cryptsetup luksDelKey /dev/sde 0
> luksDelKey is a deprecated action name.
> Please use luksKillSlot.
> 
> WARNING!
> ========
> This is the last keyslot. Device will become unusable after purging this key.
> ...
> 
> # cryptsetup luksKillSlot /dev/sde 1
> Key 1 not active. Can't wipe.
> 
> # cryptsetup --version
> cryptsetup 1.1.2
> 
> 
> Can you reproduce it with recent version?
> And I think we already found more problems with SLED10.
> 
> Milan

>


-- 
_______________________________________________
Surf the Web in a faster, safer and easier way:
Download Opera 9 at http://www.opera.com

^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2010-06-20 19:54 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2010-06-19 17:20 [dm-crypt] Bug in cryptsetup? Si St
2010-06-19 20:16 ` Heinz Diehl
2010-06-19 21:50 ` Milan Broz
2010-06-19 22:13   ` Arno Wagner
2010-06-19 22:26     ` Christoph Anton Mitterer
2010-06-20 19:54       ` Arno Wagner
2010-06-20 12:54 Si St

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.