Advisory

PYSEC-2026-918

Also known as: CVE-2022-35920, GHSA-8cw9-5hmv-77w6

Summary

sanic vulnerable to Path Traversal when using app.static if using encoded %2F URLs

Details

Impact
Access to lateral directories when using app.static if using encoded %2F URLs. Parent directory traversal is not impacted.

Patches

  • v20.12.7 (LTS)
  • v21.12.2 (LTS)
  • v22.6.1

References
https://github.com/sanic-org/sanic/issues/2478
https://github.com/sanic-org/sanic/pull/2495

For more information
If you have any questions or comments about this advisory:

Severity

High Basis: CVSS v3 score 8.3, vector CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:C/C:L/I:L/A:L

Dates

Published
2026-07-06 08:03 UTC
Modified
2026-07-07 11:45 UTC

Affected packages and fixes

sanic

PyPI · All systems

Affected

  • introduced 0, fixed 20.12.7, introduced 22.0.0, fixed 22.6.1, introduced 21.0.0, fixed 21.12.2 (ecosystem)

Fixed versions

20.12.7, 22.6.1, 21.12.2

Fix

  • Fixed version 20.12.7
    pip install --upgrade sanic==20.12.7
  • Fixed version 22.6.1
    pip install --upgrade sanic==22.6.1
  • Fixed version 21.12.2
    pip install --upgrade sanic==21.12.2

Fix commands are the export's own generic commands. Ojuju never runs them. Check them against your setup first.

Check your own computer: guard packages check

View this record on OSV.dev

Source

Source: PyPA Advisory Database · CC BY 4.0

Sources & licences