Masci
Monthly
Banks, a Python library for generating LLM prompts from a simple template language, ships a DirectoryPromptRegistry that prior to version 2.5.1 fails to reject symbolic links for its index.json file and for discovered or existing .jinja prompt files. An attacker who can influence the contents of the registry directory - for example by planting a symlink or by controlling files extracted from an untrusted archive into that directory - can cause _scan() and get() to follow a link outside the registry root and disclose arbitrary files, while set(), _save() and _load() can read or overwrite an external link target, giving high confidentiality and integrity impact with limited availability impact. Exploitation requires local placement influence over the prompt directory and applies only to deployments that use DirectoryPromptRegistry and expose that directory to untrusted input, which is why the vendor CVSS 4.0 base score is 7.3 (AV:L/AC:L/AT:P/PR:L/UI:N) and the assessed CVSS 3.1 vector is AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:L; no public exploit code and no confirmed active exploitation (CISA KEV) were identified at time of analysis. The issue is fixed in version 2.5.1.
Arbitrary code execution in the Banks Python LLM-templating library (versions prior to 2.4.3) allows an attacker who can influence Tool JSON definitions within a {% completion %} block to run any importable Python callable in the host process. Banks resolves the attacker-controlled import_path field via importlib.import_module() plus getattr() with no allowlist, so values like os.system or subprocess.getoutput become invokable when the LLM emits a matching tool_calls entry, passing decoded arguments as kwargs. No public exploit identified at time of analysis; this bug is explicitly distinct from and unfixed by the 2.4.2 SandboxedEnvironment patch (GHSA-gphh-9q3h-jgpp / CVE-2026-44209) because the malicious payload is plain text in the rendered body and never touches Jinja attribute access.
Arbitrary file disclosure in the Banks Python prompt-templating library (masci/banks) before 2.4.4 lets attackers who control template variables read any file the Python process can access. All four media filters (image, audio, video, document) wrap untrusted input in Path(value) and feed it straight to open(file_path, "rb") with no sanitization, so path traversal (../) reads files like .env, SSH keys, cloud credentials, source, /etc/passwd and /etc/shadow, returning them base64-encoded in the rendered prompt for trivial exfiltration. No public exploit identified at time of analysis and it is not in CISA KEV, but the fix in 2.4.4 is straightforward to reverse-engineer.
Prompt-structure injection in the Banks LLM prompt-templating library (masci/banks) before 2.5.0 allows attacker-controlled template data to cross the prompt boundary and be reinterpreted as system, assistant, or tool chat messages. Because Prompt.chat_messages() parses every rendered line of template output as ChatMessage JSON and ChatMessage.role accepts arbitrary strings, an unauthenticated remote attacker who can induce a consuming application to render untrusted data through a Banks template and forward the resulting messages to an LLM provider can override system instructions, alter the intended prompt structure, or confuse downstream tool and message handling. This is a genuine but conditional, medium-severity input-validation flaw (CVSS 6.5, CWE-20): it does not affect a default Banks install in isolation, and no public exploit code was identified at time of analysis. Vendor-released patch: 2.5.0.
Path traversal in the Banks Python prompt-template library (all versions prior to 2.4.5) allows a low-privileged attacker to write arbitrary bytes to attacker-chosen filesystem paths accessible to the application process. DirectoryPromptRegistry.set() in directory.py constructs on-disk paths by directly interpolating unvalidated Prompt.name and Prompt.version values - enabling relative sequences like ../victim/foo or absolute paths to escape the configured registry root. The poisoned path persists in index.json and is reconstructed on subsequent registry loads, meaning exploitation survives application restarts. No public exploit or CISA KEV listing exists at time of analysis; a vendor-released patch is available as version 2.4.5.
Banks, a Python library for generating LLM prompts from a simple template language, ships a DirectoryPromptRegistry that prior to version 2.5.1 fails to reject symbolic links for its index.json file and for discovered or existing .jinja prompt files. An attacker who can influence the contents of the registry directory - for example by planting a symlink or by controlling files extracted from an untrusted archive into that directory - can cause _scan() and get() to follow a link outside the registry root and disclose arbitrary files, while set(), _save() and _load() can read or overwrite an external link target, giving high confidentiality and integrity impact with limited availability impact. Exploitation requires local placement influence over the prompt directory and applies only to deployments that use DirectoryPromptRegistry and expose that directory to untrusted input, which is why the vendor CVSS 4.0 base score is 7.3 (AV:L/AC:L/AT:P/PR:L/UI:N) and the assessed CVSS 3.1 vector is AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:L; no public exploit code and no confirmed active exploitation (CISA KEV) were identified at time of analysis. The issue is fixed in version 2.5.1.
Arbitrary code execution in the Banks Python LLM-templating library (versions prior to 2.4.3) allows an attacker who can influence Tool JSON definitions within a {% completion %} block to run any importable Python callable in the host process. Banks resolves the attacker-controlled import_path field via importlib.import_module() plus getattr() with no allowlist, so values like os.system or subprocess.getoutput become invokable when the LLM emits a matching tool_calls entry, passing decoded arguments as kwargs. No public exploit identified at time of analysis; this bug is explicitly distinct from and unfixed by the 2.4.2 SandboxedEnvironment patch (GHSA-gphh-9q3h-jgpp / CVE-2026-44209) because the malicious payload is plain text in the rendered body and never touches Jinja attribute access.
Arbitrary file disclosure in the Banks Python prompt-templating library (masci/banks) before 2.4.4 lets attackers who control template variables read any file the Python process can access. All four media filters (image, audio, video, document) wrap untrusted input in Path(value) and feed it straight to open(file_path, "rb") with no sanitization, so path traversal (../) reads files like .env, SSH keys, cloud credentials, source, /etc/passwd and /etc/shadow, returning them base64-encoded in the rendered prompt for trivial exfiltration. No public exploit identified at time of analysis and it is not in CISA KEV, but the fix in 2.4.4 is straightforward to reverse-engineer.
Prompt-structure injection in the Banks LLM prompt-templating library (masci/banks) before 2.5.0 allows attacker-controlled template data to cross the prompt boundary and be reinterpreted as system, assistant, or tool chat messages. Because Prompt.chat_messages() parses every rendered line of template output as ChatMessage JSON and ChatMessage.role accepts arbitrary strings, an unauthenticated remote attacker who can induce a consuming application to render untrusted data through a Banks template and forward the resulting messages to an LLM provider can override system instructions, alter the intended prompt structure, or confuse downstream tool and message handling. This is a genuine but conditional, medium-severity input-validation flaw (CVSS 6.5, CWE-20): it does not affect a default Banks install in isolation, and no public exploit code was identified at time of analysis. Vendor-released patch: 2.5.0.
Path traversal in the Banks Python prompt-template library (all versions prior to 2.4.5) allows a low-privileged attacker to write arbitrary bytes to attacker-chosen filesystem paths accessible to the application process. DirectoryPromptRegistry.set() in directory.py constructs on-disk paths by directly interpolating unvalidated Prompt.name and Prompt.version values - enabling relative sequences like ../victim/foo or absolute paths to escape the configured registry root. The poisoned path persists in index.json and is reconstructed on subsequent registry loads, meaning exploitation survives application restarts. No public exploit or CISA KEV listing exists at time of analysis; a vendor-released patch is available as version 2.4.5.