All of lore.kernel.org
 help / color / mirror / Atom feed
From: Mike Snitzer <snitzer@redhat.com>
To: Milan Broz <gmazyland@gmail.com>
Cc: dm-devel@redhat.com, mpatocka@redhat.com
Subject: Re: dm-crypt: Fix parsing of extended IV arguments.
Date: Thu, 10 Jan 2019 14:18:25 -0500	[thread overview]
Message-ID: <20190110191825.GA936@redhat.com> (raw)
In-Reply-To: <20190109105714.3606-1-gmazyland@gmail.com>

On Wed, Jan 09 2019 at  5:57am -0500,
Milan Broz <gmazyland@gmail.com> wrote:

> The dm-crypt cipher specification in a mapping table is defined as
>   cipher[:keycount]-chainmode-ivmode[:ivopts] or with the new crypt API format
>   capi:cipher_api_spec-ivmode[:ivopts].
> 
> For ESSIV, the parameter includes hash specification, for example aes-cbc-essiv:sha256.
> 
> The implementation expected that additional IV option never includes another dash '-' character
> 
> Unfortunately, with SHA3, we have now names like sha3-256, so the mapping table parser fails:
> 
> dmsetup create test --table "0 8 crypt aes-cbc-essiv:sha3-256 9c1185a5c5e9fc54612808977ee8f5b9e 0 /dev/sdb 0"
>   or (new format)
> dmsetup create test --table "0 8 crypt capi:cbc(aes)-essiv:sha3-256 9c1185a5c5e9fc54612808977ee8f5b9e 0 /dev/sdb 0"
> 
>   device-mapper: crypt: Ignoring unexpected additional cipher options
>   device-mapper: table: 253:0: crypt: Error creating IV
>   device-mapper: ioctl: error adding target to table
> 
> This patch fixes the dm-crypt constructor to ignore additional dash in IV options and also removes
> bogus warning (that is ignored anyway).
> 
> [This patch should go into stable tree as well.]

Rather than this it'd be useful to just be more explicit, e.g.:

Fixes: XXXXXXXX ("commit subject")
Cc: stable@vger.kernel.org # > 4.x?

Once I know which commit exposed us to this problem I can take care of
getting this fix staged for 5.0-rcX inclussion.

Thanks,
Mike

  reply	other threads:[~2019-01-10 19:18 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-01-09 10:57 [PATCH] dm-crypt: Fix parsing of extended IV arguments Milan Broz
2019-01-10 19:18 ` Mike Snitzer [this message]
2019-01-10 19:50   ` Milan Broz
2019-01-10 20:27     ` Mike Snitzer

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=20190110191825.GA936@redhat.com \
    --to=snitzer@redhat.com \
    --cc=dm-devel@redhat.com \
    --cc=gmazyland@gmail.com \
    --cc=mpatocka@redhat.com \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.