summaryrefslogtreecommitdiffstats
path: root/nss_engine_kernel.c
diff options
context:
space:
mode:
authorRob Crittenden <rcritten@redhat.com>2015-09-30 20:32:46 -0400
committerRob Crittenden <rcritten@redhat.com>2015-10-02 16:51:56 -0400
commit979a74f6ce2e61fb607414d9ce5f39226630bab2 (patch)
treec5801695e918d87af2e0d02ded72ec08b09f4e14 /nss_engine_kernel.c
parentd42edc43ef8bd40897f5dc599eb4c02b7e69e4b2 (diff)
Fix compatibility with RHEL 6.x (Apache 2.2.x and NSS 3.15.1)
Diffstat (limited to 'nss_engine_kernel.c')
-rw-r--r--nss_engine_kernel.c11
1 files changed, 10 insertions, 1 deletions
diff --git a/nss_engine_kernel.c b/nss_engine_kernel.c
index 93e7c74..28042fb 100644
--- a/nss_engine_kernel.c
+++ b/nss_engine_kernel.c
@@ -17,6 +17,8 @@
#include "secerr.h"
static void HandshakeDone(PRFileDesc *fd, void *doneflag);
+extern cipher_properties ciphers_def[];
+extern int ciphernum;
/*
* Post Read Request Handler
@@ -144,7 +146,11 @@ int nss_hook_ReadReq(request_rec *r)
/*
* Log information about incoming HTTPS requests
*/
+#if AP_SERVER_MINORVERSION_NUMBER <= 2
+ if (r->server->loglevel >= APLOG_INFO && ap_is_initial_req(r)) {
+#else
if (r->server->log.level >= APLOG_INFO && ap_is_initial_req(r)) {
+#endif
ap_log_error(APLOG_MARK, APLOG_INFO, 0, r->server,
"%s HTTPS request received for child %ld (server %s)",
(r->connection->keepalives <= 0 ?
@@ -180,7 +186,6 @@ int nss_hook_Access(request_rec *r)
CERTCertificate *cert;
CERTCertificate *peercert;
int verify_old, verify;
- extern cipher_properties ciphers_def[];
PRBool ciphers_old[ciphernum];
PRBool ciphers_new[ciphernum];
char * cipher = NULL;
@@ -633,7 +638,11 @@ int nss_hook_Access(request_rec *r)
ap_log_error(APLOG_MARK, APLOG_INFO, 0, r->server,
"Access to %s denied for %s "
"(requirement expression not fulfilled)",
+#if AP_SERVER_MINORVERSION_NUMBER <= 2
+ r->filename, r->connection->remote_ip);
+#else
r->filename, r->connection->client_ip);
+#endif
ap_log_error(APLOG_MARK, APLOG_INFO, 0, r->server,
"Failed expression: %s", req->cpExpr);