# CVE-2022-25760: Arbitrary Code Injection

- Severity: High 7.1 (CVSS:3.1, scored by snyk) `CVSS:3.1/AV:N/AC:H/PR:L/UI:N/S:U/C:H/I:H/A:L/E:P`
- Known to be exploited: not in CISA's catalogue, which lists only what CISA has confirmed
- Likelihood of exploitation in the next 30 days (EPSS): 1.64%, higher than 77% of CVEs (2026-12-01)
- Public exploit code or proof of concept: one link below, marked "exploit"
- Published: 2022-03-17T11:20:27.369Z
- Modified: 2026-06-17T04:34:13.893Z
- Also known as: GHSA-8m2f-74r2-x3f2
- Weaknesses: CWE-94
- Assigned by: snyk

## Description

All versions of package accesslog are vulnerable to Arbitrary Code Injection due to the usage of the Function constructor without input sanitization. If (attacker-controlled) user input is given to the format option of the package's exported constructor function, it is possible for an attacker to execute arbitrary JavaScript code on the host that this package is being run on.

(As written by CVE List.)

## Affected

- accesslog: before unspecified
- accesslog (npm): up to 0.0.2
- accesslog_project accesslog: no versions given

## Every score

- snyk: CVSS:3.1 7.1 High `CVSS:3.1/AV:N/AC:H/PR:L/UI:N/S:U/C:H/I:H/A:L/E:P`
- GitHub: CVSS:3.1 7.1 High `CVSS:3.1/AV:N/AC:H/PR:L/UI:N/S:U/C:H/I:H/A:L`
- NVD: CVSS:3.1 9.8 Critical `CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H`
- NVD: CVSS:2.0 10.0 High `AV:N/AC:L/Au:N/C:C/I:C/A:C`

## References

- <https://snyk.io/vuln/SNYK-JS-ACCESSLOG-2312099> (exploit, third-party-advisory, web)
- <https://github.com/carlos8f/node-accesslog/blob/master/lib/compile.js%23L6> (broken-link, web)
- <https://nvd.nist.gov/vuln/detail/CVE-2022-25760> (advisory)
- <https://github.com/carlos8f/node-accesslog> (package)

## Sources

- CVE List: [CVE-2022-25760](https://www.cve.org/CVERecord?id=CVE-2022-25760), CVE Terms of Use, modified 2024-09-16
- GitHub Advisory Database: [GHSA-8m2f-74r2-x3f2](https://github.com/advisories/GHSA-8m2f-74r2-x3f2), CC-BY-4.0, modified 2026-03-13
- NVD: [CVE-2022-25760](https://nvd.nist.gov/vuln/detail/CVE-2022-25760), Public domain, modified 2026-06-17

---

Page: https://cve.day/CVE-2022-25760 · Whole record: https://cve.day/CVE-2022-25760.json · Rebuilt by cve.day 2026-11-25T22:58:10.151Z
