{"id":"CVE-2026-107716","published":"2026-10-08T21:33:13Z","modified":"2026-10-09T15:13:19Z","title":"Banks: Symlink traversal and arbitrary file disclosure/overwrite in DirectoryPromptRegistry","vendor":"masci","product":"banks","tier":"tail","description":{"text":"Banks generates meaningful LLM prompts using a simple template language. Prior to 2.5.1, Banks DirectoryPromptRegistry does not reject symbolic links for index.json or discovered and existing .jinja prompt files. In an application where untrusted users can influence a prompt directory, DirectoryPromptRegistry._scan() and DirectoryPromptRegistry.get() can follow a link outside the registry root and disclose a file, while DirectoryPromptRegistry.set(), DirectoryPromptRegistry._save(), and DirectoryPromptRegistry._load() can read or overwrite an external link target. The issue requires attacker influence over the registry directory or its extracted contents. This issue is fixed in version 2.5.1.","provenance":"source","from":"CVE.org"},"cvss":{"score":7.3,"severity":"HIGH","version":"4.0","vector":"CVSS:4.0/AV:L/AC:L/AT:P/PR:L/UI:N/VC:H/VI:H/VA:L/SC:N/SI:N/SA:N","provenance":"source","from":"CVE.org CNA"},"epss":{"score":0.00166,"percentile":0.03311,"provenance":"source"},"cwes":[{"id":"CWE-22","name":"Improper Limitation of a Pathname to a Restricted Directory"},{"id":"CWE-59","name":"Improper Link Resolution Before File Access"}],"references":[{"url":"https://github.com/masci/banks/security/advisories/GHSA-556j-vv39-8rqv","tags":["x_refsource_CONFIRM"]},{"url":"https://github.com/masci/banks/pull/79","tags":["x_refsource_MISC"]},{"url":"https://github.com/masci/banks/commit/23ed13e50b4e217693fa5f9c30943fac8a41582f","tags":["x_refsource_MISC"]},{"url":"https://github.com/masci/banks/releases/tag/v2.5.1","tags":["x_refsource_MISC"]}],"priority":{"score":5.8,"factors":[{"name":"EPSS percentile","points":0.66},{"name":"CVSS severity","points":5.11}]},"vendorSlug":"masci","affectedVersions":[{"vendor":"masci","product":"banks","versions":["< 2.5.1"]}],"ssvc":{"exploitation":"none","automatable":"no","technicalImpact":"partial","timestamp":"2026-10-09T14:54:57.852402Z","from":"CISA ADP","provenance":"source"},"affected":[{"ecosystem":"PyPI","package":"banks","vulnerableRanges":["<2.5.1"],"patched":["2.5.1"],"from":["GHSA-556j-vv39-8rqv","PYSEC-2026-4201"],"provenance":"source"}],"summary":{"text":"The Banks LLM prompt-templating library (masci/banks), prior to version 2.5.1, has a flaw in its DirectoryPromptRegistry component, which does not reject symbolic links for index.json or for discovered and existing .jinja prompt files. An attacker who can influence the prompt registry directory or its extracted contents, in an application where untrusted users can do so, can use symlinks to make the registry read or overwrite files outside the registry root, which requires local access and some level of privilege to modify the directory.","provenance":"ai","model":"claude-haiku-5-5","generatedAt":"2026-11-20T22:17:37Z"},"euvd":{"id":"EUVD-2026-95340","exploited":false,"provenance":"source"},"lineage":{"familyId":"fam-masci-banks-cve-2026-71492","parents":[{"from":"CVE-2026-71492","to":"CVE-2026-107716","relation":"related","confidence":"medium","kind":"lineage","evidence":[{"kind":"same-code","provenance":"machine","files":["src/banks/registries/directory.py"],"commits":["https://github.com/masci/banks/commit/23ed13e50b4e217693fa5f9c30943fac8a41582f","https://github.com/masci/banks/commit/a215f6d779966945c56e0af5abed1ae5916fd9d3"],"basis":"shared function","functions":["from_prompt_path"]}]}],"packageHistory":[{"cve":"CVE-2026-61536","published":"2026-07-30","fixed":"2.4.3","kev":false},{"cve":"CVE-2026-71492","published":"2026-08-20","fixed":"2.4.5","kev":false},{"cve":"CVE-2026-107717","published":"2026-10-08","fixed":"2.5.0","kev":false,"link":{"from":"CVE-2026-107717","to":"CVE-2026-107716","relation":"successor","confidence":"low","kind":"sequence","orderedBy":"description","evidence":[{"kind":"version-step","provenance":"source","package":"PyPI:banks","fromFixed":"2.5.0","toFixed":"2.5.1","daysApart":0}]}},{"cve":"CVE-2026-107716","published":"2026-10-08","fixed":"2.5.1","kev":false}],"package":"PyPI:banks"}}