# CVE-2021-4070: Off-by-one Error in v2fly/v2ray-core

- Severity: Medium 5.9 (CVSS:3.0, scored by @huntrdev) `CVSS:3.0/AV:L/AC:L/PR:N/UI:N/S:U/C:L/I:L/A:L`
- 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): 0.86%, higher than 59% of CVEs (2026-12-01)
- Public exploit code or proof of concept: one link below, marked "exploit"
- Published: 2022-02-23T19:50:10.000Z
- Modified: 2026-06-17T04:18:59.397Z
- Also known as: GHSA-4cxw-hq44-r344, GO-2022-0550
- Weaknesses: CWE-193
- Assigned by: @huntrdev

## Description

Off-by-one Error in GitHub repository v2fly/v2ray-core prior to 4.44.0.

(As written by CVE List.)

## Affected

- v2fly v2fly/v2ray-core: from unspecified before 4.44.0
- github.com/v2fly/v2ray-core/v4 (Go): before 4.44.0
- github.com/v2fly/v2ray-core (Go): all versions
- v2fly v2ray-core: before 4.44.0

## Every score

- @huntrdev: CVSS:3.0 5.9 Medium `CVSS:3.0/AV:L/AC:L/PR:N/UI:N/S:U/C:L/I:L/A:L`
- GitHub: CVSS:3.1 9.1 Critical `CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:H`
- NVD: CVSS:3.1 9.1 Critical `CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:H`
- NVD: CVSS:2.0 6.4 Medium `AV:N/AC:L/Au:N/C:P/I:N/A:P`

## References

- <https://huntr.dev/bounties/8da19456-4d89-41ef-9781-a41efd6a1877> (exploit, patch, third-party-advisory, web)
- <https://github.com/v2fly/v2ray-core/commit/c1af2bfd7aa59a4482aa7f6ec4b9208c1d350b5c> (fix, patch, third-party-advisory, web)
- <https://nvd.nist.gov/vuln/detail/CVE-2021-4070> (advisory)
- <https://github.com/v2fly/v2ray-core> (package)
- <https://github.com/advisories/GHSA-4cxw-hq44-r344> (advisory)

## Sources

- CVE List: [CVE-2021-4070](https://www.cve.org/CVERecord?id=CVE-2021-4070), CVE Terms of Use, modified 2024-08-03
- GitHub Advisory Database: [GHSA-4cxw-hq44-r344](https://github.com/advisories/GHSA-4cxw-hq44-r344), CC-BY-4.0, modified 2024-08-21
- Go Vulnerability Database: [GO-2022-0550](https://pkg.go.dev/vuln/GO-2022-0550), CC-BY-4.0, modified 2026-03-03
- NVD: [CVE-2021-4070](https://nvd.nist.gov/vuln/detail/CVE-2021-4070), Public domain, modified 2026-06-17

---

Page: https://cve.day/CVE-2021-4070 · Whole record: https://cve.day/CVE-2021-4070.json · Rebuilt by cve.day 2026-11-25T22:58:07.055Z
