CVE-2023-6395 json
Mock: privilege escalation for users that can access mock configuration
published 2024-01-16 2 y ago modified 2026-07-07 4 mo ago also GHSA-7j98-74jh-cjxh , PYSEC-2026-1949 , EUVD-2024-0284
- cvss
- 6.7
- version 3.1, CNA
- cisa kev
- Not listed
- not in CISA's catalog
- epss
- 1.6%
- EPSS 1.6% chance of exploitation in 30 days, percentile 75%
- public exploits
- 0
- none known
Summary
The Mock software contains a vulnerability wherein an attacker could potentially exploit privilege escalation, enabling the execution of arbitrary code with root user privileges. This weakness stems from the absence of proper sandboxing during the expansion and execution of Jinja2 templates, which may be included in certain configuration parameters. While the Mock documentation advises treating users added to the mock group as privileged, certain build systems invoking mock on behalf of users might inadvertently permit less privileged users to define configuration tags. These tags could then be passed as parameters to mock during execution, potentially leading to the utilization of Jinja2 templates for remote privilege escalation and the execution of arbitrary code as the root user on the build server.
Patch / fix
- pypi templated-dictionary 1.4.1
Vendor advisories
What the vendors themselves say about their products: affected, fixed or not affected, and what to do.
red hat product security vex CVE-2023-6395 updated cvss 6.7
Mock: Privilege escalation for users that can access mock configuration
-
Red Hat Enterprise Linux 6 mocknot affected: vulnerable code not present
Red Hat CSAF VEX © Red Hat, Inc., from https://security.access.redhat.com/data/csaf/v2/vex/; changed: reduced to product statuses and remediations. CC BY 4.0 · csaf
CISA SSVC
- Exploitation
- none
- Automatable
- yes
- Technical impact
- total
- Assessed
- 2 y ago
Exploit prediction
1.55% chance of exploitation in the next 30 days, higher than 75% of all scored CVEs (FIRST EPSS, 2026-11-08).
Exploits and checks
- openwall.com http://www.openwall.com/lists/oss-security/2024/01/16/3 referenced PoC, tagged "exploit" by a source, unverified
CVSS scores
| assigned by | version | score | vector |
|---|---|---|---|
| CNA | 3.1 | 6.7 | CVSS:3.1/AV:L/AC:L/PR:H/UI:N/S:U/C:H/I:H/A:H |
| NVD | 3.1 | 9.8 | CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H |
| OSV | 3.1 | 6.7 | CVSS:3.1/AV:L/AC:L/PR:H/UI:N/S:U/C:H/I:H/A:H |
| GitHub | 3.1 | 6.7 | CVSS:3.1/AV:L/AC:L/PR:H/UI:N/S:U/C:H/I:H/A:H |
Affected packages
| ecosystem | package | affected | fixed in |
|---|---|---|---|
| pypi | templated-dictionary | <1.4.1 |
1.4.1 |
Affected products
- n/a mock
- Red Hat Red Hat Enterprise Linux 6
- Fedora Extra Packages for Enterprise Linux
- Fedora Fedora
Classification
References
-
github.com
/xsuchy/templated-dictionary/commit/0740bd0ca8d487301881541028977d120f8b8933
web, patch
-
github.com
/xsuchy/templated-dictionary/commit/bcd90f0dafa365575c4b101e6f5d98c4ef4e4b69
web, patch
-
openwall.com
/lists/oss-security/2024/01/16/1
web, mailing-list, patch, third-party-advisory
-
openwall.com
/lists/oss-security/2024/01/16/3
web, exploit, mailing-list, third-party-advisory
-
access.redhat.com
/security/cve/CVE-2023-6395
vdb-entry, web, third-party-advisory
-
bugzilla.redhat.com
/show_bug.cgi?id=2252206
issue-tracking, web, third-party-advisory
- lists.fedoraproject.org /archives/list/package-announce@lists.fedoraproject.org/message/NBFYREAJH4T7GXXQZ4GJEREN4Q3AHS3K/
- lists.fedoraproject.org /archives/list/package-announce@lists.fedoraproject.org/message/62SP2BJC2AFLFJJAEHPGZ3ZINTBTI7AN/
-
nvd.nist.gov
/vuln/detail/CVE-2023-6395
advisory
-
github.com
/xsuchy/templated-dictionary
package
-
lists.fedoraproject.org
/archives/list/package-announce@lists.fedoraproject.org/message/62SP2BJC2AFLFJJAEHPGZ3ZINTBTI7AN
web
-
lists.fedoraproject.org
/archives/list/package-announce@lists.fedoraproject.org/message/NBFYREAJH4T7GXXQZ4GJEREN4Q3AHS3K
web
-
pypi.org
/project/templated-dictionary
package
-
github.com
/advisories/GHSA-7j98-74jh-cjxh
advisory
Sources
- CVE List CVE-2023-6395
- GitHub Advisory GHSA-7j98-74jh-cjxh
- NVD CVE-2023-6395
- OSV PYSEC-2026-1949
Fencer Vulns keeps one entry per vulnerability: the CVE id wins, then GHSA, and records that alias each other are merged, except that two CVEs always keep separate entries. The same data is available as JSON.