diff --git a/.augeas.metadata b/.augeas.metadata new file mode 100644 index 0000000..9713e4d --- /dev/null +++ b/.augeas.metadata @@ -0,0 +1 @@ +22c15195bf6c7e71b4cfa2cc387b30a65ce75e65 augeas-1.13.0.tar.gz diff --git a/0001-Chrony-add-new-directives-and-options-745.patch b/0001-Chrony-add-new-directives-and-options-745.patch index 91e6345..4297c64 100644 --- a/0001-Chrony-add-new-directives-and-options-745.patch +++ b/0001-Chrony-add-new-directives-and-options-745.patch @@ -1,7 +1,7 @@ From 08101c754aafab4d0f79367839bbd0d6012c31cf Mon Sep 17 00:00:00 2001 From: Miroslav Lichvar Date: Wed, 2 Mar 2022 14:54:39 +0100 -Subject: [PATCH 1/4] Chrony: add new directives and options (#745) +Subject: [PATCH 1/5] Chrony: add new directives and options (#745) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit diff --git a/0002-Kdump-parse-auto_reset_crashkernel-754.patch b/0002-Kdump-parse-auto_reset_crashkernel-754.patch index edea2f3..47fde06 100644 --- a/0002-Kdump-parse-auto_reset_crashkernel-754.patch +++ b/0002-Kdump-parse-auto_reset_crashkernel-754.patch @@ -1,7 +1,7 @@ From e0bce2e8c21ccc69729676e8dc6fa1e541aedee2 Mon Sep 17 00:00:00 2001 From: Laszlo Ersek Date: Wed, 20 Apr 2022 10:13:06 +0200 -Subject: [PATCH 2/4] Kdump: parse "auto_reset_crashkernel" (#754) +Subject: [PATCH 2/5] Kdump: parse "auto_reset_crashkernel" (#754) The "auto_reset_crashkernel" keyword was introduced in the following kexec-tools patch set: diff --git a/0003-semanage-Fix-parsing-of-ignoredirs-758.patch b/0003-semanage-Fix-parsing-of-ignoredirs-758.patch index 2e6963c..3939ef8 100644 --- a/0003-semanage-Fix-parsing-of-ignoredirs-758.patch +++ b/0003-semanage-Fix-parsing-of-ignoredirs-758.patch @@ -1,7 +1,7 @@ From aca3def462ab141c3991a2d27c44341b809cf970 Mon Sep 17 00:00:00 2001 From: rwmjones Date: Thu, 6 Oct 2022 12:15:56 +0100 -Subject: [PATCH 3/4] semanage: Fix parsing of ignoredirs (#758) +Subject: [PATCH 3/5] semanage: Fix parsing of ignoredirs (#758) From /etc/selinux/semanage.conf from a RHEL 9.1 system, this line caused problems: diff --git a/0004-Tmpfiles-allow-for-letter-types-allow-as-prefix-for-.patch b/0004-Tmpfiles-allow-for-letter-types-allow-as-prefix-for-.patch index 787ad89..71048ca 100644 --- a/0004-Tmpfiles-allow-for-letter-types-allow-as-prefix-for-.patch +++ b/0004-Tmpfiles-allow-for-letter-types-allow-as-prefix-for-.patch @@ -1,7 +1,7 @@ From 34749f9ea1af8e3fad9e60891beda0fe786cb0f2 Mon Sep 17 00:00:00 2001 From: Pino Toscano Date: Fri, 24 Mar 2023 11:26:46 +0100 -Subject: [PATCH 4/4] Tmpfiles: allow '=', '~', '^' for letter types, allow ":" +Subject: [PATCH 4/5] Tmpfiles: allow '=', '~', '^' for letter types, allow ":" as prefix for the mode * Tmpfiles: allow '=', '~', '^' for letter types diff --git a/0005-lenses-Allow-whitespace-at-the-end-of-kernel-commnd-.patch b/0005-lenses-Allow-whitespace-at-the-end-of-kernel-commnd-.patch new file mode 100644 index 0000000..7f313b1 --- /dev/null +++ b/0005-lenses-Allow-whitespace-at-the-end-of-kernel-commnd-.patch @@ -0,0 +1,44 @@ +From f4a9ca77e5dba3659cfadd9e12ba96b32befdaab Mon Sep 17 00:00:00 2001 +From: rwmjones +Date: Sun, 5 Mar 2023 10:30:43 +0000 +Subject: [PATCH 5/5] lenses: Allow whitespace at the end of kernel commnd line + (#798) + +Reported-by: Yongkui Guo +Fixes: https://bugzilla.redhat.com/show_bug.cgi?id=2159282 + +Signed-off-by: Richard W.M. Jones +(cherry picked from commit 801aa73db3c356378467622a7e02dea21ccf4332) +--- + lenses/cmdline.aug | 2 +- + lenses/tests/test_cmdline.aug | 1 + + 2 files changed, 2 insertions(+), 1 deletion(-) + +diff --git a/lenses/cmdline.aug b/lenses/cmdline.aug +index b8b5176d..30e9aac7 100644 +--- a/lenses/cmdline.aug ++++ b/lenses/cmdline.aug +@@ -13,7 +13,7 @@ module Cmdline = + + let entry = [ key Rx.word . Util.del_str "=" . store Rx.no_spaces ] | [ key Rx.word ] + +-let lns = (Build.opt_list entry Sep.space)? . del /\n?/ "" ++let lns = (Build.opt_list entry Sep.space)? . del /[ \t]*\n?/ "" + + let filter = incl "/etc/kernel/cmdline" + . incl "/proc/cmdline" +diff --git a/lenses/tests/test_cmdline.aug b/lenses/tests/test_cmdline.aug +index 0624a0b2..77a429d8 100644 +--- a/lenses/tests/test_cmdline.aug ++++ b/lenses/tests/test_cmdline.aug +@@ -4,6 +4,7 @@ let lns = Cmdline.lns + + test lns get "foo\nbar" = * + test lns get "foo\n" = { "foo" } ++test lns get "foo \n" = { "foo" } + test lns get "foo" = { "foo" } + test lns get "foo bar" = { "foo" } { "bar" } + test lns get "foo bar" = { "foo" } { "bar" } +-- +2.31.1 + diff --git a/augeas.spec b/augeas.spec index a63af7b..8d81d9e 100644 --- a/augeas.spec +++ b/augeas.spec @@ -1,6 +1,6 @@ Name: augeas Version: 1.13.0 -Release: 4%{?dist} +Release: 5%{?dist} Summary: A library for changing configuration files License: LGPLv2+ @@ -30,6 +30,10 @@ Patch3: 0003-semanage-Fix-parsing-of-ignoredirs-758.patch # Upstream commit 41b2a33ff02687fa53d69a012a1d47141b196a86 Patch4: 0004-Tmpfiles-allow-for-letter-types-allow-as-prefix-for-.patch +# Fix parsing of /etc/kernel/cmdline +# Upstream commit 801aa73db3c356378467622a7e02dea21ccf4332 +Patch5: 0005-lenses-Allow-whitespace-at-the-end-of-kernel-commnd-.patch + Provides: bundled(gnulib) BuildRequires: make @@ -148,7 +152,8 @@ rm -f $RPM_BUILD_ROOT/usr/bin/dump %changelog * Tue Apr 04 2023 Richard W.M. Jones - 1.13.0-4 - Fix parsing of /usr/lib/tmpfiles.d/provision.conf - resolves: rhbz#2155136 +- Fix parsing of /etc/kernel/cmdline + resolves: rhbz#2155136, rhbz#2159282 * Thu Oct 06 2022 Richard W.M. Jones - 1.13.0-3 - Fix parsing of /etc/selinux/semanage.conf in RHEL 9