/third_party/openssl/crypto/ts/ |
D | ts_rsp_print.c | 23 static int ts_status_map_print(BIO *bio, const struct status_map_st *a, 25 static int ts_ACCURACY_print_bio(BIO *bio, const TS_ACCURACY *accuracy); 28 int TS_RESP_print_bio(BIO *bio, TS_RESP *a) in TS_RESP_print_bio() argument 30 BIO_printf(bio, "Status info:\n"); in TS_RESP_print_bio() 31 TS_STATUS_INFO_print_bio(bio, a->status_info); in TS_RESP_print_bio() 33 BIO_printf(bio, "\nTST info:\n"); in TS_RESP_print_bio() 35 TS_TST_INFO_print_bio(bio, a->tst_info); in TS_RESP_print_bio() 37 BIO_printf(bio, "Not included.\n"); in TS_RESP_print_bio() 42 int TS_STATUS_INFO_print_bio(BIO *bio, TS_STATUS_INFO *a) in TS_STATUS_INFO_print_bio() argument 75 BIO_printf(bio, "Status: "); in TS_STATUS_INFO_print_bio() [all …]
|
D | ts_lib.c | 19 int TS_ASN1_INTEGER_print_bio(BIO *bio, const ASN1_INTEGER *num) in TS_ASN1_INTEGER_print_bio() argument 29 result = BIO_write(bio, "0x", 2) > 0; in TS_ASN1_INTEGER_print_bio() 30 result = result && BIO_write(bio, hex, strlen(hex)) > 0; in TS_ASN1_INTEGER_print_bio() 38 int TS_OBJ_print_bio(BIO *bio, const ASN1_OBJECT *obj) in TS_OBJ_print_bio() argument 43 BIO_printf(bio, "%s\n", obj_txt); in TS_OBJ_print_bio() 48 int TS_ext_print_bio(BIO *bio, const STACK_OF(X509_EXTENSION) *extensions) in TS_ext_print_bio() argument 54 BIO_printf(bio, "Extensions:\n"); in TS_ext_print_bio() 59 if (i2a_ASN1_OBJECT(bio, obj) < 0) in TS_ext_print_bio() 62 BIO_printf(bio, ":%s\n", critical ? " critical" : ""); in TS_ext_print_bio() 63 if (!X509V3_EXT_print(bio, ex, 0, 4)) { in TS_ext_print_bio() [all …]
|
D | ts_req_print.c | 18 int TS_REQ_print_bio(BIO *bio, TS_REQ *a) in TS_REQ_print_bio() argument 27 BIO_printf(bio, "Version: %d\n", v); in TS_REQ_print_bio() 29 TS_MSG_IMPRINT_print_bio(bio, a->msg_imprint); in TS_REQ_print_bio() 31 BIO_printf(bio, "Policy OID: "); in TS_REQ_print_bio() 34 BIO_printf(bio, "unspecified\n"); in TS_REQ_print_bio() 36 TS_OBJ_print_bio(bio, policy_id); in TS_REQ_print_bio() 38 BIO_printf(bio, "Nonce: "); in TS_REQ_print_bio() 40 BIO_printf(bio, "unspecified"); in TS_REQ_print_bio() 42 TS_ASN1_INTEGER_print_bio(bio, a->nonce); in TS_REQ_print_bio() 43 BIO_write(bio, "\n", 1); in TS_REQ_print_bio() [all …]
|
/third_party/openssl/ssl/ |
D | t1_trce.c | 24 # define ssl_trace_list(bio, indent, msg, msglen, value, table) \ argument 25 do_ssl_trace_list(bio, indent, msg, msglen, value, \ 40 static int do_ssl_trace_list(BIO *bio, int indent, in do_ssl_trace_list() argument 52 BIO_indent(bio, indent, 80); in do_ssl_trace_list() 53 BIO_printf(bio, "%s (%d)\n", do_ssl_trace_str(val, tbl, ntbl), val); in do_ssl_trace_list() 614 static void ssl_print_hex(BIO *bio, int indent, const char *name, in ssl_print_hex() argument 619 BIO_indent(bio, indent, 80); in ssl_print_hex() 620 BIO_printf(bio, "%s (len=%d): ", name, (int)msglen); in ssl_print_hex() 622 BIO_printf(bio, "%02X", msg[i]); in ssl_print_hex() 623 BIO_puts(bio, "\n"); in ssl_print_hex() [all …]
|
/third_party/openssl/test/ |
D | bio_memleak_test.c | 19 BIO *bio; in test_bio_memleak() local 24 bio = BIO_new(BIO_s_mem()); in test_bio_memleak() 25 if (!TEST_ptr(bio)) in test_bio_memleak() 30 BIO_set_mem_buf(bio, &bufmem, BIO_NOCLOSE); in test_bio_memleak() 31 BIO_set_flags(bio, BIO_FLAGS_MEM_RDONLY); in test_bio_memleak() 32 if (!TEST_int_eq(BIO_read(bio, buf, sizeof(buf)), sizeof(str))) in test_bio_memleak() 39 BIO_free(bio); in test_bio_memleak() 46 BIO *bio = NULL; in test_bio_get_mem() local 49 bio = BIO_new(BIO_s_mem()); in test_bio_get_mem() 50 if (!TEST_ptr(bio)) in test_bio_get_mem() [all …]
|
D | bio_core_test.c | 16 BIO *bio; member 19 static int tst_bio_core_read_ex(OSSL_CORE_BIO *bio, char *data, size_t data_len, in tst_bio_core_read_ex() argument 22 return BIO_read_ex(bio->bio, data, data_len, bytes_read); in tst_bio_core_read_ex() 25 static int tst_bio_core_write_ex(OSSL_CORE_BIO *bio, const char *data, in tst_bio_core_write_ex() argument 28 return BIO_write_ex(bio->bio, data, data_len, written); in tst_bio_core_write_ex() 31 static int tst_bio_core_gets(OSSL_CORE_BIO *bio, char *buf, int size) in tst_bio_core_gets() argument 33 return BIO_gets(bio->bio, buf, size); in tst_bio_core_gets() 36 static int tst_bio_core_puts(OSSL_CORE_BIO *bio, const char *str) in tst_bio_core_puts() argument 38 return BIO_puts(bio->bio, str); in tst_bio_core_puts() 41 static long tst_bio_core_ctrl(OSSL_CORE_BIO *bio, int cmd, long num, void *ptr) in tst_bio_core_ctrl() argument [all …]
|
D | bio_callback_test.c | 48 BIO *bio; in test_bio_callback_ex() local 58 bio = BIO_new(BIO_s_mem()); in test_bio_callback_ex() 59 if (bio == NULL) in test_bio_callback_ex() 62 BIO_set_callback_ex(bio, my_bio_cb_ex); in test_bio_callback_ex() 63 i = BIO_write(bio, test1, test1len); in test_bio_callback_ex() 66 || !TEST_ptr_eq(my_param_b[0], bio) in test_bio_callback_ex() 72 || !TEST_ptr_eq(my_param_b[1], bio) in test_bio_callback_ex() 82 i = BIO_read(bio, buf, sizeof(buf)); in test_bio_callback_ex() 85 || !TEST_ptr_eq(my_param_b[0], bio) in test_bio_callback_ex() 91 || !TEST_ptr_eq(my_param_b[1], bio) in test_bio_callback_ex() [all …]
|
D | asynciotest.c | 62 static int async_new(BIO *bio) in async_new() argument 70 BIO_set_data(bio, ctrs); in async_new() 71 BIO_set_init(bio, 1); in async_new() 75 static int async_free(BIO *bio) in async_free() argument 79 if (bio == NULL) in async_free() 81 ctrs = BIO_get_data(bio); in async_free() 83 BIO_set_data(bio, NULL); in async_free() 84 BIO_set_init(bio, 0); in async_free() 89 static int async_read(BIO *bio, char *out, int outl) in async_read() argument 93 BIO *next = BIO_next(bio); in async_read() [all …]
|
D | sslcorrupttest.c | 16 static void copy_flags(BIO *bio) in copy_flags() argument 19 BIO *next = BIO_next(bio); in copy_flags() 22 BIO_clear_flags(bio, BIO_FLAGS_SHOULD_RETRY | BIO_FLAGS_RWS); in copy_flags() 23 BIO_set_flags(bio, flags); in copy_flags() 26 static int tls_corrupt_read(BIO *bio, char *out, int outl) in tls_corrupt_read() argument 29 BIO *next = BIO_next(bio); in tls_corrupt_read() 32 copy_flags(bio); in tls_corrupt_read() 37 static int tls_corrupt_write(BIO *bio, const char *in, int inl) in tls_corrupt_write() argument 40 BIO *next = BIO_next(bio); in tls_corrupt_write() 53 copy_flags(bio); in tls_corrupt_write() [all …]
|
/third_party/openssl/crypto/bio/ |
D | bio_lib.c | 83 BIO *bio = OPENSSL_zalloc(sizeof(*bio)); in BIO_new_ex() local 85 if (bio == NULL) { in BIO_new_ex() 90 bio->libctx = libctx; in BIO_new_ex() 91 bio->method = method; in BIO_new_ex() 92 bio->shutdown = 1; in BIO_new_ex() 93 bio->references = 1; in BIO_new_ex() 95 if (!CRYPTO_new_ex_data(CRYPTO_EX_INDEX_BIO, bio, &bio->ex_data)) in BIO_new_ex() 98 bio->lock = CRYPTO_THREAD_lock_new(); in BIO_new_ex() 99 if (bio->lock == NULL) { in BIO_new_ex() 101 CRYPTO_free_ex_data(CRYPTO_EX_INDEX_BIO, bio, &bio->ex_data); in BIO_new_ex() [all …]
|
D | bss_bio.c | 28 static int bio_new(BIO *bio); 29 static int bio_free(BIO *bio); 30 static int bio_read(BIO *bio, char *buf, int size); 31 static int bio_write(BIO *bio, const char *buf, int num); 32 static long bio_ctrl(BIO *bio, int cmd, long num, void *ptr); 33 static int bio_puts(BIO *bio, const char *str); 36 static void bio_destroy_pair(BIO *bio); 76 static int bio_new(BIO *bio) in bio_new() argument 86 bio->ptr = b; in bio_new() 90 static int bio_free(BIO *bio) in bio_free() argument [all …]
|
D | bio_cb.c | 19 long BIO_debug_callback_ex(BIO *bio, int cmd, const char *argp, size_t len, in BIO_debug_callback_ex() argument 31 left = BIO_snprintf(buf, sizeof(buf), "BIO[%p]: ", (void *)bio); in BIO_debug_callback_ex() 41 BIO_snprintf(p, left, "Free - %s\n", bio->method->name); in BIO_debug_callback_ex() 44 if (bio->method->type & BIO_TYPE_DESCRIPTOR) in BIO_debug_callback_ex() 46 bio->num, len, in BIO_debug_callback_ex() 47 bio->method->name, bio->num); in BIO_debug_callback_ex() 50 bio->num, len, bio->method->name); in BIO_debug_callback_ex() 53 if (bio->method->type & BIO_TYPE_DESCRIPTOR) in BIO_debug_callback_ex() 55 bio->num, len, in BIO_debug_callback_ex() 56 bio->method->name, bio->num); in BIO_debug_callback_ex() [all …]
|
D | ossl_core_bio.c | 21 BIO *bio; member 50 res = BIO_free(cb->bio); in ossl_core_bio_free() 58 OSSL_CORE_BIO *ossl_core_bio_new_from_bio(BIO *bio) in ossl_core_bio_new_from_bio() argument 62 if (cb == NULL || !BIO_up_ref(bio)) { in ossl_core_bio_new_from_bio() 66 cb->bio = bio; in ossl_core_bio_new_from_bio() 70 static OSSL_CORE_BIO *core_bio_new_from_new_bio(BIO *bio) in core_bio_new_from_new_bio() argument 74 if (bio == NULL) in core_bio_new_from_new_bio() 77 BIO_free(bio); in core_bio_new_from_new_bio() 80 cb->bio = bio; in core_bio_new_from_new_bio() 97 return BIO_read_ex(cb->bio, data, dlen, readbytes); in ossl_core_bio_read_ex() [all …]
|
D | bss_core.c | 46 static int bio_core_read_ex(BIO *bio, char *data, size_t data_len, in bio_core_read_ex() argument 49 BIO_CORE_GLOBALS *bcgbl = get_globals(bio->libctx); in bio_core_read_ex() 53 return bcgbl->c_bio_read_ex(BIO_get_data(bio), data, data_len, bytes_read); in bio_core_read_ex() 56 static int bio_core_write_ex(BIO *bio, const char *data, size_t data_len, in bio_core_write_ex() argument 59 BIO_CORE_GLOBALS *bcgbl = get_globals(bio->libctx); in bio_core_write_ex() 63 return bcgbl->c_bio_write_ex(BIO_get_data(bio), data, data_len, written); in bio_core_write_ex() 66 static long bio_core_ctrl(BIO *bio, int cmd, long num, void *ptr) in bio_core_ctrl() argument 68 BIO_CORE_GLOBALS *bcgbl = get_globals(bio->libctx); in bio_core_ctrl() 72 return bcgbl->c_bio_ctrl(BIO_get_data(bio), cmd, num, ptr); in bio_core_ctrl() 75 static int bio_core_gets(BIO *bio, char *buf, int size) in bio_core_gets() argument [all …]
|
/third_party/rust/crates/rust-openssl/openssl/src/ssl/ |
D | bio.rs | 47 let bio = cvt_p(BIO_new(method.0.get()))?; in new() localVariable 48 BIO_set_data(bio, Box::into_raw(state) as *mut _); in new() 49 BIO_set_init(bio, 1); in new() 51 Ok((bio, method)) in new() 55 pub unsafe fn take_error<S>(bio: *mut BIO) -> Option<io::Error> { in take_error() 56 let state = state::<S>(bio); in take_error() 60 pub unsafe fn take_panic<S>(bio: *mut BIO) -> Option<Box<dyn Any + Send>> { in take_panic() 61 let state = state::<S>(bio); in take_panic() 65 pub unsafe fn get_ref<'a, S: 'a>(bio: *mut BIO) -> &'a S { in get_ref() 66 let state = &*(BIO_get_data(bio) as *const StreamState<S>); in get_ref() [all …]
|
/third_party/openssl/providers/common/ |
D | bio_prov.c | 90 int ossl_prov_bio_read_ex(OSSL_CORE_BIO *bio, void *data, size_t data_len, in ossl_prov_bio_read_ex() argument 95 return c_bio_read_ex(bio, data, data_len, bytes_read); in ossl_prov_bio_read_ex() 98 int ossl_prov_bio_write_ex(OSSL_CORE_BIO *bio, const void *data, size_t data_len, in ossl_prov_bio_write_ex() argument 103 return c_bio_write_ex(bio, data, data_len, written); in ossl_prov_bio_write_ex() 106 int ossl_prov_bio_gets(OSSL_CORE_BIO *bio, char *buf, int size) in ossl_prov_bio_gets() argument 110 return c_bio_gets(bio, buf, size); in ossl_prov_bio_gets() 113 int ossl_prov_bio_puts(OSSL_CORE_BIO *bio, const char *str) in ossl_prov_bio_puts() argument 117 return c_bio_puts(bio, str); in ossl_prov_bio_puts() 120 int ossl_prov_bio_ctrl(OSSL_CORE_BIO *bio, int cmd, long num, void *ptr) in ossl_prov_bio_ctrl() argument 124 return c_bio_ctrl(bio, cmd, num, ptr); in ossl_prov_bio_ctrl() [all …]
|
/third_party/openssl/test/testutil/ |
D | load.c | 21 BIO *bio = NULL; in load_cert_pem() local 23 if (!TEST_ptr(file) || !TEST_ptr(bio = BIO_new(BIO_s_file()))) in load_cert_pem() 25 if (TEST_int_gt(BIO_read_filename(bio, file), 0) in load_cert_pem() 27 (void)TEST_ptr(cert = PEM_read_bio_X509(bio, &cert, NULL, NULL)); in load_cert_pem() 29 BIO_free(bio); in load_cert_pem() 36 BIO *bio; in STACK_OF() local 39 if (!TEST_ptr(file) || (bio = BIO_new_file(file, "r")) == NULL) in STACK_OF() 44 BIO_free(bio); in STACK_OF() 50 x = PEM_read_bio_X509(bio, NULL, 0, NULL); in STACK_OF() 53 BIO_free(bio); in STACK_OF() [all …]
|
/third_party/node/src/ |
D | node_crypto_bio.cc | 35 BIOPointer bio(BIO_new(GetMethod())); in New() local 36 if (bio && env != nullptr) in New() 37 NodeBIO::FromBIO(bio.get())->env_ = env; in New() 38 return bio; in New() 43 BIOPointer bio = New(env); in NewFixed() local 45 if (!bio || in NewFixed() 47 BIO_write(bio.get(), data, len) != static_cast<int>(len) || in NewFixed() 48 BIO_set_mem_eof_return(bio.get(), 0) != 1) { in NewFixed() 52 return bio; in NewFixed() 56 int NodeBIO::New(BIO* bio) { in New() argument [all …]
|
/third_party/openssl/test/helpers/ |
D | ssltestlib.c | 70 static int tls_dump_new(BIO *bio) in tls_dump_new() argument 72 BIO_set_init(bio, 1); in tls_dump_new() 76 static int tls_dump_free(BIO *bio) in tls_dump_free() argument 78 BIO_set_init(bio, 0); in tls_dump_free() 83 static void copy_flags(BIO *bio) in copy_flags() argument 86 BIO *next = BIO_next(bio); in copy_flags() 89 BIO_clear_flags(bio, BIO_FLAGS_SHOULD_RETRY | BIO_FLAGS_RWS); in copy_flags() 90 BIO_set_flags(bio, flags); in copy_flags() 193 static int tls_dump_read(BIO *bio, char *out, int outl) in tls_dump_read() argument 196 BIO *next = BIO_next(bio); in tls_dump_read() [all …]
|
/third_party/rust/crates/rust-openssl/openssl-sys/src/handwritten/ |
D | pem.rs | 15 pub fn PEM_write_bio_X509(bio: *mut BIO, x509: #[const_ptr_if(ossl300)] X509) -> c_int; 16 … pub fn PEM_write_bio_X509_REQ(bio: *mut BIO, x509: #[const_ptr_if(ossl300)] X509_REQ) -> c_int; 17 … pub fn PEM_write_bio_X509_CRL(bio: *mut BIO, x509: #[const_ptr_if(ossl300)] X509_CRL) -> c_int; 38 bio: *mut BIO, 48 bio: *mut BIO, 58 bio: *mut BIO, 82 bio: *mut BIO, in PEM_read_bio_X509() 88 bio: *mut BIO, in PEM_read_bio_X509_REQ() 94 bio: *mut BIO, in PEM_read_bio_X509_CRL() 100 bio: *mut BIO, in PEM_read_bio_RSAPrivateKey() [all …]
|
/third_party/openssl/crypto/asn1/ |
D | asn_mime.c | 50 static STACK_OF(MIME_HEADER) *mime_parse_hdr(BIO *bio); 57 static int multi_split(BIO *bio, int flags, const char *bound, STACK_OF(BIO) **ret); 76 BIO *bio, *tbio; in i2d_ASN1_bio_stream() local 77 bio = BIO_new_NDEF(out, val, it); in i2d_ASN1_bio_stream() 78 if (!bio) { in i2d_ASN1_bio_stream() 82 if (!SMIME_crlf_copy(in, bio, flags)) { in i2d_ASN1_bio_stream() 86 (void)BIO_flush(bio); in i2d_ASN1_bio_stream() 89 tbio = BIO_pop(bio); in i2d_ASN1_bio_stream() 90 BIO_free(bio); in i2d_ASN1_bio_stream() 91 bio = tbio; in i2d_ASN1_bio_stream() [all …]
|
/third_party/openssl/crypto/x509/ |
D | t_x509.c | 400 int ossl_x509_print_ex_brief(BIO *bio, X509 *cert, unsigned long neg_cflags) in ossl_x509_print_ex_brief() argument 406 return BIO_printf(bio, " (no certificate)\n") > 0; in ossl_x509_print_ex_brief() 407 if (BIO_printf(bio, " certificate\n") <= 0 in ossl_x509_print_ex_brief() 408 || !X509_print_ex(bio, cert, flags, ~X509_FLAG_NO_SUBJECT)) in ossl_x509_print_ex_brief() 411 if (BIO_printf(bio, " self-issued\n") <= 0) in ossl_x509_print_ex_brief() 414 if (BIO_printf(bio, " ") <= 0 in ossl_x509_print_ex_brief() 415 || !X509_print_ex(bio, cert, flags, ~X509_FLAG_NO_ISSUER)) in ossl_x509_print_ex_brief() 418 if (!X509_print_ex(bio, cert, flags, in ossl_x509_print_ex_brief() 422 if (BIO_printf(bio, " not yet valid\n") <= 0) in ossl_x509_print_ex_brief() 425 if (BIO_printf(bio, " no more valid\n") <= 0) in ossl_x509_print_ex_brief() [all …]
|
/third_party/ltp/testcases/kernel/device-drivers/tbio/tbio_kernel/ |
D | ltp_tbio.c | 66 static struct bio *tbiop, *tbiop_dup; 77 static int send_request(struct request_queue *q, struct bio *bio, in send_request() argument 82 rq = blk_make_request(q, bio, GFP_KERNEL); in send_request() 103 rq->__sector = bio->bi_sector; in send_request() 122 struct bio *bio = NULL; in tbio_io() local 150 bio = bio_map_user(q, bdev, (unsigned long)inter.data, in tbio_io() 153 if (!bio) { in tbio_io() 170 send_request(q, bio, bdev, &inter, writing); in tbio_io() 172 if (bio) in tbio_io() 173 bio_unmap_user(bio); in tbio_io() [all …]
|
/third_party/fsverity-utils/lib/ |
D | sign_digest.c | 55 BIO *bio; in read_private_key() local 60 bio = BIO_new_file(keyfile, "r"); in read_private_key() 61 if (!bio) { in read_private_key() 66 pkey = PEM_read_bio_PrivateKey(bio, NULL, NULL, NULL); in read_private_key() 77 BIO_free(bio); in read_private_key() 84 BIO *bio; in read_certificate() local 94 bio = BIO_new_file(certfile, "r"); in read_certificate() 95 if (!bio) { in read_certificate() 99 cert = PEM_read_bio_X509(bio, NULL, NULL, NULL); in read_certificate() 110 BIO_free(bio); in read_certificate() [all …]
|
/third_party/openssl/providers/common/include/prov/ |
D | bio.h | 19 int ossl_prov_bio_read_ex(OSSL_CORE_BIO *bio, void *data, size_t data_len, 21 int ossl_prov_bio_write_ex(OSSL_CORE_BIO *bio, const void *data, size_t data_len, 23 int ossl_prov_bio_gets(OSSL_CORE_BIO *bio, char *buf, int size); 24 int ossl_prov_bio_puts(OSSL_CORE_BIO *bio, const char *str); 25 int ossl_prov_bio_ctrl(OSSL_CORE_BIO *bio, int cmd, long num, void *ptr); 26 int ossl_prov_bio_up_ref(OSSL_CORE_BIO *bio); 27 int ossl_prov_bio_free(OSSL_CORE_BIO *bio); 28 int ossl_prov_bio_vprintf(OSSL_CORE_BIO *bio, const char *format, va_list ap); 29 int ossl_prov_bio_printf(OSSL_CORE_BIO *bio, const char *format, ...);
|