CVE-2021-42057 json
Obsidian Dataview vulnerable to code injection due to unsafe eval
published 5y ago modified 4mo ago also GHSA-xfg5-vrmc-24wc , EUVD-2022-5772
- cvss
- 7.8
- version 3.1, NVD
- cisa kev
- Not listed
- not in CISA's catalog
- epss
- 1.2%
- EPSS 1.2% chance of exploitation in 30 days, percentile 69%
- public exploits
- 0
- none known
Summary
Obsidian Dataview through 0.4.12-hotfix1 allows eval injection. The evalInContext function in executes user input, which allows an attacker to craft malicious Markdown files that will execute arbitrary code once opened. NOTE: 0.4.13 provides a mitigation for some use cases.
Patch / fix
- npm obsidian-dataview 0.4.13
Is CVE-2021-42057 in your dependencies? Fencer shows which of your repositories are affected as soon as an advisory lands, and opens the fix as a pull request.
Check with FencerExploit prediction
1.25% chance of exploitation in the next 30 days, higher than 69% of all scored CVEs (FIRST EPSS, 2026-11-09).
Exploits and checks
- github.com https://github.com/blacksmithgu/obsidian-dataview/issues/615 referenced PoC, tagged "exploit" by a source, unverified
CVSS scores
| assigned by | version | score | vector |
|---|---|---|---|
| NVD | 3.1 | 7.8 | CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H |
| NVD | 2.0 | 9.3 | AV:N/AC:M/Au:N/C:C/I:C/A:C |
| GitHub | 3.1 | 7.8 | CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H |
Affected packages
| ecosystem | package | affected | fixed in |
|---|---|---|---|
| npm | obsidian-dataview | <0.4.13 |
0.4.13 |
Classification
- Weakness
-
- CWE-94 Improper Control of Generation of Code
References
-
github.com
/blacksmithgu/obsidian-dataview/issues/615
web, exploit, issue-tracking, third-party-advisory
-
nvd.nist.gov
/vuln/detail/CVE-2021-42057
advisory
-
github.com
/blacksmithgu/obsidian-dataview
package
Sources
- CVE List CVE-2021-42057
- GitHub Advisory GHSA-xfg5-vrmc-24wc
- NVD CVE-2021-42057
Fencer Intel 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.