Home
last modified time | relevance | path

Searched refs:opad (Results 1 – 23 of 23) sorted by relevance

/linux/crypto/
H A Dhmac.c40 u8 *opad = &tctx->pads[ss]; in hmac_setkey() local
61 memcpy(opad, ipad, bs); in hmac_setkey()
65 opad[i] ^= HMAC_OPAD_VALUE; in hmac_setkey()
72 crypto_shash_update(shash, opad, bs) ?: in hmac_setkey()
73 crypto_shash_export(shash, opad); in hmac_setkey()
114 const u8 *opad = &tctx->pads[ss]; in hmac_final() local
118 crypto_shash_import(desc, opad) ?: in hmac_final()
130 const u8 *opad = &tctx->pads[ss]; in hmac_finup() local
134 crypto_shash_import(desc, opad) ?: in hmac_finup()
/linux/drivers/crypto/chelsio/
H A Dchcr_algo.h145 #define FILL_SEC_CPL_SCMD0_SEQNO(ctrl, seq, cmode, amode, opad, size) \ argument
154 SCMD_HMAC_CTRL_V((opad)) | \
170 #define FILL_KEY_CTX_HDR(ck_size, mk_size, d_ck, opad, ctx_len) \ argument
175 KEY_CONTEXT_OPAD_PRESENT_V((opad)) | \
179 #define FILL_KEY_CRX_HDR(ck_size, mk_size, d_ck, opad, ctx_len) \ argument
H A Dchcr_crypto.h246 u8 opad[CHCR_HASH_MAX_BLOCK_SIZE_128]; member
/linux/drivers/crypto/marvell/octeontx/
H A Dotx_cptvf_algs.c553 ctx->opad = kzalloc(ss, GFP_KERNEL); in cpt_aead_init()
554 if (!ctx->opad) { in cpt_aead_init()
563 kfree(ctx->opad); in cpt_aead_init()
622 kfree(ctx->opad); in otx_cpt_aead_exit()
756 u8 *ipad = NULL, *opad = NULL; in aead_hmac_init() local
793 opad = ctx->opad; in aead_hmac_init()
797 memcpy(opad, ipad, bs); in aead_hmac_init()
801 opad[icount] ^= 0x5c; in aead_hmac_init()
819 crypto_shash_update(&ctx->sdesc->shash, opad, bs); in aead_hmac_init()
820 crypto_shash_export(&ctx->sdesc->shash, opad); in aead_hmac_init()
[all …]
H A Dotx_cptvf_algs.h116 u8 opad[64]; member
174 u8 *opad; member
/linux/drivers/crypto/allwinner/sun8i-ss/
H A Dsun8i-ss-hash.c70 tfmctx->opad = kzalloc(bs, GFP_KERNEL); in sun8i_ss_hmac_setkey()
71 if (!tfmctx->opad) { in sun8i_ss_hmac_setkey()
78 memcpy(tfmctx->opad, tfmctx->key, tfmctx->keylen); in sun8i_ss_hmac_setkey()
81 tfmctx->opad[i] ^= HMAC_OPAD_VALUE; in sun8i_ss_hmac_setkey()
89 kfree_sensitive(tfmctx->opad); in sun8i_ss_hmac_setkey()
138 kfree_sensitive(tfmctx->opad); in sun8i_ss_hash_exit_tfm()
606 addr_xpad = dma_map_single(ss->dev, tfmctx->opad, bs, DMA_TO_DEVICE); in sun8i_ss_hash_run()
H A Dsun8i-ss.h235 u8 *opad; member
/linux/drivers/crypto/marvell/octeontx2/
H A Dotx2_cptvf_algs.c646 ctx->opad = kzalloc(ss, GFP_KERNEL); in cpt_aead_init()
647 if (!ctx->opad) { in cpt_aead_init()
732 kfree(ctx->opad); in otx2_cpt_aead_exit()
844 u8 *ipad = NULL, *opad = NULL; in aead_hmac_init() local
882 opad = ctx->opad; in aead_hmac_init()
886 memcpy(opad, ipad, bs); in aead_hmac_init()
890 opad[icount] ^= 0x5c; in aead_hmac_init()
908 crypto_shash_update(&ctx->sdesc->shash, opad, bs); in aead_hmac_init()
909 crypto_shash_export(&ctx->sdesc->shash, opad); in aead_hmac_init()
910 ret = swap_pad(ctx->mac_type, opad); in aead_hmac_init()
[all …]
H A Dotx2_cptvf_algs.h107 u8 opad[64]; member
170 u8 *opad; member
/linux/drivers/crypto/marvell/cesa/
H A Dhash.c1138 u8 *ipad, u8 *opad, in mv_cesa_ahmac_pad_init() argument
1172 memcpy(opad, ipad, blocksize); in mv_cesa_ahmac_pad_init()
1176 opad[i] ^= HMAC_OPAD_VALUE; in mv_cesa_ahmac_pad_init()
1190 u8 *opad; in mv_cesa_ahmac_setkey() local
1213 opad = ipad + blocksize; in mv_cesa_ahmac_setkey()
1215 ret = mv_cesa_ahmac_pad_init(req, key, keylen, ipad, opad, blocksize); in mv_cesa_ahmac_setkey()
1223 ret = mv_cesa_ahmac_iv_state_init(req, opad, ostate, blocksize); in mv_cesa_ahmac_setkey()
/linux/drivers/crypto/cavium/cpt/
H A Dcptvf_algs.h90 u8 opad[64]; /* or OPAD */ member
/linux/drivers/crypto/intel/qat/qat_common/
H A Dqat_algs.c80 char opad[SHA512_BLOCK_SIZE]; member
124 memset(ctx->opad, 0, block_size); in qat_alg_do_precomputes()
133 memcpy(ctx->opad, ctx->ipad, digest_size); in qat_alg_do_precomputes()
136 memcpy(ctx->opad, auth_key, auth_keylen); in qat_alg_do_precomputes()
141 char *opad_ptr = ctx->opad + i; in qat_alg_do_precomputes()
181 if (crypto_shash_update(shash, ctx->opad, block_size)) in qat_alg_do_precomputes()
214 memzero_explicit(ctx->opad, block_size); in qat_alg_do_precomputes()
/linux/drivers/crypto/ccp/
H A Dccp-crypto-sha.c162 rctx->cmd.u.sha.opad = ctx->u.sha.key_len ? in ccp_do_sha_update()
303 ctx->u.sha.opad[i] = ctx->u.sha.key[i] ^ HMAC_OPAD_VALUE; in ccp_sha_setkey()
306 sg_init_one(&ctx->u.sha.opad_sg, ctx->u.sha.opad, block_size); in ccp_sha_setkey()
H A Dccp-crypto.h195 u8 opad[MAX_SHA_BLOCK_SIZE]; member
H A Dccp-ops.c1761 if (sha->final && sha->opad) { in ccp_run_sha_cmd()
1779 scatterwalk_map_and_copy(hmac_buf, sha->opad, 0, block_size, 0); in ccp_run_sha_cmd()
1811 hmac_cmd.u.sha.opad = NULL; in ccp_run_sha_cmd()
/linux/drivers/crypto/aspeed/
H A Daspeed-hace.h167 u8 opad[SHA512_BLOCK_SIZE]; member
H A Daspeed-hace-hash.c365 memcpy(rctx->buffer, bctx->opad, rctx->block_size); in aspeed_ahash_hmac_resume()
778 memcpy(bctx->opad, bctx->ipad, bs); in aspeed_sham_setkey()
782 bctx->opad[i] ^= HMAC_OPAD_VALUE; in aspeed_sham_setkey()
/linux/include/linux/
H A Dccp.h294 struct scatterlist *opad; member
/linux/drivers/crypto/
H A Datmel-sha.c1664 u32 opad[SHA512_BLOCK_SIZE / sizeof(u32)]; member
1771 unsafe_memcpy(hmac->opad, hmac->ipad, bs, in atmel_sha_hmac_compute_ipad_hash()
1775 hmac->opad[i] ^= 0x5c5c5c5c; in atmel_sha_hmac_compute_ipad_hash()
1794 return atmel_sha_cpu_hash(dd, hmac->opad, bs, false, in atmel_sha_hmac_compute_opad_hash()
1808 hmac->opad[i] = atmel_sha_read(dd, SHA_REG_DIGEST(i)); in atmel_sha_hmac_setup_done()
1907 atmel_sha_write(dd, SHA_REG_DIN(i), hmac->opad[i]); in atmel_sha_hmac_final()
1989 atmel_sha_write(dd, SHA_REG_DIN(i), hmac->opad[i]); in atmel_sha_hmac_digest2()
2317 atmel_sha_write(dd, SHA_REG_DIN(i), hmac->opad[i]); in atmel_sha_authenc_init2()
/linux/drivers/crypto/bcm/
H A Dcipher.h216 u8 opad[MAX_HASH_BLOCK_SIZE]; member
/linux/drivers/crypto/cavium/nitrox/
H A Dnitrox_req.h147 u8 opad[64]; member
/linux/drivers/crypto/inside-secure/
H A Dsafexcel.h852 } ipad, opad; member
H A Dsafexcel_cipher.c712 ctx->state_sz) / sizeof(u32), &ctx->base.opad, in safexcel_send_req()