Skip to content

gh-134587: Fix os.mkdir(mode=0o700) under Windows AppContainer#148804

Open
thatnerdyguy wants to merge 4 commits intopython:mainfrom
thatnerdyguy:fix-issue-134587
Open

gh-134587: Fix os.mkdir(mode=0o700) under Windows AppContainer#148804
thatnerdyguy wants to merge 4 commits intopython:mainfrom
thatnerdyguy:fix-issue-134587

Conversation

@thatnerdyguy
Copy link
Copy Markdown

@thatnerdyguy thatnerdyguy commented Apr 20, 2026

In gh-118773, which was a follow up to gh-118488, an SDDL was used to grant a directory created via os.mkdir with mode=0o700 owner, admin, and system control. However, when running under a Windows AppContainer, objects must ALSO allow access for the AppContainer SID.

This changes the logic to do a one time resolution of the SDDL string to use. If we are running under an AppContainer, then the SDDL includes the SID of the AppContainer, otherwise we use the same standard SDDL as before.

In 8af84b5 (pythongh-118773), which was a follow up to 81939da (pythongh-118488), an SDDL was used to grant
a directory created via os.mkdir with mode=0o700 owner, admin, and system control. However,
when running under a Windows AppContainer, objects must ALSO allow access for the AppContainer
SID.

This changes the logic to do a one time resolution of the SDDL string to use. If we are running
under an AppContainer, then the SDDL includes the SID of the AppContainer, otherwise we use the
same standard SDDL as before.
@python-cla-bot
Copy link
Copy Markdown

python-cla-bot bot commented Apr 20, 2026

All commit authors signed the Contributor License Agreement.

CLA signed

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant