lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <6c9b32ef-1e63-f721-1d7f-b0f1e0f2d1ca@nod.at>
Date:   Tue, 4 Oct 2016 10:46:54 +0200
From:   Richard Weinberger <richard@....at>
To:     Eric Biggers <ebiggers@...gle.com>
Cc:     linux-fsdevel <linux-fsdevel@...r.kernel.org>,
        linux-ext4@...r.kernel.org, linux-f2fs-devel@...ts.sourceforge.net,
        Theodore Ts'o <tytso@....edu>, jaegeuk@...nel.org,
        David Gstir <david@...ma-star.at>
Subject: Re: [PATCH] fscrypto: make XTS tweak initialization
 endian-independent

Eric,

On 03.10.2016 20:03, Eric Biggers wrote:
>>>  {
>>> -       u8 xts_tweak[FS_XTS_TWEAK_SIZE];
>>> +       struct {
>>> +               __le64 index;
>>> +               u8 padding[FS_XTS_TWEAK_SIZE - sizeof(__le64)];
>>> +       } xts_tweak;
>>
>> While we are here, wouldn't it make sense to rename the variable to "iv"?
>> In aes-xts mode the IV is used as tweak. But it is still an IV and passed
>> as IV parameter to the crypto API.
>>
>> Especially when other cipher modes are used this is confusing.
>>
> 
> Good idea --- I agree that "iv" is a better name, so as to not tie the code to
> XTS specifically.  But I think the renaming should be a separate patch.

Sure. I can do that.

> Also, currently this code *is* only supposed to be used for XTS.  There's a bug
> where a specially crafted filesystem can cause this code path to be entered with
> CTS, but I have a patch pending in the ext4 tree to fix that.

David and I are currently working on UBIFS encryption and we have to support other cipher
modes than XTS. So, keeping fscrypto as generic as possible would be nice. :-)

Thanks,
//richard
--
To unsubscribe from this list: send the line "unsubscribe linux-ext4" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ