diff options
| author | Pierre Pronchery <pierre@freebsdfoundation.org> | 2023-09-22 14:52:58 +0000 |
|---|---|---|
| committer | Ed Maste <emaste@FreeBSD.org> | 2023-09-22 15:55:26 +0000 |
| commit | 315108b81694de474bbc273c0050b195047f5eed (patch) | |
| tree | e3f2a313c74d0ae64bb2f0da5ecd9edb258e361f /apps | |
| parent | cf2fc1b0f5ce501f5a29d307294e5637e0f5aba6 (diff) | |
Diffstat (limited to 'apps')
| -rw-r--r-- | apps/cmp.c | 2 | ||||
| -rw-r--r-- | apps/lib/apps.c | 13 | ||||
| -rw-r--r-- | apps/req.c | 8 | ||||
| -rw-r--r-- | apps/s_server.c | 2 |
4 files changed, 12 insertions, 13 deletions
diff --git a/apps/cmp.c b/apps/cmp.c index a317fdb0bf3e..c479b1549660 100644 --- a/apps/cmp.c +++ b/apps/cmp.c @@ -2512,7 +2512,7 @@ static int get_opts(int argc, char **argv) } break; case OPT_CSR: - opt_csr = opt_arg(); + opt_csr = opt_str(); break; case OPT_OUT_TRUSTED: opt_out_trusted = opt_str(); diff --git a/apps/lib/apps.c b/apps/lib/apps.c index 4baeb352fedf..572f6a3f8f28 100644 --- a/apps/lib/apps.c +++ b/apps/lib/apps.c @@ -944,7 +944,7 @@ int load_key_certs_crls_suppress(const char *uri, int format, int maybe_stdin, BIO *bio; if (!maybe_stdin) { - BIO_printf(bio_err, "No filename or uri specified for loading"); + BIO_printf(bio_err, "No filename or uri specified for loading\n"); goto end; } uri = "<stdin>"; @@ -960,10 +960,8 @@ int load_key_certs_crls_suppress(const char *uri, int format, int maybe_stdin, ctx = OSSL_STORE_open_ex(uri, libctx, propq, get_ui_method(), &uidata, params, NULL, NULL); } - if (ctx == NULL) { - BIO_printf(bio_err, "Could not open file or uri for loading"); + if (ctx == NULL) goto end; - } if (expect > 0 && !OSSL_STORE_expect(ctx, expect)) goto end; @@ -1948,16 +1946,17 @@ X509_NAME *parse_name(const char *cp, int chtype, int canmulti, nid = OBJ_txt2nid(typestr); if (nid == NID_undef) { BIO_printf(bio_err, - "%s: Skipping unknown %s name attribute \"%s\"\n", + "%s warning: Skipping unknown %s name attribute \"%s\"\n", opt_getprog(), desc, typestr); if (ismulti) BIO_printf(bio_err, - "Hint: a '+' in a value string needs be escaped using '\\' else a new member of a multi-valued RDN is expected\n"); + "%s hint: a '+' in a value string needs be escaped using '\\' else a new member of a multi-valued RDN is expected\n", + opt_getprog()); continue; } if (*valstr == '\0') { BIO_printf(bio_err, - "%s: No value provided for %s name attribute \"%s\", skipped\n", + "%s warning: No value provided for %s name attribute \"%s\", skipped\n", opt_getprog(), desc, typestr); continue; } diff --git a/apps/req.c b/apps/req.c index 73b320a7098c..926f0796bc8f 100644 --- a/apps/req.c +++ b/apps/req.c @@ -990,10 +990,10 @@ int req_main(int argc, char **argv) else tpubkey = X509_REQ_get0_pubkey(req); if (tpubkey == NULL) { - fprintf(stdout, "Modulus is unavailable\n"); + BIO_puts(bio_err, "Modulus is unavailable\n"); goto end; } - fprintf(stdout, "Modulus="); + BIO_puts(out, "Modulus="); if (EVP_PKEY_is_a(tpubkey, "RSA") || EVP_PKEY_is_a(tpubkey, "RSA-PSS")) { BIGNUM *n = NULL; @@ -1002,9 +1002,9 @@ int req_main(int argc, char **argv) BN_print(out, n); BN_free(n); } else { - fprintf(stdout, "Wrong Algorithm type"); + BIO_puts(out, "Wrong Algorithm type"); } - fprintf(stdout, "\n"); + BIO_puts(out, "\n"); } if (!noout && !gen_x509) { diff --git a/apps/s_server.c b/apps/s_server.c index a203d6a091ca..c8ccdfd03ca1 100644 --- a/apps/s_server.c +++ b/apps/s_server.c @@ -789,7 +789,7 @@ const OPTIONS s_server_options[] = { "second server certificate chain file in PEM format"}, {"dkey", OPT_DKEY, '<', "Second private key file to use (usually for DSA)"}, - {"dkeyform", OPT_DKEYFORM, 'F', + {"dkeyform", OPT_DKEYFORM, 'f', "Second key file format (ENGINE, other values ignored)"}, {"dpass", OPT_DPASS, 's', "Second private key and cert file pass phrase source"}, |
