projects
/
privoxy.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
a52bdf9
)
OpenSSL generate_key(): Check EVP_RSA_gen()'s return value
author
Fabian Keil
<fk@fabiankeil.de>
Thu, 11 Jul 2024 08:21:03 +0000
(10:21 +0200)
committer
Fabian Keil
<fk@fabiankeil.de>
Thu, 11 Jul 2024 08:21:03 +0000
(10:21 +0200)
openssl.c
patch
|
blob
|
history
diff --git
a/openssl.c
b/openssl.c
index
f392037
..
ba2fc3e
100644
(file)
--- a/
openssl.c
+++ b/
openssl.c
@@
-1538,6
+1538,12
@@
static int generate_key(struct client_state *csp, char **key_buf)
}
#else
key = EVP_RSA_gen(RSA_KEYSIZE);
+ if (key == NULL)
+ {
+ log_error(LOG_LEVEL_ERROR, "EVP_RSA_gen() failed");
+ ret = -1;
+ goto exit;
+ }
#endif
/*