Репозиторий Sisyphus
Последнее обновление: 1 октября 2023 | Пакетов: 18631 | Посещений: 37568753
en ru br
Репозитории ALT
S:0.25.4-alt1
5.1: 0.16.8.9-alt1
4.1: 0.16.8.9-alt1
3.0: 0.16.7-alt1_2
www.altlinux.org/Changes

Группа :: Графические оболочки/Enlightenment
Пакет: enlightenment

 Главная   Изменения   Спек   Патчи   Sources   Загрузить   Gear   Bugs and FR  Repocop 

Патч: enlightenment-0.19.0-alt-pam-helper.patch
Скачать


diff -durN enlightenment-0.19.0.orig/config.h.in enlightenment-0.19.0/config.h.in
--- enlightenment-0.19.0.orig/config.h.in	2014-09-15 17:55:28.000000000 +0400
+++ enlightenment-0.19.0/config.h.in	2014-09-18 22:05:35.737560110 +0400
@@ -125,6 +125,9 @@
 /* PAM Authentication Support */
 #undef HAVE_PAM
 
+/* PAM Authentication helper Support */
+#undef USE_PAM_HELPER
+
 /* Define to 1 if you have the <security/pam_appl.h> header file. */
 #undef HAVE_SECURITY_PAM_APPL_H
 
diff -durN enlightenment-0.19.0.orig/configure.ac enlightenment-0.19.0/configure.ac
--- enlightenment-0.19.0.orig/configure.ac	2014-09-15 17:54:55.000000000 +0400
+++ enlightenment-0.19.0/configure.ac	2014-09-18 22:05:35.741560040 +0400
@@ -129,6 +129,16 @@
     fi
 fi
 
+use_pam_helper=no
+AC_ARG_WITH(pam-helper,
+  AC_HELP_STRING([--with-pam-helper], [with PAM helper @<:@default=no@:>@]),
+  [use_pam_helper=$withval],
+  [use_pam_helper=no]
+)
+if test "x$use_pam_helper" != "xno" ; then
+  AC_DEFINE_UNQUOTED(USE_PAM_HELPER, "$use_pam_helper", [PAM Authentication helper path])
+fi
+
 dnl AC_E_CHECK_PKG(VALGRIND, [valgrind >= 2.4.0], [], [:])
 AC_SUBST([VALGRIND_CFLAGS])
 AC_SUBST([VALGRIND_LIBS])
diff -durN enlightenment-0.19.0.orig/src/bin/e_auth.c enlightenment-0.19.0/src/bin/e_auth.c
--- enlightenment-0.19.0.orig/src/bin/e_auth.c	2014-09-09 20:28:12.000000000 +0400
+++ enlightenment-0.19.0/src/bin/e_auth.c	2014-09-19 07:22:39.696540716 +0400
@@ -144,7 +144,22 @@
    _e_auth_child_pid = fork();
    if (_e_auth_child_pid > 0) return _e_auth_child_pid;
    if (_e_auth_child_pid < 0) return -1;
+#ifdef USE_PAM_HELPER
+        if (!access(USE_PAM_HELPER, X_OK)) {
+          FILE *fp = popen(USE_PAM_HELPER, "w");
+
+          if (fp)
+            {
+               int status;
 
+               fputs(passwd, fp);
+               status = pclose(fp);
+               if (WIFEXITED(status) && WEXITSTATUS(status) == 0)
+                 exit(0);
+            }
+          exit(-1);
+        }
+#endif
    action.sa_handler = SIG_DFL;
    action.sa_flags = SA_ONSTACK | SA_NODEFER | SA_RESETHAND | SA_SIGINFO;
    sigemptyset(&action.sa_mask);
 
дизайн и разработка: Vladimir Lettiev aka crux © 2004-2005, Andrew Avramenko aka liks © 2007-2008
текущий майнтейнер: Michael Shigorin