Searched refs:chacha (Results 1 – 8 of 8) sorted by relevance
/optee_os-3.20.0/core/lib/libtomcrypt/src/prngs/ |
A D | chacha20.c | 35 XMEMSET(&prng->u.chacha.ent, 0, sizeof(prng->u.chacha.ent)); in chacha20_prng_start() 36 prng->u.chacha.idx = 0; in chacha20_prng_start() 64 if ((err = chacha_setup(&prng->u.chacha.s, buf, 32, 20)) != CRYPT_OK) goto LBL_UNLOCK; in chacha20_prng_add_entropy() 66 if ((err = chacha_ivctr64(&prng->u.chacha.s, buf + 32, 8, 0)) != CRYPT_OK) goto LBL_UNLOCK; in chacha20_prng_add_entropy() 72 … while (inlen--) prng->u.chacha.ent[prng->u.chacha.idx++ % sizeof(prng->u.chacha.ent)] ^= *in++; in chacha20_prng_add_entropy() 94 …if ((err = chacha_setup(&prng->u.chacha.s, prng->u.chacha.ent, 32, 20)) != CRYPT_OK) goto LBL… in chacha20_prng_ready() 96 …if ((err = chacha_ivctr64(&prng->u.chacha.s, prng->u.chacha.ent + 32, 8, 0)) != CRYPT_OK) goto LBL… in chacha20_prng_ready() 97 XMEMSET(&prng->u.chacha.ent, 0, sizeof(prng->u.chacha.ent)); in chacha20_prng_ready() 98 prng->u.chacha.idx = 0; in chacha20_prng_ready() 117 if (chacha_keystream(&prng->u.chacha.s, out, outlen) != CRYPT_OK) outlen = 0; in chacha20_prng_read() [all …]
|
/optee_os-3.20.0/core/lib/libtomcrypt/src/encauth/chachapoly/ |
A D | chacha20poly1305_setiv.c | 28 if ((err = chacha_ivctr32(&st->chacha, iv, ivlen, 1)) != CRYPT_OK) return err; in chacha20poly1305_setiv() 32 if ((err = chacha_ivctr64(&st->chacha, iv, ivlen, 1)) != CRYPT_OK) return err; in chacha20poly1305_setiv() 36 for(i = 0; i < 12; i++) tmp_st.input[i] = st->chacha.input[i]; in chacha20poly1305_setiv()
|
A D | chacha20poly1305_init.c | 17 return chacha_setup(&st->chacha, key, keylen, 20); in chacha20poly1305_init()
|
A D | chacha20poly1305_encrypt.c | 24 if ((err = chacha_crypt(&st->chacha, in, inlen, out)) != CRYPT_OK) return err; in chacha20poly1305_encrypt()
|
A D | chacha20poly1305_decrypt.c | 33 if ((err = chacha_crypt(&st->chacha, in, inlen, out)) != CRYPT_OK) return err; in chacha20poly1305_decrypt()
|
A D | chacha20poly1305_done.c | 32 if ((err = chacha_done(&st->chacha)) != CRYPT_OK) return err; in chacha20poly1305_done()
|
/optee_os-3.20.0/core/lib/libtomcrypt/src/headers/ |
A D | tomcrypt_prng.h | 61 struct chacha20_prng chacha; member
|
A D | tomcrypt_mac.h | 542 chacha_state chacha; member
|
Completed in 7 milliseconds