Home
last modified time | relevance | path

Searched refs:mlen (Results 1 – 5 of 5) sorted by relevance

/hal_espressif-latest/components/bt/porting/ext/tinycrypt/src/
Dccm_mode.c40 unsigned int nlen, unsigned int mlen) in tc_ccm_config() argument
50 } else if ((mlen < 4) || (mlen > 16) || (mlen & 1)) { in tc_ccm_config()
54 c->mlen = mlen; in tc_ccm_config()
150 (olen < (plen + c->mlen))) { /* invalid output buffer size */ in tc_ccm_generation_encryption()
161 b[0] = ((alen > 0) ? 0x40:0) | (((c->mlen - 2) / 2 << 3)) | (1); in tc_ccm_generation_encryption()
191 for (i = 0; i < c->mlen; ++i) { in tc_ccm_generation_encryption()
211 (olen < plen - c->mlen)) { /* invalid output buffer size */ in tc_ccm_decryption_verification()
229 ccm_ctr_mode(out, plen - c->mlen, payload, plen - c->mlen, b, c->sched); in tc_ccm_decryption_verification()
235 for (i = 0; i < c->mlen; ++i) { in tc_ccm_decryption_verification()
236 tag[i] = *(payload + plen - c->mlen + i) ^ b[i]; in tc_ccm_decryption_verification()
[all …]
/hal_espressif-latest/components/bt/esp_ble_mesh/mesh_common/tinycrypt/src/
Dccm_mode.c40 unsigned int nlen, unsigned int mlen) in tc_ccm_config() argument
50 } else if ((mlen < 4) || (mlen > 16) || (mlen & 1)) { in tc_ccm_config()
54 c->mlen = mlen; in tc_ccm_config()
150 (olen < (plen + c->mlen))) { /* invalid output buffer size */ in tc_ccm_generation_encryption()
161 b[0] = ((alen > 0) ? 0x40 : 0) | (((c->mlen - 2) / 2 << 3)) | (1); in tc_ccm_generation_encryption()
191 for (i = 0; i < c->mlen; ++i) { in tc_ccm_generation_encryption()
211 (olen < plen - c->mlen)) { /* invalid output buffer size */ in tc_ccm_decryption_verification()
229 ccm_ctr_mode(out, plen - c->mlen, payload, plen - c->mlen, b, c->sched); in tc_ccm_decryption_verification()
235 for (i = 0; i < c->mlen; ++i) { in tc_ccm_decryption_verification()
236 tag[i] = *(payload + plen - c->mlen + i) ^ b[i]; in tc_ccm_decryption_verification()
[all …]
/hal_espressif-latest/components/wpa_supplicant/src/crypto/
Dccmp.c144 size_t mlen; in ccmp_decrypt() local
155 mlen = data_len - 8 - 8; in ccmp_decrypt()
169 if (aes_ccm_ad(tk, 16, nonce, tag_len, data + 8, mlen, aad, aad_len, in ccmp_decrypt()
170 data + 8 + mlen, plain) < 0) { in ccmp_decrypt()
174 wpa_hexdump(MSG_MSGDUMP, "CCMP decrypted", plain, mlen); in ccmp_decrypt()
176 *decrypted_len = mlen; in ccmp_decrypt()
287 size_t mlen; in ccmp_256_decrypt() local
297 mlen = data_len - 8 - 16; in ccmp_256_decrypt()
305 if (aes_ccm_ad(tk, 32, nonce, 16, data + 8, mlen, aad, aad_len, in ccmp_256_decrypt()
306 data + 8 + mlen, plain) < 0) { in ccmp_256_decrypt()
[all …]
/hal_espressif-latest/components/bt/porting/ext/tinycrypt/include/tinycrypt/
Dccm_mode.h94 unsigned int mlen; /* mac length in bytes (parameter t in SP-800 38C) */ member
112 unsigned int nlen, unsigned int mlen);
/hal_espressif-latest/components/bt/esp_ble_mesh/mesh_common/tinycrypt/include/tinycrypt/
Dccm_mode.h94 unsigned int mlen; /* mac length in bytes (parameter t in SP-800 38C) */ member
112 unsigned int nlen, unsigned int mlen);