mirror of
https://github.com/owasp-modsecurity/ModSecurity.git
synced 2025-08-15 23:55:03 +03:00
MODSEC-60
This commit is contained in:
parent
8907f66f3f
commit
fdded33831
@ -575,6 +575,9 @@ static int hook_post_config(apr_pool_t *mp, apr_pool_t *mp_log, apr_pool_t *mp_t
|
||||
ap_log_error(APLOG_MARK, APLOG_NOTICE | APLOG_NOERRNO, 0, s,
|
||||
"%s configured.", MODSEC_MODULE_NAME_FULL);
|
||||
|
||||
/* show libraries informations */
|
||||
version(mp);
|
||||
|
||||
/* If we've changed the server signature make note of the original. */
|
||||
if (new_server_signature != NULL) {
|
||||
ap_log_error(APLOG_MARK, APLOG_NOTICE | APLOG_NOERRNO, 0, s,
|
||||
|
@ -28,6 +28,42 @@
|
||||
#include "apr_global_mutex.h"
|
||||
#include "msc_util.h"
|
||||
|
||||
#include "apr_version.h"
|
||||
#include <libxml/xmlversion.h>
|
||||
|
||||
/*
|
||||
* \brief Print informations from used libraries
|
||||
*
|
||||
* \param mp Pointer to memory pool
|
||||
*/
|
||||
void version(apr_pool_t *mp) {
|
||||
char *pcre_vrs = NULL;
|
||||
|
||||
ap_log_error(APLOG_MARK, APLOG_NOTICE, 0, NULL,
|
||||
"ModSecurity: APR compiled version=\"%s\"; "
|
||||
"loaded version=\"%s\"", APR_VERSION_STRING, apr_version_string());
|
||||
|
||||
if (strstr(apr_version_string(),APR_VERSION_STRING) == NULL) {
|
||||
ap_log_error(APLOG_MARK, APLOG_WARNING, 0, NULL, "ModSecurity: Loaded APR do not match with compiled!");
|
||||
}
|
||||
|
||||
pcre_vrs = apr_psprintf(mp,"%d.%d", PCRE_MAJOR, PCRE_MINOR);
|
||||
|
||||
ap_log_error(APLOG_MARK, APLOG_NOTICE, 0, NULL,
|
||||
"ModSecurity: PCRE compiled version=\"%s\"; "
|
||||
"loaded version=\"%s\"", pcre_vrs, pcre_version());
|
||||
|
||||
if (strstr(pcre_version(),pcre_vrs) == NULL) {
|
||||
ap_log_error(APLOG_MARK, APLOG_WARNING, 0, NULL, "ModSecurity: Loaded PCRE do not match with compiled!");
|
||||
}
|
||||
|
||||
/* Lua version function was removed in current 5.1. Need to check in future versions if it's back */
|
||||
ap_log_error(APLOG_MARK, APLOG_NOTICE, 0, NULL,
|
||||
"ModSecurity: LUA compiled version=\"%s\"",LUA_VERSION);
|
||||
|
||||
ap_log_error(APLOG_MARK, APLOG_NOTICE, 0, NULL,
|
||||
"ModSecurity: LIBXML compiled version=\"%s\"",LIBXML_DOTTED_VERSION);
|
||||
}
|
||||
|
||||
/**
|
||||
* Write the supplied data to the audit log (if the FD is ready), update
|
||||
|
Loading…
x
Reference in New Issue
Block a user