lkml.org 
[lkml]   [1999]   [Sep]   [7]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: loop.c transfer module api
On Tue, Sep 07, 1999 at 07:20:03AM -0500, kernel@draper.net wrote:
>
> Agreed. But, storing random IVs someplace doesn't sound very righteous.
>
> Several months ago, as an experiment, I generated a large kernel module
> (called loop_rand) filled with data taken from /dev/random. I then
> modified the kerneli twofish code to derive IVs based on both the real_block
> and data taken from the table. My twofish notes to myself:
>
> * Jan 17, 1999 - Added exploitation of module loop_rand. This table
> * contains a fairly large number of 96 bit entries of
> * random data. A 128 bit block IV is derived by computing
> * IV = E( real_block + loop_rand[ mod(real_block/entries ] )
> * <-32bits-> + <-----------96bits---------------->
> * <---------------------128 bit IV ------------------->
> *
> * The implication is now that two secrets must be known
> * to recover the data: 1) The 128 bit key (pass phrase hash)
> * and 2) the loop_rand kernel module (which is intended to
> * be stored on *OTHER* than the encrypted disk)(preferably
> * a diskette which is stored seperately from the machine).
>
> The stength of the cipher should remain in the key, not in the IVs. I am
> not comfortable with my loop_rand work, it strikes me as an overkill.
>
> I think your #2 idea is perfect. Suppose one were to develop a
> "filesystem signature" in losetup as a hash of the fully qualified
> device/file name, stuff that into the loop_device structure, and then have
> loop.c pass IV = relative_block + signature into the transfer module.
> The result is both relocatable and avoids duplication of ciphertext...
> the best of both worlds.
>

The IV should be _random_, not secret. Just look at the operation of
CBC mode. Each block of ciphertext is the next block's "IV". So
there is no reason to keep the first IV secret when all the other
"IVs" are exposed. What we want to do is to keep the first IV
_random_.


astor

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 13:53    [W:1.508 / U:0.056 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site