Lines Matching refs:cbb
139 CBB cbb; in EVP_PKEY2PKCS8() local
142 if (!CBB_init(&cbb, 0) || in EVP_PKEY2PKCS8()
143 !EVP_marshal_private_key(&cbb, pkey) || in EVP_PKEY2PKCS8()
144 !CBB_finish(&cbb, &der, &der_len) || in EVP_PKEY2PKCS8()
146 CBB_cleanup(&cbb); in EVP_PKEY2PKCS8()
220 CBB cbb; in PKCS8_encrypt() local
221 if (!CBB_init(&cbb, 128) || in PKCS8_encrypt()
222 !PKCS8_marshal_encrypted_private_key(&cbb, pbe_nid, cipher, pass, in PKCS8_encrypt()
225 !CBB_finish(&cbb, &der, &der_len)) { in PKCS8_encrypt()
226 CBB_cleanup(&cbb); in PKCS8_encrypt()
346 CBB cbb; in parse_bag_attributes() local
347 if (!CBB_init(&cbb, CBS_len(&value))) { in parse_bag_attributes()
354 !cbb_add_utf8(&cbb, c)) { in parse_bag_attributes()
356 CBB_cleanup(&cbb); in parse_bag_attributes()
360 if (!CBB_finish(&cbb, out_friendly_name, out_friendly_name_len)) { in parse_bag_attributes()
362 CBB_cleanup(&cbb); in parse_bag_attributes()
992 static int add_cert_bag(CBB *cbb, X509 *cert, const char *name, in add_cert_bag() argument
996 !CBB_add_asn1(cbb, &bag, CBS_ASN1_SEQUENCE) || in add_cert_bag()
1016 !CBB_flush(cbb)) { in add_cert_bag()
1027 CBB cbb, safe_contents; in make_cert_safe_contents() local
1028 if (!CBB_init(&cbb, 0) || in make_cert_safe_contents()
1029 !CBB_add_asn1(&cbb, &safe_contents, CBS_ASN1_SEQUENCE) || in make_cert_safe_contents()
1042 ret = CBB_finish(&cbb, out_data, out_len); in make_cert_safe_contents()
1045 CBB_cleanup(&cbb); in make_cert_safe_contents()
1161 CBB cbb, pfx, auth_safe, auth_safe_oid, auth_safe_wrapper, auth_safe_data, in PKCS12_create() local
1164 if (!CBB_init(&cbb, 0) || in PKCS12_create()
1165 !CBB_add_asn1(&cbb, &pfx, CBS_ASN1_SEQUENCE) || in PKCS12_create()
1263 !CBB_finish(&cbb, &ret->ber_bytes, &ret->ber_len)) { in PKCS12_create()
1271 CBB_cleanup(&cbb); in PKCS12_create()