Searched refs:clen (Results 1 - 25 of 192) sorted by relevance

12345678

/freebsd-current/sys/contrib/libsodium/test/default/
H A Donetimeauth7.c12 int clen; local
14 for (clen = 0; clen < 1000; ++clen) {
16 randombytes_buf(c, clen);
17 crypto_onetimeauth(a, c, clen, key);
18 if (crypto_onetimeauth_verify(a, c, clen, key) != 0) {
19 printf("fail %d\n", clen);
22 if (clen > 0) {
23 c[rand() % clen]
[all...]
H A Dauth7.c12 size_t clen; local
14 for (clen = 0; clen < sizeof c; ++clen) {
16 randombytes_buf(c, clen);
17 crypto_auth_hmacsha512(a, c, clen, key);
18 if (crypto_auth_hmacsha512_verify(a, c, clen, key) != 0) {
19 printf("fail %u\n", (unsigned int) clen);
22 if (clen > 0) {
23 c[(size_t) rand() % clen]
[all...]
H A Dauth5.c12 size_t clen; local
14 for (clen = 0; clen < 1000; ++clen) {
16 randombytes_buf(c, clen);
17 crypto_auth(a, c, clen, key);
18 if (crypto_auth_verify(a, c, clen, key) != 0) {
19 printf("fail %u\n", (unsigned int) clen);
22 if (clen > 0) {
23 c[rand() % clen]
[all...]
/freebsd-current/bin/ls/
H A Dutil.c57 size_t clen; local
61 while ((clen = mbrtowc(&wc, s, MB_LEN_MAX, &mbs)) != 0) {
62 if (clen == (size_t)-2) {
66 if (clen == (size_t)-1) {
73 for (i = 0; i < (int)clen; i++)
75 s += clen;
88 size_t clen; local
92 while ((clen = mbrtowc(&wc, s, MB_LEN_MAX, &mbs)) != 0) {
93 if (clen == (size_t)-1) {
100 if (clen
137 size_t clen, r; local
169 size_t clen; local
[all...]
/freebsd-current/contrib/bearssl/src/rand/
H A Daesctr_drbg.c52 size_t clen; local
60 clen = len;
61 if (clen > 65280) {
62 clen = 65280;
69 if ((uint32_t)(ctx->cc + ((clen + 15) >> 4)) > 32768) {
70 clen = (32768 - ctx->cc) << 4;
71 if (clen > len) {
72 clen = len;
79 memset(buf, 0, clen);
81 iv, ctx->cc, buf, clen);
161 size_t clen; local
[all...]
/freebsd-current/contrib/wpa/src/crypto/
H A Dsha256-tlsprf.c32 size_t clen; local
63 clen = outlen - pos;
64 if (clen > SHA256_MAC_LEN)
65 clen = SHA256_MAC_LEN;
66 os_memcpy(out + pos, P, clen);
67 pos += clen;
H A Dsha384-tlsprf.c32 size_t clen; local
63 clen = outlen - pos;
64 if (clen > SHA384_MAC_LEN)
65 clen = SHA384_MAC_LEN;
66 os_memcpy(out + pos, P, clen);
67 pos += clen;
H A Dsha384-kdf.c40 size_t pos, clen; local
61 clen = outlen - pos;
62 if (clen > SHA384_MAC_LEN)
63 clen = SHA384_MAC_LEN;
64 os_memcpy(out + pos, T, clen);
65 pos += clen;
H A Dsha512-kdf.c40 size_t pos, clen; local
61 clen = outlen - pos;
62 if (clen > SHA512_MAC_LEN)
63 clen = SHA512_MAC_LEN;
64 os_memcpy(out + pos, T, clen);
65 pos += clen;
H A Dsha256-kdf.c40 size_t pos, clen; local
61 clen = outlen - pos;
62 if (clen > SHA256_MAC_LEN)
63 clen = SHA256_MAC_LEN;
64 os_memcpy(out + pos, T, clen);
65 pos += clen;
/freebsd-current/sys/contrib/libsodium/src/libsodium/crypto_stream/chacha20/
H A Dstream_chacha20.h8 int (*stream)(unsigned char *c, unsigned long long clen,
10 int (*stream_ietf)(unsigned char *c, unsigned long long clen,
/freebsd-current/sys/contrib/libsodium/src/libsodium/crypto_box/
H A Dcrypto_box_easy.c66 unsigned long long clen,
70 return crypto_secretbox_open_detached(m, c, mac, clen, n, k);
76 unsigned long long clen, const unsigned char *n,
85 ret = crypto_box_open_detached_afternm(m, c, mac, clen, n, k);
93 unsigned long long clen, const unsigned char *n,
96 if (clen < crypto_box_MACBYTES) {
100 clen - crypto_box_MACBYTES,
106 unsigned long long clen, const unsigned char *n,
109 if (clen < crypto_box_MACBYTES) {
113 clen
64 crypto_box_open_detached_afternm(unsigned char *m, const unsigned char *c, const unsigned char *mac, unsigned long long clen, const unsigned char *n, const unsigned char *k) argument
74 crypto_box_open_detached(unsigned char *m, const unsigned char *c, const unsigned char *mac, unsigned long long clen, const unsigned char *n, const unsigned char *pk, const unsigned char *sk) argument
92 crypto_box_open_easy_afternm(unsigned char *m, const unsigned char *c, unsigned long long clen, const unsigned char *n, const unsigned char *k) argument
105 crypto_box_open_easy(unsigned char *m, const unsigned char *c, unsigned long long clen, const unsigned char *n, const unsigned char *pk, const unsigned char *sk) argument
[all...]
/freebsd-current/contrib/bearssl/src/kdf/
H A Dhkdf.c76 size_t clen; local
96 clen = hc->dig_len - hc->ptr;
97 if (clen > out_len) {
98 clen = out_len;
100 memcpy(out, hc->buf + hc->ptr, clen);
101 out = (unsigned char *)out + clen;
102 out_len -= clen;
103 hc->ptr += clen;
104 tlen += clen;
/freebsd-current/sys/contrib/libsodium/src/libsodium/crypto_secretbox/xsalsa20poly1305/
H A Dsecretbox_xsalsa20poly1305.c27 unsigned long long clen,
34 if (clen < 32) {
39 clen - 32, subkey) != 0) {
42 crypto_stream_xsalsa20_xor(m, c, clen, n, k);
26 crypto_secretbox_xsalsa20poly1305_open(unsigned char *m, const unsigned char *c, unsigned long long clen, const unsigned char *n, const unsigned char *k) argument
/freebsd-current/sys/contrib/libsodium/src/libsodium/crypto_stream/salsa20/
H A Dstream_salsa20.h8 int (*stream)(unsigned char *c, unsigned long long clen,
/freebsd-current/usr.bin/hexdump/
H A Dconv.c50 size_t clen, oclen; local
101 clen = mbrtowc(&wc, p, bufsize, &pr->mbstate);
102 if (clen == 0)
103 clen = 1;
104 else if (clen == (size_t)-1 || (clen == (size_t)-2 &&
117 clen = 1;
119 } else if (clen == (size_t)-2) {
129 clen += oclen;
132 clen
[all...]
/freebsd-current/sys/contrib/libsodium/src/libsodium/crypto_stream/
H A Dcrypto_stream.c30 crypto_stream(unsigned char *c, unsigned long long clen, argument
33 return crypto_stream_xsalsa20(c, clen, n, k);
/freebsd-current/sys/contrib/libsodium/src/libsodium/crypto_aead/xchacha20poly1305/sodium/
H A Daead_xchacha20poly1305.c53 unsigned long long clen = 0ULL; local
63 clen = mlen + crypto_aead_xchacha20poly1305_ietf_ABYTES;
65 *clen_p = clen;
74 unsigned long long clen,
89 (m, nsec, c, clen, mac, ad, adlen, npub2, k2);
101 unsigned long long clen,
110 if (clen >= crypto_aead_xchacha20poly1305_ietf_ABYTES) {
113 c, clen - crypto_aead_xchacha20poly1305_ietf_ABYTES,
114 c + clen - crypto_aead_xchacha20poly1305_ietf_ABYTES,
119 mlen = clen
71 crypto_aead_xchacha20poly1305_ietf_decrypt_detached(unsigned char *m, unsigned char *nsec, const unsigned char *c, unsigned long long clen, const unsigned char *mac, const unsigned char *ad, unsigned long long adlen, const unsigned char *npub, const unsigned char *k) argument
97 crypto_aead_xchacha20poly1305_ietf_decrypt(unsigned char *m, unsigned long long *mlen_p, unsigned char *nsec, const unsigned char *c, unsigned long long clen, const unsigned char *ad, unsigned long long adlen, const unsigned char *npub, const unsigned char *k) argument
[all...]
/freebsd-current/sys/contrib/libsodium/src/libsodium/crypto_box/curve25519xchacha20poly1305/
H A Dbox_curve25519xchacha20poly1305.c113 unsigned long long clen, const unsigned char *n, const unsigned char *k)
115 return crypto_secretbox_xchacha20poly1305_open_detached(m, c, mac, clen, n,
122 unsigned long long clen, const unsigned char *n, const unsigned char *pk,
132 m, c, mac, clen, n, k);
140 unsigned char *m, const unsigned char *c, unsigned long long clen,
143 if (clen < crypto_box_curve25519xchacha20poly1305_MACBYTES) {
148 clen - crypto_box_curve25519xchacha20poly1305_MACBYTES, n, k);
153 unsigned char *m, const unsigned char *c, unsigned long long clen,
156 if (clen < crypto_box_curve25519xchacha20poly1305_MACBYTES) {
161 clen
111 crypto_box_curve25519xchacha20poly1305_open_detached_afternm( unsigned char *m, const unsigned char *c, const unsigned char *mac, unsigned long long clen, const unsigned char *n, const unsigned char *k) argument
120 crypto_box_curve25519xchacha20poly1305_open_detached( unsigned char *m, const unsigned char *c, const unsigned char *mac, unsigned long long clen, const unsigned char *n, const unsigned char *pk, const unsigned char *sk) argument
139 crypto_box_curve25519xchacha20poly1305_open_easy_afternm( unsigned char *m, const unsigned char *c, unsigned long long clen, const unsigned char *n, const unsigned char *k) argument
152 crypto_box_curve25519xchacha20poly1305_open_easy( unsigned char *m, const unsigned char *c, unsigned long long clen, const unsigned char *n, const unsigned char *pk, const unsigned char *sk) argument
[all...]
/freebsd-current/contrib/nvi/common/
H A Dput.c37 size_t blen, clen, len; local
121 if (len > 0 && (clen = cp->cno + (append ? 1 : 0)) > 0) {
122 MEMCPY(bp, p, clen);
123 p += clen;
124 t += clen;
134 clen = len == 0 ? 0 : len - (cp->cno + (append ? 1 : 0));
159 if (clen > 0) {
160 MEMCPY(t, p, clen);
161 t += clen;
182 ADD_SPACE_RETW(sp, bp, blen, ltp->len + clen);
[all...]
/freebsd-current/usr.bin/cut/
H A Dcut.c274 int canwrite, clen, warned; local
280 for (col = 0; lbuflen > 0; col += clen) {
281 if ((clen = mbrlen(lbuf, lbuflen, &mbs)) < 0) {
287 clen = 1;
289 if (clen == 0 || *lbuf == '\n')
299 while (i < col + clen && i < maxval &&
302 canwrite = i < col + clen;
303 for (; i < col + clen && i < maxval; i++)
306 fwrite(lbuf, 1, clen, stdout);
313 for (i = col; i < col + clen;
388 size_t clen, bufsize = 0, reallen; local
[all...]
/freebsd-current/contrib/bearssl/src/hash/
H A Dmultihash.c114 size_t clen; local
116 clen = 128 - ptr;
117 if (clen > len) {
118 clen = len;
120 memcpy(ctx->buf + ptr, buf, clen);
121 ptr += clen;
122 buf += clen;
123 len -= clen;
124 ctx->count += (uint64_t)clen;
H A Dmd5sha1.c47 size_t clen; local
49 clen = 64 - ptr;
50 if (clen > len) {
51 clen = len;
53 memcpy(cc->buf + ptr, buf, clen);
54 ptr += clen;
55 buf += clen;
56 len -= clen;
57 cc->count += (uint64_t)clen;
/freebsd-current/sys/contrib/libsodium/src/libsodium/crypto_pwhash/scryptsalsa208sha256/
H A Dpbkdf2-sha256.c57 size_t clen; local
88 clen = dkLen - i * 32;
89 if (clen > 32) {
90 clen = 32;
92 memcpy(&buf[i * 32], T, clen);
/freebsd-current/sys/contrib/libsodium/src/libsodium/crypto_stream/salsa20/ref/
H A Dsalsa20_ref.c19 stream_ref(unsigned char *c, unsigned long long clen, const unsigned char *n, argument
28 if (!clen) {
40 while (clen >= 64) {
48 clen -= 64;
51 if (clen) {
53 for (i = 0; i < (unsigned int) clen; i++) {

Completed in 136 milliseconds

12345678