Linux NFS development
 help / color / mirror / Atom feed
From: David Howells <dhowells@redhat.com>
To: Herbert Xu <herbert@gondor.apana.org.au>
Cc: dhowells@redhat.com, Chuck Lever III <chuck.lever@oracle.com>,
	Scott Mayhew <smayhew@redhat.com>,
	Ard Biesheuvel <ardb@kernel.org>,
	Jeff Layton <jlayton@kernel.org>,
	Linux NFS Mailing List <linux-nfs@vger.kernel.org>,
	"linux-crypto@vger.kernel.org" <linux-crypto@vger.kernel.org>
Subject: Re: Did the in-kernel Camellia or CMAC crypto implementation break?
Date: Fri, 14 Apr 2023 11:34:37 +0100	[thread overview]
Message-ID: <1239686.1681468477@warthog.procyon.org.uk> (raw)
In-Reply-To: <ZDkoiqPXwIRYmeF3@gondor.apana.org.au>

Herbert Xu <herbert@gondor.apana.org.au> wrote:

> Interesting.  Could you outline how this new interface would work?

I'll write up an API doc for my code as I have it working and post that.

> And have you looked whether the aead interface could fit into your
> model?

Do you mean use the aead API rather than inventing my own?  Looking at aead.h,
there aren't enough bits in it as it stands:

	struct aead_alg {
		int (*setkey)(struct crypto_aead *tfm, const u8 *key,
			      unsigned int keylen);
		int (*setauthsize)(struct crypto_aead *tfm, unsigned int authsize);
		int (*encrypt)(struct aead_request *req);
		int (*decrypt)(struct aead_request *req);
		int (*init)(struct crypto_aead *tfm);
		void (*exit)(struct crypto_aead *tfm);

		unsigned int ivsize;
		unsigned int maxauthsize;
		unsigned int chunksize;

		struct crypto_alg base;
	};

In krb5, for encryption, there are two keys, not one, and no IV to be passed
in.  The code I have will insert a confounder and a checksum, which must have
space allowed for it.

David


  reply	other threads:[~2023-04-14 10:35 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-04-12 15:56 Did the in-kernel Camellia or CMAC crypto implementation break? David Howells
2023-04-12 16:57 ` Chuck Lever III
2023-04-12 17:44   ` Scott Mayhew
2023-04-12 17:50     ` David Howells
2023-04-13  6:07       ` Herbert Xu
2023-04-13  6:36         ` David Howells
2023-04-13  6:40           ` Herbert Xu
2023-04-13  8:59             ` David Howells
2023-04-13 13:55   ` David Howells
2023-04-14  2:08     ` Herbert Xu
2023-04-14  8:47       ` David Howells
2023-04-14  8:52         ` Herbert Xu
2023-04-14 10:17           ` David Howells
2023-04-14 10:18             ` Herbert Xu
2023-04-14 10:34               ` David Howells [this message]
2023-04-14 11:04                 ` Herbert Xu
2023-04-14 12:32               ` David Howells
2023-05-22 21:07           ` David Howells

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=1239686.1681468477@warthog.procyon.org.uk \
    --to=dhowells@redhat.com \
    --cc=ardb@kernel.org \
    --cc=chuck.lever@oracle.com \
    --cc=herbert@gondor.apana.org.au \
    --cc=jlayton@kernel.org \
    --cc=linux-crypto@vger.kernel.org \
    --cc=linux-nfs@vger.kernel.org \
    --cc=smayhew@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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox