DM-Crypt Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: Arno Wagner <arno@wagner.name>
To: dm-crypt@saout.de
Subject: Re: [dm-crypt] Cryptesetup and dm-crypt
Date: Wed, 27 Apr 2016 18:35:49 +0200	[thread overview]
Message-ID: <20160427163549.GA7851@tansi.org> (raw)
In-Reply-To: <1461761810.6452.16.camel@inria.fr>

At the very least, it is a safety issue, as all documentation 
and all relevant help given here says block size is 512 bytes.
It is also a compatibility issue, as volumes done this way 
would only work on your specific system and could not be 
accessed and recovered anywhere else. 

My stance would be sure, shoot yourself in the foot, but do
not call the result "LUKS".

Regards,
Arno

On Wed, Apr 27, 2016 at 14:56:50 CEST, levent demir wrote:
> Hi,
> 
> I am a PhD student and works and I am working with cryptsetup and a hw
> crypto engine. 
> 
> I am using an ATMEL board which is able to do AES-ECB mode for example. 
> 
> We have implemented an XTS version with all operations (XOR, GF
> Multiplication, 2 AES : one for IV one for data...)
> 
> My question is can we use the page size instead of the block size of 512
> bytes ?
> 
> I have read some thread it is written that it could be a security issue
> but I don't agree because : 
> 
> Now to implement XTS I do as follows basically : 
> 
> I take the IV encrypt it with the second part of the key, then I compute
> the 32 tweaks values in -for example- an array tweak_buf[512]. 
> Then I just have to compute the XOR with plaintext. 
> I do a DMA encryption with ECB of the 512 bytes. 
> Again I xor the ciphered data with tweak_buf.
> 
> Then I have ciphered a whole block of 512 bytes.
> 
> Now my question, the hardware is supporting a DMA operation till 4096, 
> is it not interesting to encrypt 8 blocks at a time ? 
> It is exactly the same operation as encrypting each block
> consecutively. 
> 
> Of course I need to pre-compute the 8 tweak_buf in a big
> tweak_buf[4096].Then in only one DMA operation I will be able to encrypt
> 4096 bytes with ECB mode. 
> 
> I hope you understand what I mean.
> 
> Can you tell me if it is possible ? If yes can I use a previous patch, I
> have seen that there are some works on it ?
> 
> Thank you. 
> 
> 
> _______________________________________________
> dm-crypt mailing list
> dm-crypt@saout.de
> http://www.saout.de/mailman/listinfo/dm-crypt

-- 
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 
"news" is "something that hardly ever happens." -- Bruce Schneier

  reply	other threads:[~2016-04-27 16:35 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-03-14 15:21 [dm-crypt] Some questions/clarifications around the LUKS spec Daniel P. Berrange
2016-03-14 18:58 ` Sven Eschenberg
2016-03-14 19:54   ` Milan Broz
2016-03-14 21:24     ` Sven Eschenberg
2016-03-14 22:27       ` Milan Broz
2016-03-15 14:21         ` Sven Eschenberg
2016-04-27 12:56         ` [dm-crypt] Cryptesetup and dm-crypt levent demir
2016-04-27 16:35           ` Arno Wagner [this message]
2016-03-14 20:31 ` [dm-crypt] Some questions/clarifications around the LUKS spec Milan Broz
2016-03-15 10:23   ` Daniel P. Berrange

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=20160427163549.GA7851@tansi.org \
    --to=arno@wagner.name \
    --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