Lines Matching refs:format
67 static BIO *bio_open_default_(const char *filename, char mode, int format,
484 X509 *load_cert_pass(const char *uri, int format, int maybe_stdin, in load_cert_pass() argument
500 (void)load_key_certs_crls(uri, format, maybe_stdin, pass, desc, 0, in load_cert_pass()
506 X509_CRL *load_crl(const char *uri, int format, int maybe_stdin, in load_crl() argument
522 (void)load_key_certs_crls(uri, format, maybe_stdin, NULL, desc, 0, in load_crl()
529 X509_REQ *load_csr(const char *file, int format, const char *desc) in load_csr() argument
534 if (format == FORMAT_UNDEF) in load_csr()
535 format = FORMAT_PEM; in load_csr()
536 in = bio_open_default(file, 'r', format); in load_csr()
540 if (format == FORMAT_ASN1) in load_csr()
542 else if (format == FORMAT_PEM) in load_csr()
545 print_format_error(format, OPT_FMT_PEMDER); in load_csr()
558 X509_REQ *load_csr_autofmt(const char *infile, int format, in load_csr_autofmt() argument
563 if (format != FORMAT_UNDEF) { in load_csr_autofmt()
564 csr = load_csr(infile, format, desc); in load_csr_autofmt()
605 EVP_PKEY *load_key(const char *uri, int format, int may_stdin, in load_key() argument
614 if (format == FORMAT_ENGINE) in load_key()
616 (void)load_key_certs_crls(uri, format, may_stdin, pass, desc, 0, in load_key()
624 EVP_PKEY *load_pubkey(const char *uri, int format, int maybe_stdin, in load_pubkey() argument
633 if (format == FORMAT_ENGINE) in load_pubkey()
635 (void)load_key_certs_crls(uri, format, maybe_stdin, pass, desc, 1, in load_pubkey()
638 (void)load_key_certs_crls(uri, format, maybe_stdin, pass, desc, 0, in load_pubkey()
644 EVP_PKEY *load_keyparams_suppress(const char *uri, int format, int maybe_stdin, in load_keyparams_suppress() argument
652 (void)load_key_certs_crls(uri, format, maybe_stdin, NULL, desc, in load_keyparams_suppress()
666 EVP_PKEY *load_keyparams(const char *uri, int format, int maybe_stdin, in load_keyparams() argument
669 return load_keyparams_suppress(uri, format, maybe_stdin, keytype, desc, 0); in load_keyparams()
894 static const char *format2string(int format) in format2string() argument
896 switch (format) { in format2string()
934 int load_key_certs_crls(const char *uri, int format, int maybe_stdin, in load_key_certs_crls() argument
1003 if ((input_type = format2string(format)) != NULL) { in load_key_certs_crls()
3023 BIO *dup_bio_in(int format) in dup_bio_in() argument
3026 BIO_NOCLOSE | (FMT_istext(format) ? BIO_FP_TEXT : 0)); in dup_bio_in()
3029 BIO *dup_bio_out(int format) in dup_bio_out() argument
3032 BIO_NOCLOSE | (FMT_istext(format) ? BIO_FP_TEXT : 0)); in dup_bio_out()
3039 if (FMT_istext(format)) in dup_bio_out()
3043 if (FMT_istext(format) in dup_bio_out()
3052 BIO *dup_bio_err(int format) in dup_bio_err() argument
3055 BIO_NOCLOSE | (FMT_istext(format) ? BIO_FP_TEXT : 0)); in dup_bio_err()
3058 if (b != NULL && FMT_istext(format)) in dup_bio_err()
3083 static const char *modestr(char mode, int format) in modestr() argument
3089 return FMT_istext(format) ? "a" : "ab"; in modestr()
3091 return FMT_istext(format) ? "r" : "rb"; in modestr()
3093 return FMT_istext(format) ? "w" : "wb"; in modestr()
3115 BIO *bio_open_owner(const char *filename, int format, int private) in bio_open_owner() argument
3125 return bio_open_default(filename, 'w', format); in bio_open_owner()
3127 textmode = FMT_istext(format); in bio_open_owner()
3158 fp = fdopen(fd, modestr('w', format)); in bio_open_owner()
3161 fp = fopen(filename, modestr('w', format)); in bio_open_owner()
3186 static BIO *bio_open_default_(const char *filename, char mode, int format, in bio_open_default_() argument
3192 ret = mode == 'r' ? dup_bio_in(format) : dup_bio_out(format); in bio_open_default_()
3203 ret = BIO_new_file(filename, modestr(mode, format)); in bio_open_default_()
3218 BIO *bio_open_default(const char *filename, char mode, int format) in bio_open_default() argument
3220 return bio_open_default_(filename, mode, format, 0); in bio_open_default()
3223 BIO *bio_open_default_quiet(const char *filename, char mode, int format) in bio_open_default_quiet() argument
3225 return bio_open_default_(filename, mode, format, 1); in bio_open_default_quiet()