Lines Matching refs:authsize
87 unsigned int authsize; member
188 if (!ctx->cdata.keylen || !ctx->authsize) in aead_set_sh_desc()
240 ivsize, ctx->authsize, is_rfc3686, in aead_set_sh_desc()
245 ivsize, ctx->authsize, is_rfc3686, nonce, in aead_set_sh_desc()
266 ivsize, ctx->authsize, alg->caam.geniv, in aead_set_sh_desc()
277 static int aead_setauthsize(struct crypto_aead *authenc, unsigned int authsize) in aead_setauthsize() argument
281 ctx->authsize = authsize; in aead_setauthsize()
367 unsigned int authsize = ctx->authsize; in aead_edesc_alloc() local
381 dst_len = src_len + (encrypt ? authsize : (-authsize)); in aead_edesc_alloc()
426 (encrypt ? authsize : 0); in aead_edesc_alloc()
547 (encrypt ? ctx->authsize : (-ctx->authsize)); in aead_edesc_alloc()
596 if (!ctx->cdata.keylen || !ctx->authsize) in chachapoly_set_sh_desc()
602 ctx->authsize, true, true); in chachapoly_set_sh_desc()
611 ctx->authsize, false, true); in chachapoly_set_sh_desc()
621 unsigned int authsize) in chachapoly_setauthsize() argument
625 if (authsize != POLY1305_DIGEST_SIZE) in chachapoly_setauthsize()
628 ctx->authsize = authsize; in chachapoly_setauthsize()
659 if (!ctx->cdata.keylen || !ctx->authsize) in gcm_set_sh_desc()
677 cnstr_shdsc_gcm_encap(desc, &ctx->cdata, ivsize, ctx->authsize, true); in gcm_set_sh_desc()
697 cnstr_shdsc_gcm_decap(desc, &ctx->cdata, ivsize, ctx->authsize, true); in gcm_set_sh_desc()
706 static int gcm_setauthsize(struct crypto_aead *authenc, unsigned int authsize) in gcm_setauthsize() argument
711 err = crypto_gcm_check_authsize(authsize); in gcm_setauthsize()
715 ctx->authsize = authsize; in gcm_setauthsize()
751 if (!ctx->cdata.keylen || !ctx->authsize) in rfc4106_set_sh_desc()
770 cnstr_shdsc_rfc4106_encap(desc, &ctx->cdata, ivsize, ctx->authsize, in rfc4106_set_sh_desc()
790 cnstr_shdsc_rfc4106_decap(desc, &ctx->cdata, ivsize, ctx->authsize, in rfc4106_set_sh_desc()
801 unsigned int authsize) in rfc4106_setauthsize() argument
806 err = crypto_rfc4106_check_authsize(authsize); in rfc4106_setauthsize()
810 ctx->authsize = authsize; in rfc4106_setauthsize()
852 if (!ctx->cdata.keylen || !ctx->authsize) in rfc4543_set_sh_desc()
871 cnstr_shdsc_rfc4543_encap(desc, &ctx->cdata, ivsize, ctx->authsize, in rfc4543_set_sh_desc()
891 cnstr_shdsc_rfc4543_decap(desc, &ctx->cdata, ivsize, ctx->authsize, in rfc4543_set_sh_desc()
902 unsigned int authsize) in rfc4543_setauthsize() argument
906 if (authsize != 16) in rfc4543_setauthsize()
909 ctx->authsize = authsize; in rfc4543_setauthsize()