Closed
Description
SUMMARY
We create a temporary directory for the become_user with umask 077 in /var/tmp without first checking if the directory exists and that it has the expected permissions.
Relevant code
ansible/lib/ansible/plugins/shell/__init__.py
Lines 159 to 163 in 79dfae9
We need to validate the parent directories are as expected before creating directories in those paths and fail if the permissions and/or ACLs are not what we expect.
ISSUE TYPE
- Bug Report
COMPONENT NAME
lib/ansible/plugins/shell/__init__.py
ANSIBLE VERSION
2.10
CONFIGURATION
default
OS / ENVIRONMENT
STEPS TO REPRODUCE
EXPECTED RESULTS
ACTUAL RESULTS