You are viewing a plain text version of this content. The canonical link for it is here.
Posted to cvs@httpd.apache.org by jo...@apache.org on 2003/10/22 17:04:11 UTC
cvs commit: httpd-2.0/modules/ssl ssl_engine_pphrase.c
jorton 2003/10/22 08:04:11
Modified: modules/ssl ssl_engine_pphrase.c
Log:
Fix a cosmetic issue where OpenSSL 0.9.7 will dump the error stack
during pass phrase entry.
* ssl_engine_pphrase.c (ssl_pphrase_Handle): Clear the OpenSSL error
stack before reading the private key.
Revision Changes Path
1.45 +4 -0 httpd-2.0/modules/ssl/ssl_engine_pphrase.c
Index: ssl_engine_pphrase.c
===================================================================
RCS file: /home/cvs/httpd-2.0/modules/ssl/ssl_engine_pphrase.c,v
retrieving revision 1.44
retrieving revision 1.45
diff -u -u -r1.44 -r1.45
--- ssl_engine_pphrase.c 3 Apr 2003 04:54:20 -0000 1.44
+++ ssl_engine_pphrase.c 22 Oct 2003 15:04:11 -0000 1.45
@@ -374,6 +374,10 @@
cpPassPhraseCur = NULL;
ssl_pphrase_server_rec = s; /* to make up for sslc flaw */
+ /* Ensure that the error stack is empty; otherwise the
+ * OpenSSL UI code may dump it to stderr. */
+ ERR_clear_error();
+
bReadable = ((pPrivateKey = SSL_read_PrivateKey(szPath, NULL,
ssl_pphrase_Handle_CB, s)) != NULL ? TRUE : FALSE);