# CVE-2026-37737: sanic-cors contains an improper regular expression in the try_match() function

- Severity: Medium 6.5 (CVSS:3.1, scored by CISA-ADP) `CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:H/I:N/A:N`
- 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.16%, higher than 5% of CVEs (2026-12-01)
- Published: 2026-06-05T00:00:00.000Z
- Modified: 2026-07-23T15:11:37.862Z
- Also known as: GHSA-94jw-hqvj-vw74, PYSEC-2026-3539
- Weaknesses: CWE-346, CWE-625
- SSVC (CISA-ADP): exploitation none, automatable no, technical impact partial
- Assigned by: mitre

## Description

sanic-cors version 2.2.0 and prior contains an improper regular expression in the try_match() function in sanic_cors/core.py that uses re.match without end-anchoring. This allows an attacker to bypass CORS origin allowlists by registering a domain that begins with a trusted origin string, to gain unauthorized access to cross-origin requests for authenticated resources.

(As written by CVE List.)

## Affected

- Unspecified product: n/a
- sanic-cors (PyPI): up to 2.2.0

## Every score

- CISA-ADP: CVSS:3.1 6.5 Medium `CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:H/I:N/A:N`
- GitHub: CVSS:3.1 6.5 Medium `CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:H/I:N/A:N`
- PyPA Advisory Database: CVSS:3.1 6.5 Medium `CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:H/I:N/A:N`

## References

- <https://github.com/ashleysommer/sanic-cors/blob/master/sanic_cors/core.py> (web)
- <https://github.com/ashleysommer/sanic-cors> (package)
- <https://pypi.org/project/Sanic-Cors/>
- <https://github.com/npbhatter17/security-advisories/blob/main/CVE-2026-37737-sanic-cors-advisory.md> (web)
- <https://nvd.nist.gov/vuln/detail/CVE-2026-37737> (advisory)
- <https://pypi.org/project/Sanic-Cors> (web)
- <https://pypi.org/project/sanic-cors> (package)
- <https://github.com/advisories/GHSA-94jw-hqvj-vw74> (advisory)

## Sources

- CVE List: [CVE-2026-37737](https://www.cve.org/CVERecord?id=CVE-2026-37737), CVE Terms of Use, modified 2026-06-05
- GitHub Advisory Database: [GHSA-94jw-hqvj-vw74](https://github.com/advisories/GHSA-94jw-hqvj-vw74), CC-BY-4.0, modified 2026-07-23
- NVD: [CVE-2026-37737](https://nvd.nist.gov/vuln/detail/CVE-2026-37737), Public domain, modified 2026-06-17
- PyPA Advisory Database: [PYSEC-2026-3539](https://osv.dev/vulnerability/PYSEC-2026-3539), CC-BY-4.0, modified 2026-07-23

---

Page: https://cve.day/CVE-2026-37737 · Whole record: https://cve.day/CVE-2026-37737.json · Rebuilt by cve.day 2026-11-25T22:59:23.884Z
