Searched refs:authsize (Results 1 - 25 of 72) sorted by relevance

123

/linux-master/include/crypto/
H A Dgcm.h16 static inline int crypto_gcm_check_authsize(unsigned int authsize) argument
18 switch (authsize) {
37 static inline int crypto_rfc4106_check_authsize(unsigned int authsize) argument
39 switch (authsize) {
70 unsigned int authsize; member in struct:aesgcm_ctx
74 unsigned int keysize, unsigned int authsize);
H A Daead.h159 int (*setauthsize)(struct crypto_aead *tfm, unsigned int authsize);
177 unsigned int authsize; member in struct:crypto_aead
276 return tfm->authsize;
346 * @authsize: size of the authentication data / tag in bytes
353 int crypto_aead_setauthsize(struct crypto_aead *tfm, unsigned int authsize);
/linux-master/crypto/
H A Daegis-neon.h15 unsigned int authsize);
H A Daegis128-neon.c59 unsigned int authsize)
65 authsize);
55 crypto_aegis128_final_simd(struct aegis_state *state, union aegis_block *tag_xor, unsigned int assoclen, unsigned int cryptlen, unsigned int authsize) argument
H A Daegis128-core.c379 unsigned int authsize)
381 if (authsize > AEGIS128_MAX_AUTH_SIZE)
383 if (authsize < AEGIS128_MIN_AUTH_SIZE)
392 unsigned int authsize = crypto_aead_authsize(tfm); local
406 authsize, 1);
415 unsigned int authsize = crypto_aead_authsize(tfm); local
416 unsigned int cryptlen = req->cryptlen - authsize;
422 authsize, 0);
431 if (unlikely(crypto_memneq(tag.bytes, zeros, authsize))) {
453 unsigned int authsize local
378 crypto_aegis128_setauthsize(struct crypto_aead *tfm, unsigned int authsize) argument
478 unsigned int authsize = crypto_aead_authsize(tfm); local
[all...]
H A Dauthencesn.c50 unsigned int authsize)
52 if (authsize > 0 && authsize < 4)
92 unsigned int authsize = crypto_aead_authsize(authenc_esn); local
103 scatterwalk_map_and_copy(hash, dst, assoclen + cryptlen, authsize, 1);
124 unsigned int authsize = crypto_aead_authsize(authenc_esn); local
130 if (!authsize)
217 unsigned int authsize = crypto_aead_authsize(authenc_esn); local
224 unsigned int cryptlen = req->cryptlen - authsize;
230 if (!authsize)
49 crypto_authenc_esn_setauthsize(struct crypto_aead *authenc_esn, unsigned int authsize) argument
268 unsigned int authsize = crypto_aead_authsize(authenc_esn); local
[all...]
H A Daead.c74 int crypto_aead_setauthsize(struct crypto_aead *tfm, unsigned int authsize) argument
78 if ((!authsize && crypto_aead_maxauthsize(tfm)) ||
79 authsize > crypto_aead_maxauthsize(tfm))
83 err = crypto_aead_alg(tfm)->setauthsize(tfm, authsize);
88 tfm->authsize = authsize;
167 aead->authsize = alg->maxauthsize;
H A Dgcm.c147 unsigned int authsize)
149 return crypto_gcm_check_authsize(authsize);
469 unsigned int authsize = crypto_aead_authsize(aead); local
470 unsigned int cryptlen = req->cryptlen - authsize;
474 req->assoclen + cryptlen, authsize, 0);
475 return crypto_memneq(iauth_tag, auth_tag, authsize) ? -EBADMSG : 0;
504 unsigned int authsize = crypto_aead_authsize(aead); local
508 cryptlen -= authsize;
706 unsigned int authsize)
711 err = crypto_rfc4106_check_authsize(authsize);
146 crypto_gcm_setauthsize(struct crypto_aead *tfm, unsigned int authsize) argument
705 crypto_rfc4106_setauthsize(struct crypto_aead *parent, unsigned int authsize) argument
913 crypto_rfc4543_setauthsize(struct crypto_aead *parent, unsigned int authsize) argument
930 unsigned int authsize = crypto_aead_authsize(aead); local
959 unsigned int authsize = crypto_aead_authsize(aead); local
[all...]
/linux-master/arch/x86/crypto/
H A Daegis128-aesni-glue.c156 unsigned int authsize)
158 if (authsize > AEGIS128_MAX_AUTH_SIZE)
160 if (authsize < AEGIS128_MIN_AUTH_SIZE)
197 unsigned int authsize = crypto_aead_authsize(tfm); local
203 req->assoclen + cryptlen, authsize, 1);
219 unsigned int authsize = crypto_aead_authsize(tfm); local
220 unsigned int cryptlen = req->cryptlen - authsize;
223 req->assoclen + cryptlen, authsize, 0);
227 return crypto_memneq(tag.bytes, zeros.bytes, authsize) ? -EBADMSG : 0;
155 crypto_aegis128_aesni_setauthsize(struct crypto_aead *tfm, unsigned int authsize) argument
/linux-master/drivers/net/ethernet/chelsio/inline_crypto/ch_ipsec/
H A Dchcr_ipsec.h50 unsigned int authsize; member in struct:ipsec_sa_entry
/linux-master/drivers/crypto/qce/
H A Daead.h21 unsigned int authsize; member in struct:qce_aead_ctx
H A Daead.c74 totallen, ctx->authsize, 1);
77 totallen, ctx->authsize, 1);
80 totallen = req->cryptlen + req->assoclen - ctx->authsize;
81 scatterwalk_map_and_copy(tag, req->src, totallen, ctx->authsize, 0);
82 ret = memcmp(result_buf->auth_iv, tag, ctx->authsize);
198 cryptlen = rctx->cryptlen + ctx->authsize;
344 cryptlen = rctx->cryptlen + ctx->authsize;
399 rctx->ccm_nonce[0] |= ((ctx->authsize - 2) / 2) <<
516 rctx->cryptlen = req->cryptlen - ctx->authsize;
651 static int qce_aead_setauthsize(struct crypto_aead *tfm, unsigned int authsize) argument
[all...]
/linux-master/drivers/crypto/nx/
H A Dnx-aes-ccm.c70 unsigned int authsize)
72 switch (authsize) {
89 unsigned int authsize)
91 switch (authsize) {
133 static int generate_b0(u8 *iv, unsigned int assoclen, unsigned int authsize, argument
136 unsigned int l, lp, m = authsize;
156 unsigned int authsize,
208 rc = generate_b0(iv, assoclen, authsize, nbytes, b0);
333 unsigned int authsize = crypto_aead_authsize(crypto_aead_reqtfm(req)); local
341 nbytes -= authsize;
69 ccm_aes_nx_setauthsize(struct crypto_aead *tfm, unsigned int authsize) argument
88 ccm4309_aes_nx_setauthsize(struct crypto_aead *tfm, unsigned int authsize) argument
153 generate_pat(u8 *iv, struct aead_request *req, struct nx_crypto_ctx *nx_ctx, unsigned int authsize, unsigned int nbytes, unsigned int assoclen, u8 *out) argument
411 unsigned int authsize = crypto_aead_authsize(crypto_aead_reqtfm(req)); local
[all...]
/linux-master/drivers/crypto/cavium/nitrox/
H A Dnitrox_aead.c59 unsigned int authsize)
66 flags.w0.mac_len = authsize;
69 aead->authsize = authsize;
75 unsigned int authsize)
77 switch (authsize) {
90 return nitrox_aead_setauthsize(aead, authsize);
230 rctx->dstlen = rctx->srclen + aead->authsize;
261 rctx->cryptlen = areq->cryptlen - aead->authsize;
264 rctx->dstlen = rctx->srclen - aead->authsize;
58 nitrox_aead_setauthsize(struct crypto_aead *aead, unsigned int authsize) argument
74 nitrox_aes_gcm_setauthsize(struct crypto_aead *aead, unsigned int authsize) argument
378 nitrox_rfc4106_setauthsize(struct crypto_aead *aead, unsigned int authsize) argument
[all...]
/linux-master/arch/arm64/crypto/
H A Dsm4-ce-ccm-glue.c46 static int ccm_setauthsize(struct crypto_aead *tfm, unsigned int authsize) argument
48 if ((authsize & 1) || authsize < 4)
243 unsigned int authsize = crypto_aead_authsize(aead); local
250 err = ccm_format_input(mac, req, req->cryptlen - authsize);
264 req->assoclen + req->cryptlen - authsize,
265 authsize, 0);
267 if (crypto_memneq(authtag, mac, authsize))
H A Daes-ce-ccm-glue.c55 static int ccm_setauthsize(struct crypto_aead *tfm, unsigned int authsize) argument
57 if ((authsize & 1) || authsize < 4)
249 unsigned int authsize = crypto_aead_authsize(aead); local
253 u32 len = req->cryptlen - authsize;
307 req->assoclen + req->cryptlen - authsize,
308 authsize, 0);
310 if (crypto_memneq(mac, orig_iv, authsize))
H A Dsm4-ce-gcm-glue.c61 static int gcm_setauthsize(struct crypto_aead *tfm, unsigned int authsize) argument
63 switch (authsize) {
220 unsigned int authsize = crypto_aead_authsize(aead); local
233 req->assoclen + req->cryptlen - authsize,
234 authsize, 0);
236 if (crypto_memneq(authtag, ghash, authsize))
H A Dghash-ce-glue.c64 const u8 tag[], u64 authsize);
264 static int gcm_aes_setauthsize(struct crypto_aead *tfm, unsigned int authsize) argument
266 return crypto_gcm_check_authsize(authsize);
402 unsigned int authsize = crypto_aead_authsize(aead); local
414 lengths.b = cpu_to_be64((req->cryptlen - authsize) * 8);
422 req->assoclen + req->cryptlen - authsize,
423 authsize, 0);
445 nrounds, tag, otag, authsize);
495 static int rfc4106_setauthsize(struct crypto_aead *tfm, unsigned int authsize) argument
497 return crypto_rfc4106_check_authsize(authsize);
[all...]
/linux-master/lib/crypto/
H A Daesgcm.c41 * @authsize: The size in bytes of the GCM authentication tag
43 * Returns: 0 on success, or -EINVAL if @keysize or @authsize contain values
47 unsigned int keysize, unsigned int authsize)
52 ret = crypto_gcm_check_authsize(authsize) ?:
57 ctx->authsize = authsize;
102 crypto_xor_cpy(authtag, buf, (u8 *)&ghash, ctx->authsize);
146 * @ctx->authsize bytes.
189 if (crypto_memneq(authtag, tagbuf, ctx->authsize)) {
46 aesgcm_expandkey(struct aesgcm_ctx *ctx, const u8 *key, unsigned int keysize, unsigned int authsize) argument
/linux-master/drivers/crypto/
H A Domap-aes-gcm.c71 dd->authsize, 1);
81 for (i = 0; i < dd->authsize; i++) {
151 dd->authsize = authlen;
195 dd->authsize, 0);
349 int omap_aes_gcm_setauthsize(struct crypto_aead *tfm, unsigned int authsize) argument
351 return crypto_gcm_check_authsize(authsize);
355 unsigned int authsize)
357 return crypto_rfc4106_check_authsize(authsize);
354 omap_aes_4106gcm_setauthsize(struct crypto_aead *parent, unsigned int authsize) argument
/linux-master/drivers/crypto/ccree/
H A Dcc_buffer_mgr.c538 static bool cc_is_icv_frag(unsigned int sgl_nents, unsigned int authsize, argument
541 return ((sgl_nents > 1) && (last_entry_data_size < authsize));
657 unsigned int authsize = areq_ctx->req_authsize; local
665 offset = *src_last_bytes - authsize;
668 offset = *dst_last_bytes - authsize;
683 unsigned int authsize = areq_ctx->req_authsize; local
695 cc_is_icv_frag(areq_ctx->src.nents, authsize,
722 (*src_last_bytes - authsize);
724 (*src_last_bytes - authsize);
739 cc_is_icv_frag(areq_ctx->src.nents, authsize,
796 unsigned int authsize = areq_ctx->req_authsize; local
952 unsigned int authsize = areq_ctx->req_authsize; local
[all...]
H A Dcc_aead.c57 unsigned int authsize; /* Actual (reduced?) size of the MAC/ICv */ member in struct:cc_aead_ctx
229 ctx->authsize) != 0) {
231 ctx->authsize, ctx->cipher_mode);
244 skip, (skip + ctx->authsize),
670 unsigned int authsize)
676 if (authsize == 0 ||
677 authsize > crypto_aead_maxauthsize(authenc)) {
681 ctx->authsize = authsize;
682 dev_dbg(dev, "authlen=%d\n", ctx->authsize);
669 cc_aead_setauthsize(struct crypto_aead *authenc, unsigned int authsize) argument
687 cc_rfc4309_ccm_setauthsize(struct crypto_aead *authenc, unsigned int authsize) argument
702 cc_ccm_setauthsize(struct crypto_aead *authenc, unsigned int authsize) argument
2141 cc_gcm_setauthsize(struct crypto_aead *authenc, unsigned int authsize) argument
2160 cc_rfc4106_gcm_setauthsize(struct crypto_aead *authenc, unsigned int authsize) argument
2180 cc_rfc4543_gcm_setauthsize(struct crypto_aead *authenc, unsigned int authsize) argument
[all...]
/linux-master/drivers/crypto/caam/
H A Dcaamalg_qi.c73 unsigned int authsize; member in struct:caam_ctx
100 if (!ctx->cdata.keylen || !ctx->authsize)
150 ivsize, ctx->authsize, is_rfc3686, nonce,
165 ivsize, ctx->authsize, alg->caam.geniv,
183 ivsize, ctx->authsize, is_rfc3686, nonce,
190 static int aead_setauthsize(struct crypto_aead *authenc, unsigned int authsize) argument
194 ctx->authsize = authsize;
312 if (!ctx->cdata.keylen || !ctx->authsize)
328 ctx->authsize, tru
348 gcm_setauthsize(struct crypto_aead *authenc, unsigned int authsize) argument
451 rfc4106_setauthsize(struct crypto_aead *authenc, unsigned int authsize) argument
559 rfc4543_setauthsize(struct crypto_aead *authenc, unsigned int authsize) argument
956 unsigned int authsize = ctx->authsize; local
[all...]
/linux-master/drivers/crypto/starfive/
H A Djh7110-aes.c219 b0[0] |= (8 * ((cryp->authsize - 2) / 2));
321 scatterwalk_copychunks(cryp->tag_out, &cryp->out_walk, cryp->authsize, 1);
323 scatterwalk_copychunks(cryp->tag_in, &cryp->in_walk, cryp->authsize, 0);
325 if (crypto_memneq(cryp->tag_in, cryp->tag_out, cryp->authsize))
337 if (!err && cryp->authsize)
349 if (cryp->authsize)
475 cryp->authsize = 0;
479 cryp->authsize = crypto_aead_authsize(crypto_aead_reqtfm(areq));
484 cryp->total_in = areq->cryptlen - cryp->authsize;
735 unsigned int authsize)
734 starfive_aes_gcm_setauthsize(struct crypto_aead *tfm, unsigned int authsize) argument
740 starfive_aes_ccm_setauthsize(struct crypto_aead *tfm, unsigned int authsize) argument
[all...]
/linux-master/drivers/crypto/xilinx/
H A Dzynqmp-aes-gcm.c68 u32 authsize; member in struct:zynqmp_aead_tfm_ctx
183 if (tfm_ctx->authsize != ZYNQMP_AES_AUTH_SIZE)
274 unsigned int authsize)
280 tfm_ctx->authsize = authsize;
281 return crypto_aead_setauthsize(tfm_ctx->fbk_cipher, authsize);
273 zynqmp_aes_aead_setauthsize(struct crypto_aead *aead, unsigned int authsize) argument

Completed in 403 milliseconds

123