You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Several tests use os.geteuid() == 0 to check whether the current effective user can override discretionary access control and bypass permission checks for files. While user root typically has CAP_DAC_OVERRIDE, it may not actually have the capability. Non-root accounts can have CAP_DAC_OVERRIDE, too. On wasm32-emscripten it is not possible to query the actual effective uid.
I propose to add a check for DAC override instead of relying on effective uid check.
The text was updated successfully, but these errors were encountered:
``os.geteuid() == 0`` is not a reliable check whether the current user
has the capability to bypass permission checks. Tests now probe for DAC
override.
``os.geteuid() == 0`` is not a reliable check whether the current user
has the capability to bypass permission checks. Tests now probe for DAC
override.
``os.geteuid() == 0`` is not a reliable check whether the current user
has the capability to bypass permission checks. Tests now probe for DAC
override.
(cherry picked from commit 7e0d98e)
Co-authored-by: Christian Heimes <christian@python.org>
``os.geteuid() == 0`` is not a reliable check whether the current user
has the capability to bypass permission checks. Tests now probe for DAC
override.
(cherry picked from commit 7e0d98e)
Co-authored-by: Christian Heimes <christian@python.org>
Feature or enhancement
Several tests use
os.geteuid() == 0
to check whether the current effective user can override discretionary access control and bypass permission checks for files. While user root typically has CAP_DAC_OVERRIDE, it may not actually have the capability. Non-root accounts can have CAP_DAC_OVERRIDE, too. On wasm32-emscripten it is not possible to query the actual effective uid.I propose to add a check for DAC override instead of relying on effective uid check.
The text was updated successfully, but these errors were encountered: