Lines Matching refs:len

24 int o2i_SCT_signature(SCT *sct, const unsigned char **in, size_t len)  in o2i_SCT_signature()  argument
27 size_t len_remaining = len; in o2i_SCT_signature()
41 if (len <= 4) { in o2i_SCT_signature()
67 return len - len_remaining; in o2i_SCT_signature()
70 SCT *o2i_SCT(SCT **psct, const unsigned char **in, size_t len) in o2i_SCT() argument
75 if (len == 0 || len > MAX_SCT_SIZE) { in o2i_SCT()
98 if (len < 43) { in o2i_SCT()
102 len -= 43; in o2i_SCT()
113 if (len < len2) { in o2i_SCT()
124 len -= len2; in o2i_SCT()
126 sig_len = o2i_SCT_signature(sct, &p, len); in o2i_SCT()
131 len -= sig_len; in o2i_SCT()
132 *in = p + len; in o2i_SCT()
135 sct->sct = OPENSSL_memdup(p, len); in o2i_SCT()
138 sct->sct_len = len; in o2i_SCT()
139 *in = p + len; in o2i_SCT()
155 size_t len; in i2o_SCT_signature() local
173 len = 4 + sct->sig_len; in i2o_SCT_signature()
178 *out += len; in i2o_SCT_signature()
180 pstart = p = OPENSSL_malloc(len); in i2o_SCT_signature()
192 return len; in i2o_SCT_signature()
200 size_t len; in i2o_SCT() local
214 len = 43 + sct->ext_len + 4 + sct->sig_len; in i2o_SCT()
216 len = sct->sct_len; in i2o_SCT()
219 return len; in i2o_SCT()
223 *out += len; in i2o_SCT()
225 pstart = p = OPENSSL_malloc(len); in i2o_SCT()
244 memcpy(p, sct->sct, len); in i2o_SCT()
247 return len; in i2o_SCT()
254 size_t len) in STACK_OF()
259 if (len < 2 || len > MAX_SCT_LIST_SIZE) { in STACK_OF()
265 if (list_len != len - 2) { in STACK_OF()
319 int len, sct_len, i, is_pp_new = 0; in i2o_SCT_LIST() local
325 if ((len = i2o_SCT_LIST(a, NULL)) == -1) { in i2o_SCT_LIST()
329 if ((*pp = OPENSSL_malloc(len)) == NULL) in i2o_SCT_LIST()
371 long len) in STACK_OF()
378 if (d2i_ASN1_OCTET_STRING(&oct, &p, len) == NULL) in STACK_OF()
383 *pp += len; in STACK_OF()
392 int len; in i2d_SCT_LIST() local
398 len = i2d_ASN1_OCTET_STRING(&oct, out); in i2d_SCT_LIST()
400 return len; in i2d_SCT_LIST()