Home
last modified time | relevance | path

Searched refs:nlen (Results 1 – 25 of 179) sorted by relevance

12345678

/freebsd/contrib/nvi/common/
H A Dmem.h20 #define BINC_GOTO(sp, type, lp, llen, nlen) do { \ argument
23 if ((nlen) > llen) { \
24 if ((L__bincp = binc(sp, lp, &(llen), nlen)) == NULL) \
33 #define BINC_GOTOC(sp, lp, llen, nlen) \ argument
34 BINC_GOTO(sp, char, lp, llen, nlen)
35 #define BINC_GOTOW(sp, lp, llen, nlen) \ argument
36 BINC_GOTO(sp, CHAR_T, lp, llen, (nlen) * sizeof(CHAR_T))
37 #define BINC_RET(sp, type, lp, llen, nlen) do { \ argument
40 if ((nlen) > llen) { \
41 if ((L__bincp = binc(sp, lp, &(llen), nlen)) == NULL) \
[all …]
H A Dkey.h13 #define FILE2INT5(sp,buf,n,nlen,w,wlen) \ argument
14 sp->conv.file2int(sp, n, nlen, &buf, &wlen, &w)
15 #define INT2FILE(sp,w,wlen,n,nlen) \ argument
16 sp->conv.int2file(sp, w, wlen, &sp->cw, &nlen, &n)
17 #define CHAR2INT5(sp,buf,n,nlen,w,wlen) \ argument
18 sp->conv.sys2int(sp, n, nlen, &buf, &wlen, &w)
19 #define INT2CHAR(sp,w,wlen,n,nlen) \ argument
20 sp->conv.int2sys(sp, w, wlen, &sp->cw, &nlen, &n)
21 #define INPUT2INT5(sp,cw,n,nlen,w,wlen) \ argument
22 sp->conv.input2int(sp, n, nlen, &(cw), &wlen, &w)
[all …]
/freebsd/contrib/bearssl/src/ec/
H A Decdsa_i15_sign_raw.c49 size_t hash_len, nlen, ulen; in br_ecdsa_i15_sign_raw() local
81 nlen = cd->order_len; in br_ecdsa_i15_sign_raw()
82 br_i15_decode(n, cd->order, nlen); in br_ecdsa_i15_sign_raw()
116 br_i15_encode(tt, nlen, x); in br_ecdsa_i15_sign_raw()
117 br_i15_encode(tt + nlen, nlen, m); in br_ecdsa_i15_sign_raw()
118 br_hmac_drbg_init(&drbg, hf, tt, nlen << 1); in br_ecdsa_i15_sign_raw()
120 br_hmac_drbg_generate(&drbg, tt, nlen); in br_ecdsa_i15_sign_raw()
121 br_ecdsa_i15_bits2int(k, tt, nlen, n[0]); in br_ecdsa_i15_sign_raw()
136 br_i15_encode(tt, nlen, k); in br_ecdsa_i15_sign_raw()
137 ulen = impl->mulgen(eU, tt, nlen, sk->curve); in br_ecdsa_i15_sign_raw()
[all …]
H A Decdsa_i31_sign_raw.c49 size_t hash_len, nlen, ulen; in br_ecdsa_i31_sign_raw() local
80 nlen = cd->order_len; in br_ecdsa_i31_sign_raw()
81 br_i31_decode(n, cd->order, nlen); in br_ecdsa_i31_sign_raw()
115 br_i31_encode(tt, nlen, x); in br_ecdsa_i31_sign_raw()
116 br_i31_encode(tt + nlen, nlen, m); in br_ecdsa_i31_sign_raw()
117 br_hmac_drbg_init(&drbg, hf, tt, nlen << 1); in br_ecdsa_i31_sign_raw()
119 br_hmac_drbg_generate(&drbg, tt, nlen); in br_ecdsa_i31_sign_raw()
120 br_ecdsa_i31_bits2int(k, tt, nlen, n[0]); in br_ecdsa_i31_sign_raw()
135 br_i31_encode(tt, nlen, k); in br_ecdsa_i31_sign_raw()
136 ulen = impl->mulgen(eU, tt, nlen, sk->curve); in br_ecdsa_i31_sign_raw()
[all …]
H A Decdsa_i31_vrfy_raw.c47 size_t nlen, rlen, ulen; in br_ecdsa_i31_vrfy_raw() local
93 nlen = cd->order_len; in br_ecdsa_i31_vrfy_raw()
94 br_i31_decode(n, cd->order, nlen); in br_ecdsa_i31_vrfy_raw()
116 memcpy(tx, cd->order, nlen); in br_ecdsa_i31_vrfy_raw()
117 tx[nlen - 1] -= 2; in br_ecdsa_i31_vrfy_raw()
118 br_i31_modpow(s, tx, nlen, n, n0i, t1, t2); in br_ecdsa_i31_vrfy_raw()
134 br_i31_encode(ty, nlen, t2); in br_ecdsa_i31_vrfy_raw()
140 br_i31_encode(tx, nlen, t1); in br_ecdsa_i31_vrfy_raw()
148 tx, nlen, ty, nlen, cd->curve); in br_ecdsa_i31_vrfy_raw()
H A Decdsa_i15_vrfy_raw.c47 size_t nlen, rlen, ulen; in br_ecdsa_i15_vrfy_raw() local
94 nlen = cd->order_len; in br_ecdsa_i15_vrfy_raw()
95 br_i15_decode(n, cd->order, nlen); in br_ecdsa_i15_vrfy_raw()
117 memcpy(tx, cd->order, nlen); in br_ecdsa_i15_vrfy_raw()
118 tx[nlen - 1] -= 2; in br_ecdsa_i15_vrfy_raw()
119 br_i15_modpow(s, tx, nlen, n, n0i, t1, t2); in br_ecdsa_i15_vrfy_raw()
135 br_i15_encode(ty, nlen, t2); in br_ecdsa_i15_vrfy_raw()
141 br_i15_encode(tx, nlen, t1); in br_ecdsa_i15_vrfy_raw()
149 tx, nlen, ty, nlen, cd->curve); in br_ecdsa_i15_vrfy_raw()
/freebsd/contrib/bearssl/src/rsa/
H A Drsa_i31_pub.c39 size_t nlen; in br_rsa_i31_public() local
51 nlen = pk->nlen; in br_rsa_i31_public()
52 while (nlen > 0 && *n == 0) { in br_rsa_i31_public()
54 nlen --; in br_rsa_i31_public()
56 if (nlen == 0 || nlen > (BR_MAX_RSA_SIZE >> 3) || xlen != nlen) { in br_rsa_i31_public()
59 z = (long)nlen << 3; in br_rsa_i31_public()
82 br_i31_decode(m, n, nlen); in br_rsa_i31_public()
H A Drsa_i15_pub.c39 size_t nlen; in br_rsa_i15_public() local
52 nlen = pk->nlen; in br_rsa_i15_public()
53 while (nlen > 0 && *n == 0) { in br_rsa_i15_public()
55 nlen --; in br_rsa_i15_public()
57 if (nlen == 0 || nlen > (BR_MAX_RSA_SIZE >> 3) || xlen != nlen) { in br_rsa_i15_public()
60 z = (long)nlen << 3; in br_rsa_i15_public()
89 br_i15_decode(m, n, nlen); in br_rsa_i15_public()
H A Drsa_i62_pub.c41 size_t nlen; in br_rsa_i62_public() local
53 nlen = pk->nlen; in br_rsa_i62_public()
54 while (nlen > 0 && *n == 0) { in br_rsa_i62_public()
56 nlen --; in br_rsa_i62_public()
58 if (nlen == 0 || nlen > (BR_MAX_RSA_SIZE >> 3) || xlen != nlen) { in br_rsa_i62_public()
61 z = (long)nlen << 3; in br_rsa_i62_public()
82 br_i31_decode(m, n, nlen); in br_rsa_i62_public()
H A Drsa_i32_pub.c33 size_t nlen; in br_rsa_i32_public() local
45 nlen = pk->nlen; in br_rsa_i32_public()
46 while (nlen > 0 && *n == 0) { in br_rsa_i32_public()
48 nlen --; in br_rsa_i32_public()
50 if (nlen == 0 || nlen > (BR_MAX_RSA_SIZE >> 3) || xlen != nlen) { in br_rsa_i32_public()
53 br_i32_decode(m, n, nlen); in br_rsa_i32_public()
H A Drsa_i15_modulus.c34 size_t nlen, plen, qlen, tlen; in br_rsa_i15_compute_modulus() local
92 nlen = (sk->n_bitlen + 7) >> 3; in br_rsa_i15_compute_modulus()
96 br_i15_encode(n, nlen, t); in br_rsa_i15_compute_modulus()
98 return nlen; in br_rsa_i15_compute_modulus()
H A Drsa_i31_modulus.c34 size_t nlen, plen, qlen, tlen; in br_rsa_i31_compute_modulus() local
92 nlen = (sk->n_bitlen + 7) >> 3; in br_rsa_i31_compute_modulus()
96 br_i31_encode(n, nlen, t); in br_rsa_i31_compute_modulus()
98 return nlen; in br_rsa_i31_compute_modulus()
/freebsd/contrib/bearssl/tools/
H A Dvector.c46 size_t nlen; in vector_expand() local
52 nlen = (*len << 1); in vector_expand()
53 if (nlen - *ptr < extra) { in vector_expand()
54 nlen = extra + *ptr; in vector_expand()
55 if (nlen < 8) { in vector_expand()
56 nlen = 8; in vector_expand()
59 nbuf = xmalloc(nlen * esize); in vector_expand()
64 *len = nlen; in vector_expand()
/freebsd/sys/crypto/aesni/
H A Daesni_ccm.c192 unsigned char *tag, uint32_t nbytes, uint32_t abytes, int nlen, in AES_CCM_encrypt() argument
202 if (nlen < 7 || nlen > 13) in AES_CCM_encrypt()
203 panic("%s: bad nonce length %d", __FUNCTION__, nlen); in AES_CCM_encrypt()
212 L = sizeof(__m128i) - 1 - nlen; in AES_CCM_encrypt()
219 rolling_mac = cbc_mac_start(addt, abytes, nonce, nlen, in AES_CCM_encrypt()
225 bcopy(nonce, &byte_ptr[1], nlen); in AES_CCM_encrypt()
362 const unsigned char *tag, uint32_t nbytes, uint32_t abytes, int nlen, in AES_CCM_decrypt() argument
369 if (nlen < 0 || nlen > 15) in AES_CCM_decrypt()
370 panic("%s: bad nonce length %d", __FUNCTION__, nlen); in AES_CCM_decrypt()
378 L = sizeof(__m128i) - 1 - nlen; in AES_CCM_decrypt()
[all …]
/freebsd/crypto/openssl/providers/implementations/kem/
H A Drsa_kem.c249 size_t nlen; in rsasve_generate() local
252 nlen = RSA_size(prsactx->rsa); in rsasve_generate()
255 if (nlen == 0) { in rsasve_generate()
262 *outlen = nlen; in rsasve_generate()
264 *secretlen = nlen; in rsasve_generate()
271 if (!rsasve_gen_rand_bytes(prsactx->rsa, secret, nlen)) in rsasve_generate()
275 ret = RSA_public_encrypt(nlen, secret, out, prsactx->rsa, RSA_NO_PADDING); in rsasve_generate()
279 *outlen = nlen; in rsasve_generate()
281 *secretlen = nlen; in rsasve_generate()
283 OPENSSL_cleanse(secret, nlen); in rsasve_generate()
[all …]
/freebsd/sys/compat/linux/
H A Dlinux_sysctl.c114 if (la.nlen <= 0 || la.nlen > LINUX_CTL_MAXNAME) { in linux_sysctl()
115 LIN_SDT_PROBE2(sysctl, linux_sysctl, wrong_length, la.nlen, in linux_sysctl()
120 mib = malloc(la.nlen * sizeof(l_int), M_LINUX, M_WAITOK); in linux_sysctl()
121 error = copyin(PTRIN(la.name), mib, la.nlen * sizeof(l_int)); in linux_sysctl()
130 if (la.nlen < 2) in linux_sysctl()
146 sb = sbuf_new(NULL, NULL, 20 + la.nlen * 5, SBUF_AUTOEXTEND); in linux_sysctl()
153 for (i = 0; i < la.nlen; i++) in linux_sysctl()
/freebsd/contrib/wpa/src/utils/
H A Dext_password_test.c48 size_t nlen; in ext_password_test_get() local
55 nlen = os_strlen(name); in ext_password_test_get()
58 if (os_strncmp(pos, name, nlen) == 0 && pos[nlen] == '=') { in ext_password_test_get()
60 pos += nlen + 1; in ext_password_test_get()
/freebsd/contrib/ntp/sntp/
H A Dnetworking.c79 u_int nlen; /* next extension length */ in skip_efields() local
81 nlen = ntohl(*head) & 0xffff; in skip_efields()
83 nlen = (nlen + 3) >> 2; in skip_efields()
84 if (nlen > (u_int)(tail - head) || nlen < 4) in skip_efields()
86 head += nlen; in skip_efields()
/freebsd/stand/libofw/
H A Dofw_copy.c50 size_t nlen; in ofw_mapmem() local
54 nlen = len; in ofw_mapmem()
69 nlen -= (last_dest + last_len) - dest; in ofw_mapmem()
80 if ((nlen + resid) < PAGE_SIZE*MAPMEM_PAGE_INC) { in ofw_mapmem()
83 dlen = roundup(nlen + resid, PAGE_SIZE); in ofw_mapmem()
/freebsd/usr.bin/systat/
H A Dfetch.c60 size_t nlen = len; in getsysctl() local
62 if (sysctlbyname(name, ptr, &nlen, NULL, 0) != 0) { in getsysctl()
66 if (nlen != len) { in getsysctl()
67 error("sysctl(%s...) expected %zu, got %zu", name, len, nlen); in getsysctl()
/freebsd/contrib/nvi/vi/
H A Dv_txt.c1741 size_t nlen; in v_txt_auto() local
1765 if ((nlen = (p - t)) == 0) in v_txt_auto()
1769 BINC_RETW(sp, tp->lb, tp->lb_len, tp->len + nlen); in v_txt_auto()
1773 MEMMOVE(tp->lb + nlen, tp->lb, tp->len); in v_txt_auto()
1774 tp->len += nlen; in v_txt_auto()
1777 MEMMOVE(tp->lb, t, nlen); in v_txt_auto()
1780 tp->ai = nlen; in v_txt_auto()
1973 size_t indx, len, nlen, off; in txt_fc() local
2035 nlen = STRLEN(cmd.argv[0]->bp); in txt_fc()
2043 for (nlen = cmd.argv[0]->len; --argc > 0;) { in txt_fc()
[all …]
/freebsd/crypto/heimdal/lib/roken/
H A Dsnprintf.c148 int nstart, nlen; in append_number() local
159 nlen = 0; in append_number()
164 ++nlen; in append_number()
170 nlen--; in append_number()
194 if(prec <= nlen && nstr[nstart] != '0' && nstr[nstart] != '\0') in append_number()
195 prec = nlen + 1; in append_number()
207 if(prec > nlen) in append_number()
210 width -= nlen; in append_number()
232 if(prec - nlen > width - len - nlen) in append_number()
233 len += pad(state, prec - nlen, '0'); in append_number()
[all …]
/freebsd/contrib/nvi/ex/
H A Dex_args.c50 size_t nlen; in ex_next() local
90 INT2CHAR(sp, argv[0]->bp, argv[0]->len, np, nlen); in ex_next()
91 if ((*ap = v_strdup(sp, np, nlen)) == NULL) in ex_next()
132 size_t nlen; in ex_N_next() local
143 INT2CHAR(sp, cmdp->argv[0]->bp, cmdp->argv[0]->len + 1, np, nlen); in ex_N_next()
306 size_t nlen; in ex_buildargv() local
319 INT2CHAR(sp, argv[0]->bp, argv[0]->len, np, nlen); in ex_buildargv()
320 if ((*ap = v_strdup(sp, np, nlen)) == NULL) in ex_buildargv()
/freebsd/usr.sbin/bsnmpd/modules/snmp_lm75/
H A Dsnmp_lm75.c135 sysctlname(int *oid, int nlen, char *name, size_t len) in sysctlname() argument
139 if (nlen > (int)(sizeof(mib) / sizeof(int) - 2)) in sysctlname()
144 memcpy(mib + 2, oid, nlen * sizeof(int)); in sysctlname()
146 if (sysctl(mib, nlen + 2, name, &len, 0, 0) == -1) in sysctlname()
153 sysctlgetnext(int *oid, int nlen, int *next, size_t *nextlen) in sysctlgetnext() argument
157 if (nlen > (int)(sizeof(mib) / sizeof(int) - 2)) in sysctlgetnext()
162 memcpy(mib + 2, oid, nlen * sizeof(int)); in sysctlgetnext()
164 if (sysctl(mib, nlen + 2, next, nextlen, 0, 0) == -1) in sysctlgetnext()
/freebsd/lib/libkvm/
H A Dkvm_cptime.c67 size_t nlen; in getsysctl() local
69 nlen = len; in getsysctl()
70 if (sysctlbyname(name, buf, &nlen, NULL, 0) < 0) { in getsysctl()
75 if (nlen != len) { in getsysctl()

12345678