aboutsummaryrefslogtreecommitdiff
path: root/crypto/openssl/apps
diff options
context:
space:
mode:
authorJung-uk Kim <jkim@FreeBSD.org>2020-03-31 15:47:55 +0000
committerJung-uk Kim <jkim@FreeBSD.org>2020-03-31 15:47:55 +0000
commit11c7efe3a422cd7029326bddf7f2a1c6870a99fe (patch)
treefa8dd281d833938f533d8f63871d4574bdd5145c /crypto/openssl/apps
parent568f01f6c3e51ef4b24abe532237081a35e585f6 (diff)
parentb6cfecdc04a5a5e42ae4f2b025d8246cc16f3342 (diff)
downloadsrc-11c7efe3a422cd7029326bddf7f2a1c6870a99fe.tar.gz
src-11c7efe3a422cd7029326bddf7f2a1c6870a99fe.zip
Notes
Diffstat (limited to 'crypto/openssl/apps')
-rw-r--r--crypto/openssl/apps/rehash.c14
-rw-r--r--crypto/openssl/apps/s_server.c4
2 files changed, 13 insertions, 5 deletions
diff --git a/crypto/openssl/apps/rehash.c b/crypto/openssl/apps/rehash.c
index 2b769fbceb87..fc1dffe97497 100644
--- a/crypto/openssl/apps/rehash.c
+++ b/crypto/openssl/apps/rehash.c
@@ -1,5 +1,5 @@
/*
- * Copyright 2015-2019 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 2015-2020 The OpenSSL Project Authors. All Rights Reserved.
* Copyright (c) 2013-2014 Timo Teräs <timo.teras@gmail.com>
*
* Licensed under the OpenSSL license (the "License"). You may not use
@@ -274,11 +274,19 @@ static int do_file(const char *filename, const char *fullpath, enum Hash h)
if (x->x509 != NULL) {
type = TYPE_CERT;
name = X509_get_subject_name(x->x509);
- X509_digest(x->x509, evpmd, digest, NULL);
+ if (!X509_digest(x->x509, evpmd, digest, NULL)) {
+ BIO_printf(bio_err, "out of memory\n");
+ ++errs;
+ goto end;
+ }
} else if (x->crl != NULL) {
type = TYPE_CRL;
name = X509_CRL_get_issuer(x->crl);
- X509_CRL_digest(x->crl, evpmd, digest, NULL);
+ if (!X509_CRL_digest(x->crl, evpmd, digest, NULL)) {
+ BIO_printf(bio_err, "out of memory\n");
+ ++errs;
+ goto end;
+ }
} else {
++errs;
goto end;
diff --git a/crypto/openssl/apps/s_server.c b/crypto/openssl/apps/s_server.c
index 2248a432e268..0ba75999fd28 100644
--- a/crypto/openssl/apps/s_server.c
+++ b/crypto/openssl/apps/s_server.c
@@ -1,5 +1,5 @@
/*
- * Copyright 1995-2019 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 1995-2020 The OpenSSL Project Authors. All Rights Reserved.
* Copyright (c) 2002, Oracle and/or its affiliates. All rights reserved
* Copyright 2005 Nokia. All rights reserved.
*
@@ -1904,7 +1904,7 @@ int s_server_main(int argc, char *argv[])
BIO_printf(bio_s_out, "Setting secondary ctx parameters\n");
if (sdebug)
- ssl_ctx_security_debug(ctx, sdebug);
+ ssl_ctx_security_debug(ctx2, sdebug);
if (session_id_prefix) {
if (strlen(session_id_prefix) >= 32)