Return-Path: Received: from v6.tansi.org (ns.km31936-01.keymachine.de [87.118.116.4]) by mail.server123.net (Postfix) with ESMTP for ; Sat, 26 Sep 2015 01:03:10 +0200 (CEST) Received: from gatewagner.dyndns.org (77-57-54-224.dclient.hispeed.ch [77.57.54.224]) by v6.tansi.org (Postfix) with ESMTPA id 6B4EB34FA001 for ; Sat, 26 Sep 2015 01:03:10 +0200 (CEST) Date: Sat, 26 Sep 2015 01:03:09 +0200 From: Arno Wagner Message-ID: <20150925230309.GA27051@tansi.org> References: <20150925173316.GA32719@manjaro.chello.hu> <20150925194446.GZ14230@yeono.kjorling.se> <20150925214834.GA5103@manjaro.chello.hu> <20150925222410.GD14230@yeono.kjorling.se> MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Disposition: inline Content-Transfer-Encoding: quoted-printable In-Reply-To: <20150925222410.GD14230@yeono.kjorling.se> Subject: Re: [dm-crypt] Basics List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: dm-crypt@saout.de On Sat, Sep 26, 2015 at 00:24:10 CEST, Michael Kj=F6rling wrote: > On 25 Sep 2015 23:48 +0200, from promike1987@gmail.com (Mike Nagie): > > I'll probably use this command: > > cryptsetup -v --cipher aes-xts-plain64 --key-size 512 --hash sha512 (or= =20 > > an other one I haven't decided yet) --iter-time (about) 2000 (I'm=20 > > generous, about 2 secs seems fine) --use-random >=20 > Looks reasonable, except you forgot to pass "luksFormat" and a device > to cryptsetup, so it won't know what to do with the rest. :-) (Oh, and > note that as discussed here previously, the problems with SHA-1 > leading to its current sunsetting don't affect its usage in LUKS. In > fact, I'd expect that for LUKS' purposes, even MD5 would still be a > secure choice, if perhaps somewhat... unusual.) It would be. And it will likely remain so for a long, long time. Remember that the problems with SHA-1 and MD5 are collisions, not has-reversing. Well, a collision for the use in LUKS means that if you already have a valid passphrase, you can make=20 another one. That does not break LUKS security at all. Also keep in mind, that only non-iterated SHA-1 and MD5 are vulnerable to this attack. While I am not aware of anybody having investigates it, I think it is possible that SHA-1 and MD5 even iterated 2x is secure again against collisions, as collision attacks are usually tried first against reduced round version of a hash. LUKS uses around 10'000 iterations for checking the master key and=20 around 400'000 iteratiosn for the passphrase. Of course, using SHA512 should not make sings weaker, but it also does not make things any more secure. As a side-note: It is not a good idea to tinker with crypto- parameters unless you are an expert. A lot of things are non-obvious and sometimes you will end up breaking things when you think you make them more secure. =20 > If you want additional security against forensic analysis, a good > strategy might be to set up a LUKS container with a throwaway > passphrase and key, and then "dd" or "ddrescue" zeroes into it, then > create your real LUKS container in place of the throwaway one. That > will ensure that any remnants of old data are gone, and will prevent > forensic analysis based around which parts of the container appear to > hold encrypted data. In other words: That is excessive effort. Just do what FAQ Item 2.19 says. Regards, Arno --=20 Arno Wagner, Dr. sc. techn., Dipl. Inform., Email: arno@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=20 "news" is "something that hardly ever happens." -- Bruce Schneier