From: Herbert Xu Date: Mon, 20 Jul 2026 01:34:21 +0000 (+1000) Subject: crypto: ccm - Set rfc4309 maxauthsize from child X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=438f4896f78f69ec73d5f32d2c024193f1223569;p=thirdparty%2Flinux.git crypto: ccm - Set rfc4309 maxauthsize from child Set the maxauthsize of rfc4309 using that of the child algorithm. Fixes: 4a49b499dfa0 ("[CRYPTO] ccm: Added CCM mode") Reported-by: Seohyeon Maeng Signed-off-by: Herbert Xu --- diff --git a/crypto/ccm.c b/crypto/ccm.c index 2ae929ffdef8..916441e4f2b8 100644 --- a/crypto/ccm.c +++ b/crypto/ccm.c @@ -747,7 +747,7 @@ static int crypto_rfc4309_create(struct crypto_template *tmpl, inst->alg.ivsize = 8; inst->alg.chunksize = crypto_aead_alg_chunksize(alg); - inst->alg.maxauthsize = 16; + inst->alg.maxauthsize = crypto_aead_alg_maxauthsize(alg); inst->alg.base.cra_ctxsize = sizeof(struct crypto_rfc4309_ctx);