Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!

Bug 766258

Summary: sys-apps/portage: CONFIG_PROTECT sometimes (?) ineffective for /etc/python-exec/python-exec.conf
Product: Portage Development Reporter: Michał Górny <mgorny>
Component: UnclassifiedAssignee: Portage team <dev-portage>
Status: CONFIRMED ---    
Severity: normal CC: phmagic, polynomial-c, sam
Priority: Normal    
Version: unspecified   
Hardware: All   
OS: Linux   
Whiteboard:
Package list:
Runtime testing required: ---

Description Michał Górny archtester Gentoo Infrastructure gentoo-dev Security 2021-01-20 09:23:46 UTC
I've recently moved /etc/python-exec/python-exec.conf from dev-lang/python-exec to dev-lang/python-exec-conf, and changed the installed default from empty-ish file to the current PYTHON_TARGETS.  My assumption were that users who had changed the file (either directly or via eselect-python) would have the changes confirmed via CONFIG_PROTECT.

However, Polynomial-C reports that CONFIG_PROTECT fired only on some of his machines, while on others Portage silently replaced his config with a new one.

Zac, any idea what might be happening there?
Comment 1 Zac Medico gentoo-dev 2021-01-20 10:11:28 UTC
The only scenario that I'm aware of is triggered when /etc/python-exec/python-exec.conf had been installed by a binary package created with quickpkg --include-config=y. Then FEATURES=config-protect-if-modified sees the file as unprotected, and therefore it is simply overwritten.