diff mbox series

[langdale,15/23] cups: check PACKAGECONFIG for pam feature

Message ID 2dd5c6ccdce2e402de234df3695a9058a8a126db.1679003014.git.steve@sakoman.com
State New
Headers show
Series [langdale,01/23] harfbuzz: Security fix for CVE-2023-25193 | expand

Commit Message

Steve Sakoman March 16, 2023, 9:45 p.m. UTC
From: Trevor Woerner <twoerner@gmail.com>

The cups' PACKAGECONFIG is populated based on DISTRO_FEATURES, but a user
is free to enable or disable PACKAGECONFIGs at will. In theory it is
possible that pam is enabled globally in DISTRO_FEATURES but disabled in
cups' PACKAGECONFIG. Checking the PACKAGECONFIG to determine whether or not
pam is enabled would be a safer check rather than relying on DISTRO_FEATURES.

Signed-off-by: Trevor Woerner <twoerner@gmail.com>
Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com>
(cherry picked from commit a053dd177ddc99ced11e68914079be0ffe261262)
Signed-off-by: Steve Sakoman <steve@sakoman.com>
 meta/recipes-extended/cups/cups.inc | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
diff mbox series


diff --git a/meta/recipes-extended/cups/cups.inc b/meta/recipes-extended/cups/cups.inc
index b8b655a4fb..1b522d7d85 100644
--- a/meta/recipes-extended/cups/cups.inc
+++ b/meta/recipes-extended/cups/cups.inc
@@ -74,7 +74,7 @@  do_install () {
 	rmdir ${D}/${libexecdir}/${BPN}/driver
 	# Fix the pam configuration file permissions
-	if ${@bb.utils.contains('DISTRO_FEATURES', 'pam', 'true', 'false', d)}; then
+	if ${@bb.utils.contains('PACKAGECONFIG', 'pam', 'true', 'false', d)}; then
 	    chmod 0644 ${D}${sysconfdir}/pam.d/cups