Home
last modified time | relevance | path

Searched refs:padlen (Results 1 – 19 of 19) sorted by relevance

/optee_os-3.20.0/core/lib/libtomcrypt/src/modes/cfb/
A Dcfb_encrypt.c34 cfb->padlen < 0 || cfb->padlen > (int)sizeof(cfb->pad)) { in cfb_encrypt()
39 if (cfb->padlen == cfb->blocklen) { in cfb_encrypt()
43 cfb->padlen = 0; in cfb_encrypt()
45 cfb->pad[cfb->padlen] = (*ct = *pt ^ cfb->IV[cfb->padlen]); in cfb_encrypt()
48 ++(cfb->padlen); in cfb_encrypt()
A Dcfb_decrypt.c34 cfb->padlen < 0 || cfb->padlen > (int)sizeof(cfb->pad)) { in cfb_decrypt()
39 if (cfb->padlen == cfb->blocklen) { in cfb_decrypt()
43 cfb->padlen = 0; in cfb_decrypt()
45 cfb->pad[cfb->padlen] = *ct; in cfb_decrypt()
46 *pt = *ct ^ cfb->IV[cfb->padlen]; in cfb_decrypt()
49 ++(cfb->padlen); in cfb_decrypt()
A Dcfb_setiv.c35 cfb->padlen = 0; in cfb_setiv()
A Dcfb_start.c50 cfb->padlen = 0; in cfb_start()
/optee_os-3.20.0/core/lib/libtomcrypt/src/modes/ctr/
A Dctr_encrypt.c47 if (ctr->padlen == ctr->blocklen) { in s_ctr_encrypt()
52 ctr->padlen = 0; in s_ctr_encrypt()
55 if ((ctr->padlen == 0) && (len >= (unsigned long)ctr->blocklen)) { in s_ctr_encrypt()
63 ctr->padlen = ctr->blocklen; in s_ctr_encrypt()
67 *ct++ = *pt++ ^ ctr->pad[ctr->padlen++]; in s_ctr_encrypt()
71 if (ctr->padlen == ctr->blocklen) { in s_ctr_encrypt()
101 (ctr->padlen < 0) || (ctr->padlen > (int)sizeof(ctr->pad))) { in ctr_encrypt()
113 … if ((ctr->padlen == 0 || ctr->padlen == ctr->blocklen) && len >= (unsigned long)ctr->blocklen) { in ctr_encrypt()
121 ctr->padlen = ctr->blocklen; in ctr_encrypt()
125 incr = ctr->blocklen - ctr->padlen; in ctr_encrypt()
A Dctr_setiv.c39 ctr->padlen = 0; in ctr_setiv()
A Dctr_start.c59 ctr->padlen = 0; in ctr_start()
/optee_os-3.20.0/core/lib/libtomcrypt/src/modes/ofb/
A Dofb_encrypt.c32 ofb->padlen < 0 || ofb->padlen > (int)sizeof(ofb->IV)) { in ofb_encrypt()
37 if (ofb->padlen == ofb->blocklen) { in ofb_encrypt()
41 ofb->padlen = 0; in ofb_encrypt()
43 *ct++ = *pt++ ^ ofb->IV[(ofb->padlen)++]; in ofb_encrypt()
A Dofb_setiv.c35 ofb->padlen = 0; in ofb_setiv()
A Dofb_start.c44 ofb->padlen = ofb->blocklen; in ofb_start()
/optee_os-3.20.0/core/lib/libtomcrypt/src/modes/f8/
A Df8_encrypt.c33 f8->padlen < 0 || f8->padlen > (int)sizeof(f8->IV)) { in f8_encrypt()
40 if (f8->padlen == f8->blocklen) { in f8_encrypt()
50 f8->padlen = 0; in f8_encrypt()
54 if (f8->padlen == 0) { in f8_encrypt()
73 if (f8->padlen == f8->blocklen) { in f8_encrypt()
83 f8->padlen = 0; in f8_encrypt()
85 *ct++ = *pt++ ^ f8->IV[f8->padlen++]; in f8_encrypt()
A Df8_setiv.c35 f8->padlen = 0; in f8_setiv()
A Df8_start.c52 f8->padlen = f8->blocklen; in f8_start()
/optee_os-3.20.0/core/lib/libtomcrypt/src/encauth/chachapoly/
A Dchacha20poly1305_encrypt.c19 unsigned long padlen; in chacha20poly1305_encrypt() local
26 padlen = 16 - (unsigned long)(st->aadlen % 16); in chacha20poly1305_encrypt()
27 if (padlen < 16) { in chacha20poly1305_encrypt()
28 if ((err = poly1305_process(&st->poly, padzero, padlen)) != CRYPT_OK) return err; in chacha20poly1305_encrypt()
A Dchacha20poly1305_decrypt.c19 unsigned long padlen; in chacha20poly1305_decrypt() local
25 padlen = 16 - (unsigned long)(st->aadlen % 16); in chacha20poly1305_decrypt()
26 if (padlen < 16) { in chacha20poly1305_decrypt()
27 if ((err = poly1305_process(&st->poly, padzero, padlen)) != CRYPT_OK) return err; in chacha20poly1305_decrypt()
A Dchacha20poly1305_done.c18 unsigned long padlen; in chacha20poly1305_done() local
24 padlen = 16 - (unsigned long)(st->ctlen % 16); in chacha20poly1305_done()
25 if (padlen < 16) { in chacha20poly1305_done()
26 if ((err = poly1305_process(&st->poly, padzero, padlen)) != CRYPT_OK) return err; in chacha20poly1305_done()
/optee_os-3.20.0/lib/libmbedtls/mbedtls/library/
A Dnist_kw.c149 size_t olen, padlen = 0; in mbedtls_nist_kw_wrap() local
185 padlen = ( 8 - ( in_len % 8 ) ); in mbedtls_nist_kw_wrap()
188 if( out_size < in_len + KW_SEMIBLOCK_LENGTH + padlen ) in mbedtls_nist_kw_wrap()
211 memset( output + KW_SEMIBLOCK_LENGTH + in_len, 0, padlen ); in mbedtls_nist_kw_wrap()
213 semiblocks = ( ( in_len + padlen ) / KW_SEMIBLOCK_LENGTH ) + 1; in mbedtls_nist_kw_wrap()
393 size_t padlen = 0; in mbedtls_nist_kw_unwrap() local
445 padlen = in_len - KW_SEMIBLOCK_LENGTH - Plen; in mbedtls_nist_kw_unwrap()
446 if ( padlen > 7 ) in mbedtls_nist_kw_unwrap()
448 padlen &= 7; in mbedtls_nist_kw_unwrap()
455 if( i >= KW_SEMIBLOCK_LENGTH - padlen ) in mbedtls_nist_kw_unwrap()
[all …]
A Dssl_msg.c497 int padlen; in ssl_mac() local
504 padlen = 48; in ssl_mac()
506 padlen = 40; in ssl_mac()
955 size_t padlen, i; in mbedtls_ssl_encrypt_buf() local
962 padlen = 0; in mbedtls_ssl_encrypt_buf()
975 post_avail -= padlen + 1; in mbedtls_ssl_encrypt_buf()
1171 padlen = 0; in mbedtls_ssl_decrypt_buf()
1488 padlen &= mask; in mbedtls_ssl_decrypt_buf()
1508 padlen &= mask; in mbedtls_ssl_decrypt_buf()
1511 padlen++; in mbedtls_ssl_decrypt_buf()
[all …]
/optee_os-3.20.0/core/lib/libtomcrypt/src/headers/
A Dtomcrypt_cipher.h265 padlen; member
283 padlen; member
314 padlen, member
363 padlen; member

Completed in 24 milliseconds