linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* how to request crypto_alloc_shash for GMAC
@ 2021-07-09  5:48 Steve French
  2021-07-09  6:48 ` Herbert Xu
  0 siblings, 1 reply; 2+ messages in thread
From: Steve French @ 2021-07-09  5:48 UTC (permalink / raw)
  To: LKML; +Cc: Herbert Xu, James Morris

I was trying to add support for GMAC packet signing in the kernel
client (support for it, as an alternative to CMAC, has recently been
added to some SMB3.1.1 servers)

Presumably due to https://www.ietf.org/rfc/rfc4543.txt it is already
supported in the kernel ... but what is the name that it is exposed as
in the kernel crypto libraries?

When calling crypto_alloc_shash, I tried the obvious name:
         "gmac(aes)"
(similar to what was previously used "cmac(aes)" and "hmac(sha256")
but that didn't work.

Any idea what the algorithm name that is needed to be used for GMAC here?

In looking at drivers/crypto/ccp (not sure if that is the right
subdir) - the closest I see is ccp-crypto-aes-galois.c but using that
name I also got the same error (rc=-2) trying to request that as:
         "galois(aes)"

What is the correct name to use to request GMAC in crypto_alloc_shash?

Doing "git grep crypto_alloc_shash" there are no matches on:
       - "gcm" or "gmac" or "galois"
How is it named?
-- 
Thanks,

Steve

^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: how to request crypto_alloc_shash for GMAC
  2021-07-09  5:48 how to request crypto_alloc_shash for GMAC Steve French
@ 2021-07-09  6:48 ` Herbert Xu
  0 siblings, 0 replies; 2+ messages in thread
From: Herbert Xu @ 2021-07-09  6:48 UTC (permalink / raw)
  To: Steve French; +Cc: LKML, James Morris

On Fri, Jul 09, 2021 at 12:48:00AM -0500, Steve French wrote:
>
> Presumably due to https://www.ietf.org/rfc/rfc4543.txt it is already
> supported in the kernel ... but what is the name that it is exposed as
> in the kernel crypto libraries?

We don't have standalone gmac in the kernel, it only exists as
part of the AEAD algorithm gcm.  You're more than welcome to add
it of course.

Thanks,
-- 
Email: Herbert Xu <herbert@gondor.apana.org.au>
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2021-07-09  6:48 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-07-09  5:48 how to request crypto_alloc_shash for GMAC Steve French
2021-07-09  6:48 ` Herbert Xu

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).