From 59763dd8e587d1821f2d039b2bf446c3a31ea58e Mon Sep 17 00:00:00 2001 From: Tycho Andersen Date: Tue, 20 Jun 2017 17:08:17 +0000 Subject: testing/auditd: bump audit version to 2.7.2 * update all the patches * swap out the 4th patch for a proper include of limits.h * reset package version to -r1 Signed-off-by: Tycho Andersen --- ...clude-headers-to-make-build-work-with-mus.patch | 8 ++++---- .../0002-auparse-remove-use-of-rawmemchr.patch | 16 +++++++-------- testing/audit/0003-all-get-rid-of-strndupa.patch | 14 ++++++------- ...p-audispd.c-Include-limits.h-for-PATH_MAX.patch | 24 ++++++++++++++++++++++ testing/audit/0004-path_max.patch | 23 --------------------- testing/audit/APKBUILD | 16 +++++++-------- 6 files changed, 51 insertions(+), 50 deletions(-) create mode 100644 testing/audit/0004-audisp-audispd.c-Include-limits.h-for-PATH_MAX.patch delete mode 100644 testing/audit/0004-path_max.patch (limited to 'testing') diff --git a/testing/audit/0001-auditctl-include-headers-to-make-build-work-with-mus.patch b/testing/audit/0001-auditctl-include-headers-to-make-build-work-with-mus.patch index 8747c7d450..94614afce4 100644 --- a/testing/audit/0001-auditctl-include-headers-to-make-build-work-with-mus.patch +++ b/testing/audit/0001-auditctl-include-headers-to-make-build-work-with-mus.patch @@ -1,7 +1,7 @@ -From 12e2693a4868c7f925ad528bb1dafd15d80616bb Mon Sep 17 00:00:00 2001 +From 49ed6ac0e07bc30231ce53ca5a5e150fccd4d860 Mon Sep 17 00:00:00 2001 From: Tycho Andersen Date: Mon, 13 Mar 2017 22:44:19 +0000 -Subject: [PATCH 1/3] auditctl: include headers to make build work with musl +Subject: [PATCH 1/4] auditctl: include headers to make build work with musl technically select is defined in sys/select.h, and `struct timeval` requires sys/time.h @@ -12,7 +12,7 @@ Signed-off-by: Tycho Andersen 1 file changed, 2 insertions(+) diff --git a/src/auditctl.c b/src/auditctl.c -index e112b16..11d2dc7 100644 +index 04765f4..07701f9 100644 --- a/src/auditctl.c +++ b/src/auditctl.c @@ -32,6 +32,8 @@ @@ -25,5 +25,5 @@ index e112b16..11d2dc7 100644 #include #include /* For basename */ -- -2.11.1 +2.13.1 diff --git a/testing/audit/0002-auparse-remove-use-of-rawmemchr.patch b/testing/audit/0002-auparse-remove-use-of-rawmemchr.patch index de774b3a8e..891a87bbc3 100644 --- a/testing/audit/0002-auparse-remove-use-of-rawmemchr.patch +++ b/testing/audit/0002-auparse-remove-use-of-rawmemchr.patch @@ -1,7 +1,7 @@ -From d28763047fd0937a4f150402d2760b3ddcd3a651 Mon Sep 17 00:00:00 2001 +From 8f2a6788b78dd6b219545aacbd42e2f84df8c71a Mon Sep 17 00:00:00 2001 From: Tycho Andersen Date: Mon, 13 Mar 2017 16:17:10 -0700 -Subject: [PATCH 2/3] auparse: remove use of rawmemchr +Subject: [PATCH 2/4] auparse: remove use of rawmemchr just iterate over the string instead, it's much simpler and doesn't use a glibc extension. @@ -12,13 +12,13 @@ Signed-off-by: Tycho Andersen 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/auparse/interpret.c b/auparse/interpret.c -index 1f517d7..57da00c 100644 +index ea17c41..75b7679 100644 --- a/auparse/interpret.c +++ b/auparse/interpret.c -@@ -803,10 +803,9 @@ static const char *print_proctitle(const char *val) - size_t len = strlen(val) / 2; - const char *end = out + len; - char *ptr = out; +@@ -819,10 +819,9 @@ static const char *print_proctitle(const char *val) + // Proctitle has arguments separated by NUL bytes + // We need to write over the NUL bytes with a space + // so that we can see the arguments - while ((ptr = rawmemchr(ptr, '\0'))) { - if (ptr >= end) - break; @@ -30,5 +30,5 @@ index 1f517d7..57da00c 100644 } } -- -2.11.1 +2.13.1 diff --git a/testing/audit/0003-all-get-rid-of-strndupa.patch b/testing/audit/0003-all-get-rid-of-strndupa.patch index e705de4c37..d34bf0cfb7 100644 --- a/testing/audit/0003-all-get-rid-of-strndupa.patch +++ b/testing/audit/0003-all-get-rid-of-strndupa.patch @@ -1,7 +1,7 @@ -From f45e805033c6aed205863d87fe56f5bc7e6fd0c4 Mon Sep 17 00:00:00 2001 +From 38d950e468c1e51937530f884b138076e4897da2 Mon Sep 17 00:00:00 2001 From: Tycho Andersen Date: Mon, 13 Mar 2017 16:40:08 -0700 -Subject: [PATCH 3/3] all: get rid of strndupa +Subject: [PATCH 3/4] all: get rid of strndupa in one case (src/auditd.c) we don't even need to allocate a buffer, in the other two we do it in two steps to avoid using a non-standard function. @@ -14,10 +14,10 @@ Signed-off-by: Tycho Andersen 3 files changed, 13 insertions(+), 9 deletions(-) diff --git a/auparse/auparse.c b/auparse/auparse.c -index 3677ad7..b428330 100644 +index 058f544..f61d204 100644 --- a/auparse/auparse.c +++ b/auparse/auparse.c -@@ -1096,10 +1096,12 @@ static int extract_timestamp(const char *b, au_event_t *e) +@@ -1102,10 +1102,12 @@ static int extract_timestamp(const char *b, au_event_t *e) int rc = 1; e->host = NULL; @@ -33,7 +33,7 @@ index 3677ad7..b428330 100644 if (ptr) { // Optionally grab the node - may or may not be included diff --git a/src/auditd.c b/src/auditd.c -index 3f0162d..a1c2c51 100644 +index cd49758..2de065a 100644 --- a/src/auditd.c +++ b/src/auditd.c @@ -185,7 +185,7 @@ static void child_handler2( int sig ) @@ -63,7 +63,7 @@ index 3f0162d..a1c2c51 100644 str++; return audit_name_to_msg_type(str); diff --git a/src/ausearch-lol.c b/src/ausearch-lol.c -index b1aec06..5d461b0 100644 +index 29d0a32..3a2e5e8 100644 --- a/src/ausearch-lol.c +++ b/src/ausearch-lol.c @@ -135,10 +135,12 @@ static int extract_timestamp(const char *b, event *e) @@ -82,5 +82,5 @@ index b1aec06..5d461b0 100644 if (ptr) { // Check to see if this is the node info -- -2.11.1 +2.13.1 diff --git a/testing/audit/0004-audisp-audispd.c-Include-limits.h-for-PATH_MAX.patch b/testing/audit/0004-audisp-audispd.c-Include-limits.h-for-PATH_MAX.patch new file mode 100644 index 0000000000..72baf90013 --- /dev/null +++ b/testing/audit/0004-audisp-audispd.c-Include-limits.h-for-PATH_MAX.patch @@ -0,0 +1,24 @@ +From 8c803432699a815349c73630e620d5eaa4a16727 Mon Sep 17 00:00:00 2001 +From: Felix Janda +Date: Mon, 19 Jun 2017 21:14:24 -0400 +Subject: [PATCH 4/4] audisp/audispd.c: Include for PATH_MAX + +--- + audisp/audispd.c | 1 + + 1 file changed, 1 insertion(+) + +diff --git a/audisp/audispd.c b/audisp/audispd.c +index 9831cf3..329b629 100644 +--- a/audisp/audispd.c ++++ b/audisp/audispd.c +@@ -34,6 +34,7 @@ + #include + #include + #include ++#include + + #include "audispd-config.h" + #include "audispd-pconfig.h" +-- +2.13.1 + diff --git a/testing/audit/0004-path_max.patch b/testing/audit/0004-path_max.patch deleted file mode 100644 index a9892bb551..0000000000 --- a/testing/audit/0004-path_max.patch +++ /dev/null @@ -1,23 +0,0 @@ -From ab123cbbffe90aefe1579d2708bae43e53e5afb4 Tue April 25 00:00:00 2001 -From: Breno Leitao -Date: Tue, 25 April 2017 12:33:43 +0000 -Subject: [PATCH] Define PATH_MAX if not defined - -PATH_MAX is not being defined on ppc64le, which causes a FTBFS. -This patch check that it is defined, otherwise, defines it. - -Signed-off-by: Breno Leitao - ---- a/lib/libaudit.h -+++ b/lib/libaudit.h -@@ -637,6 +637,10 @@ - int audit_can_write(void); - int audit_can_read(void); - -+#if !defined(PATH_MAX) -+#define PATH_MAX 4096 -+#endif -+ - #ifdef __cplusplus - } - #endif diff --git a/testing/audit/APKBUILD b/testing/audit/APKBUILD index 2309ce093f..f84147f079 100644 --- a/testing/audit/APKBUILD +++ b/testing/audit/APKBUILD @@ -1,7 +1,7 @@ # Maintainer: Tycho Andersen pkgname=audit -pkgver=2.7.2 -pkgrel=2 +pkgver=2.7.7 +pkgrel=1 pkgdesc="User space tools for 2.6 kernel auditing" url="http://people.redhat.com/sgrubb/audit/" arch="all" @@ -15,7 +15,7 @@ source="http://people.redhat.com/sgrubb/audit/audit-$pkgver.tar.gz 0001-auditctl-include-headers-to-make-build-work-with-mus.patch 0002-auparse-remove-use-of-rawmemchr.patch 0003-all-get-rid-of-strndupa.patch - 0004-path_max.patch + 0004-audisp-audispd.c-Include-limits.h-for-PATH_MAX.patch auditd.initd auditd.confd " @@ -61,10 +61,10 @@ static() { mv "$pkgdir"/lib/*.a "$subpkgdir"/lib/ } -sha512sums="a3974547a6da15e87c9070f3aa8a40232555afbd8d6cdf41e6d3c2a059f766ae75febbe8ff72fdadb522222eefda08e55f10dd8d20a3cee2625a6048d38c152b audit-2.7.2.tar.gz -9070de8b9d778c2907adfcb78a02c3a243ed1951d399184679518493a7eca1560878616ace1f661005bda9384e8fc6fde103298c9c57d8883786210939927ecc 0001-auditctl-include-headers-to-make-build-work-with-mus.patch -bede955da1a31b42fbb259ea88cfca97e9a4263987e5982eeeee78a74524ce5f819872cbf404551dcce490ad188cd6a0eee65312ca7665c295581801c92bbb05 0002-auparse-remove-use-of-rawmemchr.patch -41c50d8203ba8d31bd0e4fbcacbf9f15d6d83aae77660d815aecfe75e0cd40e587730becb725431f0416da14468b85c7a13739040498869d64a30ef0602081c1 0003-all-get-rid-of-strndupa.patch -c83183a7c530816b830777590f5e5f385aa81ecfee64249691a6d63310a053057bae90e60e3d68c4d2997f9e35f3589eecbe6dbdb6c53849888bd025cc4b9636 0004-path_max.patch +sha512sums="a465a0526acd647f21cc3625c12107a719abf31c6e76b5d3c7bf17796bfd970af51b892d878162dbd5e6be283f156927daeb24427d1a628125a579965423ff2e audit-2.7.7.tar.gz +119c57eb6aee67b30dcd2252513e2595dc0686b7135529928fed68ab64d0e7a46901ed6a242c90b183a1e02099668ba1c7ef05a17e5dfaa6ca74c01a36e560bf 0001-auditctl-include-headers-to-make-build-work-with-mus.patch +b7851d4c3c6d7d35f2e822273c17ab530ac24301c414da7f0c7578b7a182692ecd01b51cb50ea04adba4b43987f27020f8f411aec23b3bda0af4d4b6e9fbae5d 0002-auparse-remove-use-of-rawmemchr.patch +c380c04fc1939903eea9919d5a918f58725177adee1fe7dbe81e33905bad2f561dc35cae9f3d79aa6f00245cf33cdd50cef5e2b58f4fa5b8cd0cfad59af7137a 0003-all-get-rid-of-strndupa.patch +ca1d38b8af822f6506cead858070a7f90ae8cf851556cb9288e31614d288e723efe684777c5f64b61f3988a427a714eb306e53fff93e670342b7a618c6196d69 0004-audisp-audispd.c-Include-limits.h-for-PATH_MAX.patch 1b48c248db5d34f148f9c79f8b2a6acbf61c729230341b861f5e331bbfb0c8356305a09eb2cc5c82c14c4fd9a13c7c13957e1ed493834b8b3b9ee38978e4c31f auditd.initd 69d8777772ded7a8c0db2bcf84961b121bb355fa0d4ba0e14e311f8a8bfe665cbd2b7ac632d73477f9dfa9a6eec357a7ed458fe9b3e7b5ede75b166f3f092ab7 auditd.confd" -- cgit v1.2.3