forked from pool/pam_wrapper
Add pam_wrapper from https://cwrap.org to devel:tools like the others ... OBS-URL: https://build.opensuse.org/request/show/354484 OBS-URL: https://build.opensuse.org/package/show/devel:tools/pam_wrapper?expand=0&rev=1
92 lines
2.5 KiB
Diff
92 lines
2.5 KiB
Diff
From 8b401834e1b33ba9dda530a1e9cd76beb54aec91 Mon Sep 17 00:00:00 2001
|
|
From: Andreas Schneider <asn@samba.org>
|
|
Date: Thu, 14 Jan 2016 13:46:01 +0100
|
|
Subject: [PATCH 1/3] cmake: Do not require a C++ compiler
|
|
|
|
Signed-off-by: Andreas Schneider <asn@samba.org>
|
|
---
|
|
src/modules/CMakeLists.txt | 2 +-
|
|
src/python/CMakeLists.txt | 2 +-
|
|
2 files changed, 2 insertions(+), 2 deletions(-)
|
|
|
|
diff --git a/src/modules/CMakeLists.txt b/src/modules/CMakeLists.txt
|
|
index 93ce522..8e13a0b 100644
|
|
--- a/src/modules/CMakeLists.txt
|
|
+++ b/src/modules/CMakeLists.txt
|
|
@@ -1,4 +1,4 @@
|
|
-project(pam_wrapper-modules)
|
|
+project(pam_wrapper-modules C)
|
|
|
|
set(PAM_MODULES pam_matrix pam_get_items pam_set_items)
|
|
|
|
diff --git a/src/python/CMakeLists.txt b/src/python/CMakeLists.txt
|
|
index 108daae..2906d3e 100644
|
|
--- a/src/python/CMakeLists.txt
|
|
+++ b/src/python/CMakeLists.txt
|
|
@@ -1,4 +1,4 @@
|
|
-project(pypamtest)
|
|
+project(pypamtest C)
|
|
|
|
include_directories(${CMAKE_BINARY_DIR})
|
|
include_directories(${pam_wrapper-headers_DIR})
|
|
--
|
|
2.7.0
|
|
|
|
|
|
From 8b41fc2429cfabdc3213b5baaa9fe5911936dc9f Mon Sep 17 00:00:00 2001
|
|
From: Andreas Schneider <asn@samba.org>
|
|
Date: Thu, 14 Jan 2016 17:04:07 +0100
|
|
Subject: [PATCH 2/3] cmake: Link python module against the python library
|
|
|
|
Signed-off-by: Andreas Schneider <asn@samba.org>
|
|
---
|
|
src/python/CMakeLists.txt | 2 +-
|
|
1 file changed, 1 insertion(+), 1 deletion(-)
|
|
|
|
diff --git a/src/python/CMakeLists.txt b/src/python/CMakeLists.txt
|
|
index 2906d3e..cbee2a6 100644
|
|
--- a/src/python/CMakeLists.txt
|
|
+++ b/src/python/CMakeLists.txt
|
|
@@ -5,7 +5,7 @@ include_directories(${pam_wrapper-headers_DIR})
|
|
include_directories(${PYTHON_INCLUDE_DIR})
|
|
|
|
python_add_module(pypamtest pypamtest.c)
|
|
-target_link_libraries(pypamtest pamtest)
|
|
+target_link_libraries(pypamtest pamtest ${PYTHON_LIBRARY})
|
|
|
|
install(
|
|
TARGETS
|
|
--
|
|
2.7.0
|
|
|
|
|
|
From 13ee3e87a0f4f96c5593f5c14db9c80c07ef4b95 Mon Sep 17 00:00:00 2001
|
|
From: Andreas Schneider <asn@samba.org>
|
|
Date: Thu, 14 Jan 2016 17:04:33 +0100
|
|
Subject: [PATCH 3/3] pwrap: Return EPROTONOSUPPORT in audit_open()
|
|
|
|
I don't know why but returning EINVAL doesn't work. It treats it as
|
|
success and tries to write to it.
|
|
|
|
Signed-off-by: Andreas Schneider <asn@samba.org>
|
|
---
|
|
src/pam_wrapper.c | 2 +-
|
|
1 file changed, 1 insertion(+), 1 deletion(-)
|
|
|
|
diff --git a/src/pam_wrapper.c b/src/pam_wrapper.c
|
|
index 0c451d1..a388b29 100644
|
|
--- a/src/pam_wrapper.c
|
|
+++ b/src/pam_wrapper.c
|
|
@@ -1523,7 +1523,7 @@ int audit_open(void)
|
|
* Tell the application that the kernel doesn't
|
|
* have audit compiled in.
|
|
*/
|
|
- errno = EINVAL;
|
|
+ errno = EPROTONOSUPPORT;
|
|
return -1;
|
|
}
|
|
|
|
--
|
|
2.7.0
|
|
|