Lines Matching refs:len

187 	size_t len;  in getlength()  local
214 len = 0; in getlength()
216 len = (len << 8) | c[(*p)++]; in getlength()
218 if (len > UINT32_MAX - *p || *p + len > l) { in getlength()
220 __func__, *p, len, l)); in getlength()
223 return CAST(uint32_t, len); in getlength()
227 der_tag(char *buf, size_t len, uint32_t tag) in der_tag() argument
230 strlcpy(buf, der__tag[tag], len); in der_tag()
232 snprintf(buf, len, "%#x", tag); in der_tag()
238 der_data(char *buf, size_t blen, uint32_t tag, const void *q, uint32_t len) in der_data() argument
245 return snprintf(buf, blen, "%.*s", len, RCAST(const char *, q)); in der_data()
247 if (len < 12) in der_data()
257 for (uint32_t i = 0; i < len; i++) { in der_data()
262 return len * 2; in der_data()
269 size_t offs = 0, len = ms->search.s_len ? ms->search.s_len : nbytes; in der_offs() local
271 if (gettag(b, &offs, len) == DER_BAD) { in der_offs()
278 uint32_t tlen = getlength(b, &offs, len); in der_offs()
308 size_t offs = 0, len = ms->search.s_len; in der_cmp() local
312 DPRINTF(("%s: compare %zu bytes\n", __func__, len)); in der_cmp()
314 tag = gettag(b, &offs, len); in der_cmp()
323 tlen = getlength(b, &offs, len); in der_cmp()
377 printtag(uint32_t tag, const void *q, uint32_t len) in printtag() argument
385 printf("%.*s\n", len, (const char *)q); in printtag()
391 for (uint32_t i = 0; i < len; i++) in printtag()
413 uint32_t len = getlength(p, &x, ep - p + x); in printdata() local
418 der_tag(buf, sizeof(buf), tag), len); in printdata()
420 if (p + len > ep) in printdata()
422 printtag(tag, q, len); in printdata()
424 printdata(level + 1, p, x, len + x); in printdata()
425 x += len; in printdata()