diff mbox series

package/sudo: fix SUDO_ENABLE_SUDO_GROUP_RULE following version bump

Message ID 20220718215158.2167845-1-thomas.petazzoni@bootlin.com
State Accepted
Headers show
Series package/sudo: fix SUDO_ENABLE_SUDO_GROUP_RULE following version bump | expand

Commit Message

Thomas Petazzoni July 18, 2022, 9:51 p.m. UTC
Since the version bump of sudo to v1.9.11p2 in commit 9b7f8da96b, the
sed magic in SUDO_ENABLE_SUDO_GROUP_RULE no longer does its job, due
to a slight change in the example sudoers file provided by upstream
sudo.

This commit fixes the regexp to match the new sudoers file.

Fixes bug #14891 (https://bugs.busybox.net/show_bug.cgi?id=14891)

Reported-by: Matthias Hardt <mhardt@berlinux-solutions.de>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
---
 package/sudo/sudo.mk | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comments

Yann E. MORIN July 18, 2022, 10:05 p.m. UTC | #1
Thomas, All,

On 2022-07-18 23:51 +0200, Thomas Petazzoni via buildroot spake thusly:
> Since the version bump of sudo to v1.9.11p2 in commit 9b7f8da96b, the
> sed magic in SUDO_ENABLE_SUDO_GROUP_RULE no longer does its job, due
> to a slight change in the example sudoers file provided by upstream
> sudo.
> 
> This commit fixes the regexp to match the new sudoers file.
> 
> Fixes bug #14891 (https://bugs.busybox.net/show_bug.cgi?id=14891)
> 
> Reported-by: Matthias Hardt <mhardt@berlinux-solutions.de>
> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>

Applied to master, thanks.

Regards,
Yann E. MORIN.

> ---
>  package/sudo/sudo.mk | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/package/sudo/sudo.mk b/package/sudo/sudo.mk
> index 2b9ba76a51..4f9fdb4b2c 100644
> --- a/package/sudo/sudo.mk
> +++ b/package/sudo/sudo.mk
> @@ -80,7 +80,7 @@ define SUDO_USERS
>  endef
>  
>  define SUDO_ENABLE_SUDO_GROUP_RULE
> -	$(SED) '/^# \%sudo\tALL=(ALL) ALL/s/^# //' $(TARGET_DIR)/etc/sudoers
> +	$(SED) '/^# \%sudo\tALL=(ALL:ALL) ALL/s/^# //' $(TARGET_DIR)/etc/sudoers
>  endef
>  SUDO_POST_INSTALL_TARGET_HOOKS += SUDO_ENABLE_SUDO_GROUP_RULE
>  
> -- 
> 2.36.1
> 
> _______________________________________________
> buildroot mailing list
> buildroot@buildroot.org
> https://lists.buildroot.org/mailman/listinfo/buildroot
diff mbox series

Patch

diff --git a/package/sudo/sudo.mk b/package/sudo/sudo.mk
index 2b9ba76a51..4f9fdb4b2c 100644
--- a/package/sudo/sudo.mk
+++ b/package/sudo/sudo.mk
@@ -80,7 +80,7 @@  define SUDO_USERS
 endef
 
 define SUDO_ENABLE_SUDO_GROUP_RULE
-	$(SED) '/^# \%sudo\tALL=(ALL) ALL/s/^# //' $(TARGET_DIR)/etc/sudoers
+	$(SED) '/^# \%sudo\tALL=(ALL:ALL) ALL/s/^# //' $(TARGET_DIR)/etc/sudoers
 endef
 SUDO_POST_INSTALL_TARGET_HOOKS += SUDO_ENABLE_SUDO_GROUP_RULE