/crypto/ |
D | echainiv.c | 34 unsigned int ivsize = crypto_aead_ivsize(geniv); in echainiv_encrypt() local 37 if (req->cryptlen < ivsize) in echainiv_encrypt() 65 memcpy(&nseqno, info + ivsize - 8, 8); in echainiv_encrypt() 67 memset(info, 0, ivsize); in echainiv_encrypt() 69 scatterwalk_map_and_copy(info, req->dst, req->assoclen, ivsize, 1); in echainiv_encrypt() 74 memcpy(&a, ctx->salt + ivsize - 8, 8); in echainiv_encrypt() 79 memcpy(info + ivsize - 8, &a, 8); in echainiv_encrypt() 80 } while ((ivsize -= 8)); in echainiv_encrypt() 92 unsigned int ivsize = crypto_aead_ivsize(geniv); in echainiv_decrypt() local 94 if (req->cryptlen < ivsize) in echainiv_decrypt() [all …]
|
D | seqiv.c | 58 unsigned int ivsize = 8; in seqiv_aead_encrypt() local 61 if (req->cryptlen < ivsize) in seqiv_aead_encrypt() 87 info = kmemdup(req->iv, ivsize, req->base.flags & in seqiv_aead_encrypt() 99 req->cryptlen - ivsize, info); in seqiv_aead_encrypt() 100 aead_request_set_ad(subreq, req->assoclen + ivsize); in seqiv_aead_encrypt() 102 crypto_xor(info, ctx->salt, ivsize); in seqiv_aead_encrypt() 103 scatterwalk_map_and_copy(info, req->dst, req->assoclen, ivsize, 1); in seqiv_aead_encrypt() 118 unsigned int ivsize = 8; in seqiv_aead_decrypt() local 120 if (req->cryptlen < ivsize + crypto_aead_authsize(geniv)) in seqiv_aead_decrypt() 130 req->cryptlen - ivsize, req->iv); in seqiv_aead_decrypt() [all …]
|
D | ablkcipher.c | 131 memcpy(req->info, walk->iv, tfm->crt_ablkcipher.ivsize); in ablkcipher_walk_done() 182 unsigned int ivsize = tfm->crt_ablkcipher.ivsize; in ablkcipher_copy_iv() local 184 unsigned int size = aligned_bs * 2 + ivsize + max(aligned_bs, ivsize) - in ablkcipher_copy_iv() 196 iv = ablkcipher_get_spot(iv, ivsize); in ablkcipher_copy_iv() 198 walk->iv = memcpy(iv, walk->iv, ivsize); in ablkcipher_copy_iv() 346 if (alg->ivsize > PAGE_SIZE / 8) in crypto_init_ablkcipher_ops() 353 crt->ivsize = alg->ivsize; in crypto_init_ablkcipher_ops() 371 rblkcipher.ivsize = alg->cra_ablkcipher.ivsize; in crypto_ablkcipher_report() 395 seq_printf(m, "ivsize : %u\n", ablkcipher->ivsize); in crypto_ablkcipher_show()
|
D | blkcipher.c | 130 memcpy(desc->info, walk->iv, walk->ivsize); in blkcipher_walk_done() 274 walk->ivsize + max(aligned_bs, walk->ivsize) - in blkcipher_copy_iv() 286 iv = blkcipher_get_spot(iv, walk->ivsize); in blkcipher_copy_iv() 288 walk->iv = memcpy(iv, walk->iv, walk->ivsize); in blkcipher_copy_iv() 298 walk->ivsize = crypto_blkcipher_ivsize(desc->tfm); in blkcipher_walk_virt() 310 walk->ivsize = crypto_blkcipher_ivsize(desc->tfm); in blkcipher_walk_phys() 348 walk->ivsize = crypto_blkcipher_ivsize(desc->tfm); in blkcipher_walk_virt_block() 362 walk->ivsize = crypto_aead_ivsize(tfm); in blkcipher_aead_walk_virt_block() 446 cipher->ivsize) { in crypto_blkcipher_ctxsize() 448 len += cipher->ivsize; in crypto_blkcipher_ctxsize() [all …]
|
D | essiv.c | 219 int ivsize = crypto_aead_ivsize(tfm); in essiv_aead_crypt() local 220 int ssize = req->assoclen - ivsize; in essiv_aead_crypt() 231 memcpy(iv, req->iv, ivsize); in essiv_aead_crypt() 251 sg_set_buf(rctx->sg + 1, iv, ivsize); in essiv_aead_crypt() 428 int ivsize) in essiv_supported_algorithms() argument 443 if (ivsize != alg->cra_blocksize) in essiv_supported_algorithms() 470 int ivsize; in essiv_create() local 508 ivsize = crypto_skcipher_alg_ivsize(skcipher_alg); in essiv_create() 535 ivsize = aead_alg->ivsize; in essiv_create() 560 ivsize)) { in essiv_create() [all …]
|
D | aead.c | 163 raead.ivsize = aead->ivsize; in crypto_aead_report() 184 seq_printf(m, "ivsize : %u\n", aead->ivsize); in crypto_aead_show() 239 unsigned int ivsize; in aead_geniv_alloc() local 270 ivsize = crypto_aead_alg_ivsize(alg); in aead_geniv_alloc() 274 if (ivsize < sizeof(u64)) in aead_geniv_alloc() 296 inst->alg.ivsize = ivsize; in aead_geniv_alloc() 389 if (max3(alg->maxauthsize, alg->ivsize, alg->chunksize) > in aead_prepare_alg()
|
D | skcipher.c | 170 memcpy(walk->oiv, walk->iv, walk->ivsize); in skcipher_walk_done() 209 memcpy(walk->oiv, walk->iv, walk->ivsize); in skcipher_walk_complete() 400 unsigned ivsize = walk->ivsize; in skcipher_copy_iv() local 412 size += ivsize; in skcipher_copy_iv() 414 size += aligned_bs + ivsize; in skcipher_copy_iv() 427 walk->iv = memcpy(iv, walk->iv, walk->ivsize); in skcipher_copy_iv() 470 walk->ivsize = crypto_skcipher_ivsize(tfm); in skcipher_walk_skcipher() 541 walk->ivsize = crypto_aead_ivsize(tfm); in skcipher_walk_aead_common() 689 skcipher->ivsize = crypto_blkcipher_ivsize(blkcipher); in crypto_init_skcipher_ops_blkcipher() 787 skcipher->ivsize = crypto_ablkcipher_ivsize(ablkcipher); in crypto_init_skcipher_ops_ablkcipher() [all …]
|
D | chacha_generic.c | 152 .ivsize = CHACHA_IV_SIZE, 167 .ivsize = XCHACHA_IV_SIZE, 182 .ivsize = XCHACHA_IV_SIZE,
|
D | simd.c | 185 alg->ivsize = ialg->ivsize; in simd_skcipher_create_compat() 435 alg->ivsize = ialg->ivsize; in simd_aead_create_compat()
|
D | testmgr.c | 1846 const unsigned int ivsize = crypto_aead_ivsize(tfm); in test_aead_vec_cfg() local 1894 if (WARN_ON(ivsize > MAX_IVLEN)) in test_aead_vec_cfg() 1897 memcpy(iv, vec->iv, ivsize); in test_aead_vec_cfg() 1899 memset(iv, 0, ivsize); in test_aead_vec_cfg() 2061 const unsigned int ivsize = crypto_aead_ivsize(tfm); in generate_random_aead_testvec() local 2078 generate_random_bytes((u8 *)vec->iv, ivsize); in generate_random_aead_testvec() 2116 memcpy(iv, vec->iv, ivsize); in generate_random_aead_testvec() 2139 const unsigned int ivsize = crypto_aead_ivsize(tfm); in test_aead_vs_generic_impl() local 2204 if (ivsize != crypto_aead_ivsize(generic_tfm)) { in test_aead_vs_generic_impl() 2206 driver, ivsize, crypto_aead_ivsize(generic_tfm)); in test_aead_vs_generic_impl() [all …]
|
D | chacha20poly1305.c | 563 const char *name, unsigned int ivsize) in chachapoly_create() argument 574 if (ivsize > CHACHAPOLY_IV_SIZE) in chachapoly_create() 610 ctx->saltlen = CHACHAPOLY_IV_SIZE - ivsize; in chachapoly_create() 652 inst->alg.ivsize = ivsize; in chachapoly_create()
|
D | ecb.c | 71 inst->alg.ivsize = 0; /* ECB mode doesn't take an IV */ in crypto_ecb_create()
|
D | algif_skcipher.c | 45 unsigned ivsize = crypto_skcipher_ivsize(tfm); in skcipher_sendmsg() local 47 return af_alg_sendmsg(sock, msg, size, ivsize); in skcipher_sendmsg()
|
D | crypto_null.c | 118 .ivsize = NULL_IV_SIZE,
|
D | keywrap.c | 280 inst->alg.ivsize = SEMIBSIZE; in crypto_kw_create()
|
D | algif_aead.c | 69 unsigned int ivsize = crypto_aead_ivsize(tfm); in aead_sendmsg() local 71 return af_alg_sendmsg(sock, msg, size, ivsize); in aead_sendmsg()
|
D | salsa20_generic.c | 189 .ivsize = SALSA20_IV_SIZE,
|
D | af_alg.c | 816 unsigned int ivsize) in af_alg_sendmsg() argument 845 if (con.iv && con.iv->ivlen != ivsize) in af_alg_sendmsg() 858 memcpy(ctx->iv, con.iv->iv, ivsize); in af_alg_sendmsg()
|
D | lrw.c | 389 inst->alg.ivsize = LRW_BLOCK_SIZE; in create()
|
D | pcrypt.c | 250 inst->alg.ivsize = crypto_aead_alg_ivsize(alg); in pcrypt_create_aead()
|
D | gcm.c | 663 inst->alg.ivsize = GCM_AES_IV_SIZE; in crypto_gcm_create_common() 926 inst->alg.ivsize = GCM_RFC4106_IV_SIZE; in crypto_rfc4106_create() 1164 inst->alg.ivsize = GCM_RFC4543_IV_SIZE; in crypto_rfc4543_create()
|
D | ctr.c | 326 inst->alg.ivsize = CTR_RFC3686_IV_SIZE; in crypto_rfc3686_create()
|
D | cts.c | 380 inst->alg.ivsize = alg->base.cra_blocksize; in crypto_cts_create()
|
D | aegis128-core.c | 464 .ivsize = AEGIS128_NONCE_SIZE,
|
D | xts.c | 429 inst->alg.ivsize = XTS_BLOCK_SIZE; in create()
|