Files
open-webui/backend/open_webui/routers
Classic298andbabakizo420 b40b6fd698 fix: reject backslash in the terminal proxy path sanitizer (#27198)
_sanitize_proxy_path decodes the path and then relies on posixpath.normpath plus a leading '..' check. posixpath splits on '/' only, so a backslash run is treated as part of a single path component: 'foo/..\..\etc' normalizes to itself, does not start with '..' and is forwarded unchanged, reaching the upstream as '/foo/..%5C..%5Cetc'. An upstream that treats the backslash as a separator would resolve those '..' sequences.

Reject any path containing a backslash after decoding, matching the existing fail-closed behaviour for paths that are still encoded past the decode cap. A backslash is not meaningful in the upstream API paths this route proxies, so legitimate requests are unaffected.

Co-authored-by: babakizo420 <babakizo420@users.noreply.github.com>
2026-07-27 01:01:10 -04:00
..
2026-06-29 01:38:41 -05:00
2026-07-26 19:34:41 -04:00
2026-06-29 13:03:14 -05:00
2026-07-27 00:12:47 -04:00
2026-07-24 02:36:10 -04:00
2026-07-20 22:11:42 -04:00
2026-07-26 23:49:03 -04:00
2026-07-26 19:10:41 -04:00
2026-06-29 05:47:21 -05:00
2026-07-23 21:29:33 -04:00
2026-06-29 13:03:14 -05:00
2026-07-27 00:12:47 -04:00
2026-07-20 22:11:42 -04:00
2026-07-16 01:27:52 -04:00
2026-07-23 21:29:33 -04:00
2026-06-29 13:03:14 -05:00
2026-06-25 03:31:45 +01:00
2026-07-17 04:11:11 -04:00
2026-07-16 21:57:43 -04:00
2026-07-09 17:28:34 -05:00
2026-07-24 01:44:30 -04:00
2026-06-17 02:52:35 +02:00