diff options
author | jsing <> | 2022-02-03 16:33:12 +0000 |
---|---|---|
committer | jsing <> | 2022-02-03 16:33:12 +0000 |
commit | 8babe15310f777eda2ab1203f245c0f0892a3801 (patch) | |
tree | f898df6442fa1535bd54e575b63b8dd68b1983de /src/lib/libssl/ssl_rsa.c | |
parent | 6fd933a66bac23ba01bf8727afa5da899721ffe0 (diff) | |
download | openbsd-8babe15310f777eda2ab1203f245c0f0892a3801.tar.gz openbsd-8babe15310f777eda2ab1203f245c0f0892a3801.tar.bz2 openbsd-8babe15310f777eda2ab1203f245c0f0892a3801.zip |
Cleanup/simplify ssl_cert_type()
Remove the X509 argument as it is unused - this was passed so that
ssl_cert_type() can get the public key from the X509 object if the
EVP_PKEY argument is NULL, however this is never the case.
ok tb@
Diffstat (limited to 'src/lib/libssl/ssl_rsa.c')
-rw-r--r-- | src/lib/libssl/ssl_rsa.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/lib/libssl/ssl_rsa.c b/src/lib/libssl/ssl_rsa.c index 6b1010e413..f5c90fca8b 100644 --- a/src/lib/libssl/ssl_rsa.c +++ b/src/lib/libssl/ssl_rsa.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: ssl_rsa.c,v 1.38 2022/01/08 12:43:44 jsing Exp $ */ | 1 | /* $OpenBSD: ssl_rsa.c,v 1.39 2022/02/03 16:33:12 jsing Exp $ */ |
2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) | 2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) |
3 | * All rights reserved. | 3 | * All rights reserved. |
4 | * | 4 | * |
@@ -171,7 +171,7 @@ ssl_set_pkey(SSL_CERT *c, EVP_PKEY *pkey) | |||
171 | { | 171 | { |
172 | int i; | 172 | int i; |
173 | 173 | ||
174 | i = ssl_cert_type(NULL, pkey); | 174 | i = ssl_cert_type(pkey); |
175 | if (i < 0) { | 175 | if (i < 0) { |
176 | SSLerrorx(SSL_R_UNKNOWN_CERTIFICATE_TYPE); | 176 | SSLerrorx(SSL_R_UNKNOWN_CERTIFICATE_TYPE); |
177 | return (0); | 177 | return (0); |
@@ -354,7 +354,7 @@ ssl_set_cert(SSL_CERT *c, X509 *x) | |||
354 | return (0); | 354 | return (0); |
355 | } | 355 | } |
356 | 356 | ||
357 | i = ssl_cert_type(x, pkey); | 357 | i = ssl_cert_type(pkey); |
358 | if (i < 0) { | 358 | if (i < 0) { |
359 | SSLerrorx(SSL_R_UNKNOWN_CERTIFICATE_TYPE); | 359 | SSLerrorx(SSL_R_UNKNOWN_CERTIFICATE_TYPE); |
360 | EVP_PKEY_free(pkey); | 360 | EVP_PKEY_free(pkey); |