summaryrefslogtreecommitdiffstats
path: root/apps/smime.c
diff options
context:
space:
mode:
authorRichard Levitte <levitte@openssl.org>2000-06-22 22:07:27 +0000
committerRichard Levitte <levitte@openssl.org>2000-06-22 22:07:27 +0000
commit431b0cce7daf8f1d94fdb0fa304cbee5b2c96163 (patch)
treecf30bd8c7c848e832291e75599fdf2c4351626fc /apps/smime.c
parent1023b1220ee4f25ff424fa018d7420b668958a3e (diff)
Move add_oid_section to apps.c, so it can be shared by several
applications. Also, have it and the certificate and key loading functions take a BIO argument for error output.
Diffstat (limited to 'apps/smime.c')
-rw-r--r--apps/smime.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/apps/smime.c b/apps/smime.c
index e571cdd0d5..bb8ecd7cf0 100644
--- a/apps/smime.c
+++ b/apps/smime.c
@@ -308,7 +308,7 @@ int MAIN(int argc, char **argv)
}
encerts = sk_X509_new_null();
while (*args) {
- if(!(cert = load_cert(*args,FORMAT_PEM))) {
+ if(!(cert = load_cert(bio_err,*args,FORMAT_PEM))) {
BIO_printf(bio_err, "Can't read recipient certificate file %s\n", *args);
goto end;
}
@@ -319,14 +319,14 @@ int MAIN(int argc, char **argv)
}
if(signerfile && (operation == SMIME_SIGN)) {
- if(!(signer = load_cert(signerfile,FORMAT_PEM))) {
+ if(!(signer = load_cert(bio_err,signerfile,FORMAT_PEM))) {
BIO_printf(bio_err, "Can't read signer certificate file %s\n", signerfile);
goto end;
}
}
if(certfile) {
- if(!(other = load_certs(certfile,FORMAT_PEM))) {
+ if(!(other = load_certs(bio_err,certfile,FORMAT_PEM))) {
BIO_printf(bio_err, "Can't read certificate file %s\n", certfile);
ERR_print_errors(bio_err);
goto end;
@@ -334,7 +334,7 @@ int MAIN(int argc, char **argv)
}
if(recipfile && (operation == SMIME_DECRYPT)) {
- if(!(recip = load_cert(recipfile,FORMAT_PEM))) {
+ if(!(recip = load_cert(bio_err,recipfile,FORMAT_PEM))) {
BIO_printf(bio_err, "Can't read recipient certificate file %s\n", recipfile);
ERR_print_errors(bio_err);
goto end;
@@ -348,7 +348,7 @@ int MAIN(int argc, char **argv)
} else keyfile = NULL;
if(keyfile) {
- if(!(key = load_key(keyfile, FORMAT_PEM, passin))) {
+ if(!(key = load_key(bio_err,keyfile, FORMAT_PEM, passin))) {
BIO_printf(bio_err, "Can't read recipient certificate file %s\n", keyfile);
ERR_print_errors(bio_err);
goto end;