From: Mistave <mistave@countermail.com>
To: dm-crypt@saout.de
Subject: Re: [dm-crypt] Basics
Date: Fri, 25 Sep 2015 19:55:15 +0200 [thread overview]
Message-ID: <56058A83.9070509@countermail.com> (raw)
In-Reply-To: <20150925173316.GA32719@manjaro.chello.hu>
Generally I use the following line:
# cryptsetup -c aes-xts-plain64:sha512 -h sha512 -y -s 512 -i 5000
--use-random luksFormat /dev/sdX
But AES should be faster, if your CPU supports AES-IN instruction (most
modern CPU's should). Though you are free to choose whatever cipher you
prefer (aes, twofish, serpent). On my PC AES (software) is a bit faster
than serpent and a bit slower than twofish. AES (hardware is fastest).
On 25. 09. 2015 19:33, Mike Nagie wrote:
> Hi all,
>
> I'm going to reinstall my ArchLinux and I thought I would try encrypting
> my home folder with dm-crypt.
> I read this and ArchWiki several times, but I'm still so confused.
> I'd like to keep my system as fast as just possible, sooo here is my
> benchmark results:
>
> PBKDF2-sha1 644088 iterations per second
> PBKDF2-sha256 391259 iterations per second
> PBKDF2-sha512 321254 iterations per second
> PBKDF2-ripemd160 410241 iterations per second
> PBKDF2-whirlpool 151703 iterations per second
> # Algorithm | Key | Encryption | Decryption
> aes-cbc 128b 124.2 MiB/s 143.3 MiB/s
> serpent-cbc 128b 49.9 MiB/s 194.5 MiB/s
> twofish-cbc 128b 112.4 MiB/s 211.2 MiB/s
> aes-cbc 256b 96.4 MiB/s 107.1 MiB/s
> serpent-cbc 256b 49.9 MiB/s 194.2 MiB/s
> twofish-cbc 256b 112.4 MiB/s 210.9 MiB/s
> aes-xts 256b 141.5 MiB/s 143.3 MiB/s
> serpent-xts 256b 201.1 MiB/s 191.4 MiB/s
> twofish-xts 256b 207.9 MiB/s 209.1 MiB/s
> aes-xts 512b 108.5 MiB/s 106.2 MiB/s
> serpent-xts 512b 200.1 MiB/s 191.5 MiB/s
> twofish-xts 512b 207.8 MiB/s 209.3 MiB/s
>
> So first thing; this is a 1TiB HDD. Do I need plain64? Or is there any
> drawbacks?
>
> Second: Everybody talks about the aes. It seems the twofish is faster
> here. Does this really matters? I mean this is a HDD, I guess it never
> does anything at that pace. (207MiB/s)
>
> Third: Since xts is supposed to be safer I think it's justified.
>
> Fourth: Key size I'm totally lost. Why 512b (even though it's splitted
> to 256) faster than the others? I'm sure something is not right with my theory
> else who would use 256b?! Do encrypted files bigger with 512b or
> what is the point here?
>
> Fifth: Hash: I'm thinking about sha256.
>
> Sixth: iteration time. I misunderstood the benchmark. I thought
> sha256 391259 iterations per second
> means 391259 iterations per second. However I set the iteration time to
> 391259 and well... it needless to say, it didn't open the encrypted
> partition in a second, more like in 10 minutes. So I have no idea how
> should I interpret this one.
>
> And lastly: --use-random or --use-urandom. I didn't get this one at all.
>
> Thank you for your answer in advance
>
> Mike
>
next prev parent reply other threads:[~2015-09-25 17:55 UTC|newest]
Thread overview: 33+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-09-25 17:33 [dm-crypt] Basics Mike Nagie
2015-09-25 17:55 ` Mistave [this message]
2015-09-25 19:44 ` Michael Kjörling
2015-09-25 19:48 ` Michael Kjörling
2015-09-25 21:48 ` Mike Nagie
2015-09-25 22:24 ` Michael Kjörling
2015-09-25 23:03 ` Arno Wagner
2015-09-26 7:14 ` Mike Nagie
2015-09-26 7:32 ` Mistave
2015-09-26 8:27 ` Mike Nagie
2015-09-26 10:24 ` Mistave
2015-09-26 13:12 ` Robert Nichols
2015-09-26 15:38 ` Michael Kjörling
2015-09-27 11:08 ` Mike Nagie
2015-09-27 13:47 ` Michael Kjörling
2015-09-27 14:08 ` Arno Wagner
2015-09-27 14:15 ` Michael Kjörling
2015-09-27 14:34 ` Arno Wagner
2015-09-27 16:12 ` Mike Nagie
2015-09-27 16:51 ` Michael Kjörling
2015-09-27 18:20 ` Mike Nagie
2015-09-27 18:55 ` Heinz Diehl
2015-09-27 18:57 ` Heinz Diehl
2015-09-27 21:50 ` Mike Nagie
2015-09-27 22:08 ` Michael Kjörling
2015-09-28 20:11 ` Heinz Diehl
2015-09-29 10:52 ` Mike Nagie
2015-09-30 12:16 ` Mike Nagie
2015-09-30 15:00 ` Arno Wagner
2015-09-30 17:49 ` Mike Nagie
2015-09-30 19:27 ` Arno Wagner
2015-09-30 15:40 ` Heinz Diehl
2015-09-25 20:12 ` Arno Wagner
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=56058A83.9070509@countermail.com \
--to=mistave@countermail.com \
--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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox