ID CVE-2014-2667
Summary Race condition in the _get_masked_mode function in Lib/os.py in Python 3.2 through 3.5, when exist_ok is set to true and multiple threads are used, might allow local users to bypass intended file permissions by leveraging a separate application vulnerability before the umask has been set to the expected value.
References
Vulnerable Configurations
  • cpe:2.3:a:python:python:3.2.0:*:*:*:*:*:*:*
    cpe:2.3:a:python:python:3.2.0:*:*:*:*:*:*:*
  • cpe:2.3:a:python:python:3.2.1:*:*:*:*:*:*:*
    cpe:2.3:a:python:python:3.2.1:*:*:*:*:*:*:*
  • cpe:2.3:a:python:python:3.2.2:*:*:*:*:*:*:*
    cpe:2.3:a:python:python:3.2.2:*:*:*:*:*:*:*
  • cpe:2.3:a:python:python:3.2.3:*:*:*:*:*:*:*
    cpe:2.3:a:python:python:3.2.3:*:*:*:*:*:*:*
  • cpe:2.3:a:python:python:3.2.4:*:*:*:*:*:*:*
    cpe:2.3:a:python:python:3.2.4:*:*:*:*:*:*:*
  • cpe:2.3:a:python:python:3.2.5:*:*:*:*:*:*:*
    cpe:2.3:a:python:python:3.2.5:*:*:*:*:*:*:*
  • cpe:2.3:a:python:python:3.2.6:*:*:*:*:*:*:*
    cpe:2.3:a:python:python:3.2.6:*:*:*:*:*:*:*
  • cpe:2.3:a:python:python:3.3.0:*:*:*:*:*:*:*
    cpe:2.3:a:python:python:3.3.0:*:*:*:*:*:*:*
  • cpe:2.3:a:python:python:3.3.1:*:*:*:*:*:*:*
    cpe:2.3:a:python:python:3.3.1:*:*:*:*:*:*:*
  • cpe:2.3:a:python:python:3.3.2:*:*:*:*:*:*:*
    cpe:2.3:a:python:python:3.3.2:*:*:*:*:*:*:*
  • cpe:2.3:a:python:python:3.3.3:*:*:*:*:*:*:*
    cpe:2.3:a:python:python:3.3.3:*:*:*:*:*:*:*
  • cpe:2.3:a:python:python:3.3.4:*:*:*:*:*:*:*
    cpe:2.3:a:python:python:3.3.4:*:*:*:*:*:*:*
  • cpe:2.3:a:python:python:3.3.5:*:*:*:*:*:*:*
    cpe:2.3:a:python:python:3.3.5:*:*:*:*:*:*:*
  • cpe:2.3:a:python:python:3.3.6:*:*:*:*:*:*:*
    cpe:2.3:a:python:python:3.3.6:*:*:*:*:*:*:*
  • cpe:2.3:a:python:python:3.4.0:*:*:*:*:*:*:*
    cpe:2.3:a:python:python:3.4.0:*:*:*:*:*:*:*
  • cpe:2.3:a:python:python:3.4.1:*:*:*:*:*:*:*
    cpe:2.3:a:python:python:3.4.1:*:*:*:*:*:*:*
  • cpe:2.3:a:python:python:3.4.2:*:*:*:*:*:*:*
    cpe:2.3:a:python:python:3.4.2:*:*:*:*:*:*:*
CVSS
Base: 3.3 (as of 01-07-2017 - 01:29)
Impact:
Exploitability:
CWE CWE-362
CAPEC
  • Leveraging Race Conditions
    The adversary targets a race condition occurring when multiple processes access and manipulate the same resource concurrently, and the outcome of the execution depends on the particular order in which the access takes place. The adversary can leverage a race condition by "running the race", modifying the resource and modifying the normal execution flow. For instance, a race condition can occur while accessing a file: the adversary can trick the system by replacing the original file with his version and cause the system to read the malicious file.
  • Leveraging Time-of-Check and Time-of-Use (TOCTOU) Race Conditions
    This attack targets a race condition occurring between the time of check (state) for a resource and the time of use of a resource. A typical example is file access. The adversary can leverage a file access race condition by "running the race", meaning that they would modify the resource between the first time the target program accesses the file and the time the target program uses the file. During that period of time, the adversary could replace or modify the file, causing the application to behave unexpectedly.
Access
VectorComplexityAuthentication
LOCAL MEDIUM NONE
Impact
ConfidentialityIntegrityAvailability
PARTIAL PARTIAL NONE
cvss-vector via4 AV:L/AC:M/Au:N/C:P/I:P/A:N
refmap via4
confirm http://bugs.python.org/issue21082
gentoo GLSA-201503-10
mlist
  • [oss-security] 20140328 CVE request: os.makedirs(exist_ok=True) is not thread-safe in Python
  • [oss-security] 20140329 Re: [PSRT] CVE request: os.makedirs(exist_ok=True) is not thread-safe in Python
  • [oss-security] 20140330 Re: CVE request: os.makedirs(exist_ok=True) is not thread-safe in Python
suse
  • openSUSE-SU-2014:0596
  • openSUSE-SU-2014:0597
  • openSUSE-SU-2020:0086
Last major update 01-07-2017 - 01:29
Published 16-11-2014 - 01:59
Last modified 01-07-2017 - 01:29
Back to Top