mirror of
https://github.com/owasp-modsecurity/ModSecurity.git
synced 2025-09-29 19:24:29 +03:00
Adds whoAmI method to ModSecurity class
The method returns information about the ModSecurity's version and the platform that it was compiled. Further it will be used by the audit logs and by the connectors. msc_who_am_i was added accordingly, to the C api.
This commit is contained in:
49
configure.ac
49
configure.ac
@@ -49,6 +49,55 @@ AC_CHECK_HEADERS([sys/utsname.h])
|
||||
# ??
|
||||
LT_INIT([dlopen])
|
||||
|
||||
# Identify platform
|
||||
AC_CANONICAL_HOST
|
||||
|
||||
case $host in
|
||||
*-*-aix*)
|
||||
echo "Checking platform... Identified as AIX"
|
||||
AC_DEFINE([AIX], [1], [Define if the operating system is AIX])
|
||||
;;
|
||||
*-*-hpux*)
|
||||
echo "Checking platform... Identified as HPUX"
|
||||
AC_DEFINE([HPUX], [1], [Define if the operating system is HPUX])
|
||||
;;
|
||||
*-*-darwin*)
|
||||
echo "Checking platform... Identified as Macintosh OS X"
|
||||
AC_DEFINE([MACOSX], [1], [Define if the operating system is Macintosh OSX])
|
||||
;;
|
||||
*-*-linux*)
|
||||
echo "Checking platform... Identified as Linux"
|
||||
AC_DEFINE([LINUX], [1], [Define if the operating system is LINUX])
|
||||
;;
|
||||
*-*-solaris*)
|
||||
echo "Checking platform... Identified as Solaris"
|
||||
AC_DEFINE([SOLARIS], [1], [Define if the operating system is SOLARIS])
|
||||
;;
|
||||
*-*-freebsd*)
|
||||
echo "Checking platform... Identified as FreeBSD"
|
||||
AC_DEFINE([FREEBSD], [1], [Define if the operating system is FREEBSD])
|
||||
;;
|
||||
*-*-netbsd*)
|
||||
echo "Checking platform... Identified as NetBSD"
|
||||
AC_DEFINE([NETBSD], [1], [Define if the operating system is NETBSD])
|
||||
;;
|
||||
*-*-openbsd*)
|
||||
echo "Checking platform... Identified as OpenBSD"
|
||||
AC_DEFINE([OPENBSD], [1], [Define if the operating system is OPENBSD])
|
||||
;;
|
||||
*-*-kfreebsd*)
|
||||
echo "Checking platform... Identified as kFreeBSD, treating as linux"
|
||||
AC_DEFINE([FREEBSD], [1], [Define if the operating system is FREEBSD])
|
||||
;;
|
||||
*-*-gnu*.*)
|
||||
echo "Checking platform... Identified as HURD, treating as linux"
|
||||
AC_DEFINE([LINUX], [1], [Define if the operating system is LINUX])
|
||||
;;
|
||||
*)
|
||||
echo "Unknown CANONICAL_HOST $host"
|
||||
exit
|
||||
;;
|
||||
esac
|
||||
|
||||
# Variables to be used inside the Makefile.am files.
|
||||
MSC_BASE_DIR=`pwd`
|
||||
|
Reference in New Issue
Block a user