]> granicus.if.org Git - php/commitdiff
sapi/fpm/config.m4: check for libapparmor's aa_change_profile()
authorKees Cook <kees@outflux.net>
Sun, 23 Aug 2020 15:39:53 +0000 (08:39 -0700)
committerNikita Popov <nikita.ppv@gmail.com>
Mon, 24 Aug 2020 08:10:12 +0000 (10:10 +0200)
The fpm code actually uses aa_change_profile(), not change_hat(). Test
for the correct function. (libapparmor always has both, so this is just
a correctness fix.)

Closes GH-6037.

sapi/fpm/config.m4

index 9d2b8c7349c259e9a4e09a75ef8cfc3db157fd03..7c2fdec12202889774490fcb2295f1f5b408a346 100644 (file)
@@ -571,7 +571,7 @@ if test "$PHP_FPM" != "no"; then
 
   if test "x$PHP_FPM_APPARMOR" != "xno" ; then
     AC_CHECK_HEADERS([sys/apparmor.h])
-    AC_CHECK_LIB(apparmor, change_hat, [
+    AC_CHECK_LIB(apparmor, aa_change_profile, [
       PHP_ADD_LIBRARY(apparmor)
       AC_DEFINE(HAVE_APPARMOR, 1, [ AppArmor confinement available ])
     ],[