Skip to main content

Banks CVE-2026-62663

| EUVDEUVD-2026-51231 HIGH
Path Traversal (CWE-22)
2026-07-30 GitHub_M
7.5
CVSS 3.1 · Vendor: GitHub_M
View

Attack ChainAIDerived

Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain

  1. Access
    Control Banks template variable
  2. Delivery
    Inject ../ traversal path into media filter
  3. Exploit
    Banks opens target file rb
  4. Execution
    Sensitive file base64-encoded into prompt
  5. Impact
    Read secrets from rendered output

Vulnerability Assessment

Weakness
CWE
OWASP Top 10:2025
A01:2025 - Broken Access Control
ASVS 5.0
V5 - File Handling Path canonicalization, traversal prevention
MITRE ATT&CK

2 techniques across 2 tactics: Discovery, Collection

The technique list with ATT&CK links and the kill-chain view is part of the Basic plan and up.

Exploitation Conditions

Exploitation requires that the embedding application passes attacker-influenced data into a Banks Prompt template variable that is consumed by one of the four media filters (image, audio, video, or document), and that the rendered prompt output (or the resulting LLM response) is observable to the attacker so the base64-encoded file contents can be retrieved. The exact feature is the media-filter file-read path that calls open(Path(value), "rb"). Limiting factors: the flaw is not exploitable if template variables are entirely operator/developer-controlled rather than user-supplied, if no media filter is used on untrusted input, or if the app runs before version 2.4.4 but never surfaces the rendered output; disclosure is also bounded by the file permissions of the Python process (only files it can read are exposed).

Impact

The CVSS 3.1 vector CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:N scores 7.5 and models pure confidentiality loss via network-reachable, unauthenticated, low-complexity access - consistent with arbitrary file read. The important caveat is that exploitability is application-dependent: 'AV:N/PR:N' only holds when the embedding application forwards untrusted, remotely-supplied data into Banks template variables and then exposes the rendered output; in deployments where template variables are operator-controlled, real-world reach is lower. No EPSS score, SSVC decision, or POC flag was provided in the input, and the vulnerability is not listed in CISA KEV, so exploitation status is 'no public exploit identified at time of analysis' rather than active exploitation. Impact is limited to disclosure (I:N/A:N), but that disclosure includes secrets (.env, SSH keys, cloud credentials) that enable follow-on compromise, so treat as a genuine priority anywhere user input flows into Banks prompts, and as lower urgency where inputs are trusted.

Exploit ScenarioDerived

An application uses Banks to render prompts and passes a user-supplied field (e.g., a filename or attachment path) into a template that applies the document filter. The attacker sets that variable to '../../../../etc/shadow' or '../../.env'; Banks opens the file and embeds its base64-encoded contents in the rendered prompt, which the attacker then reads back from the LLM interaction or response. No exploit code was provided in the input, but the traversal technique is trivial given AV:N/AC:L.

This Week Schedule remediation this week. Why: HIGH severity (CVSS 7.0-8.9).
Patch available 0.3% exploitation probability (EPSS)

Get an e-mail when this CVE is exploited, patched or re-scored. Free account.

Alert me

AnalysisAIv1 – Jul 30, 2026

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.

RemediationAI

Vendor-released patch: upgrade Banks to version 2.4.4, which fixes all four media filters (pin banks>=2.4.4 in requirements/pyproject and rebuild). Until you can upgrade, do not pass user-controlled or otherwise untrusted data into Banks template variables that reach the image, audio, video, or document filters; if media embedding is not required, avoid those filters entirely. As compensating controls, validate and canonicalize any path-like variable before rendering and reject values containing '../', absolute paths, or symlinks, and/or confine the filters to a dedicated media directory via an allowlist - the trade-off is added validation code and possible breakage of legitimate nested media paths. Running the Python process under a least-privilege account limits which files traversal can reach (side effect: none functional, but it does not stop the read itself). See the advisory GHSA-98rr-gvc9-3cjh (https://github.com/masci/banks/security/advisories/GHSA-98rr-gvc9-3cjh) for details.

Affected VersionsENISA

banks < 2.4.4

Affected Packages

euvd banks fix: 2.4.4

Source: OSV (Open Source Vulnerabilities)

Affects your stack

Affects 1 package in euvd

Checking this CVE against your own stacks and servers is part of the Basic plan and up.

Technical ContextAI · show details

Banks is a Python library that builds LLM prompts from a simple Jinja-style template language, where filters such as {{ var | image }} embed media by reading it from disk. The CPE cpe:2.3:a:masci:banks:*:*:*:*:*:*:*:* confirms the affected component is the masci 'banks' application/library across all versions prior to the fix. The root cause is CWE-22 (Improper Limitation of a Pathname to a Restricted Directory): the media filters construct a filesystem path directly from template variable content - Path(value) - and open it in binary mode without canonicalization (no realpath resolution), no allowlist/base-directory confinement, and no rejection of traversal sequences, so relative segments like ../ resolve against the process working directory and escape any intended media folder.

Know when Banks gets its next vulnerability

  • Watch products and get an email when something new is published
  • Check this CVE against your own stack and servers
  • Exploit and PoC references, threat intelligence from 22 sources

No credit card · 7-day full trial

Severity by source

Vendor (GitHub_M) PRIMARY 7.5 HIGH
AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:N
vuln.today AI 7.5 HIGH

Untrusted template input is network-reachable and unauthenticated in the intended threat model, low complexity; pure arbitrary-file-read gives C:H with no integrity or availability impact.

3.1 AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:N
4.0 AV:N/AC:L/AT:N/PR:N/UI:N/VC:H/VI:N/VA:N/SC:N/SI:N/SA:N
Red Hat 7.5 HIGH

Primary rating from Vendor (GitHub_M).

CVSS VectorVendor: GitHub_M

Attack Vector
Network
Attack Complexity
Low
Privileges Required
None
User Interaction
None
Scope
Unchanged
Confidentiality
High
Integrity
None
Availability
None

Lifecycle Timeline

2
Patch available
Jul 30, 2026 - 18:03 EUVD
CVE Published
Jul 30, 2026 - 16:16 cve.org
HIGH 7.5

DescriptionCVE.org

Banks generates meaningful LLM prompts using a simple template language. In versions prior to 2.4.4, all four media filters (image, audio, video, document) in banks accept untrusted user input as file paths via Path(value) and pass them directly to open(file_path, "rb") without any path sanitization, canonicalization, or directory restriction. An attacker who controls template variables passed to a banks Prompt can use path traversal (../) to read arbitrary files accessible to the Python process-including .env files, SSH keys, cloud credentials, source code, /etc/passwd, and /etc/shadow-with the content returned base64-encoded in the rendered prompt output, making exfiltration trivial. This is particularly dangerous for applications that use banks to process user-provided template variables before sending prompts to an LLM. This issue has been fixed in version 2.4.4.

Executive ViewAI

Why It Matters

Masci/banks Python templating library versions before 2.4.4 contain a critical file disclosure vulnerability allowing attackers who control template variables to read sensitive files including AWS credentials, SSH keys, and source code via path traversal. Organizations using this library risk credential theft and unauthorized infrastructure access if template inputs are not properly restricted.

Business Impact: High
Compensating Controls

No vendor-released patch identified at time of analysis. Implement strict input validation to reject path traversal sequences in template variables; run with minimal file system permissions; disable media filters if unused; store credentials outside the Python process working directory; monitor for suspicious template variable patterns; consider running the templating service in a restricted container or sandbox.

Threat Intelligence Overview

EPSS Score
0.3%
Top 74% exploitable
Prevalence
Low
niche open-source Python LLM prompt-templating library, limited production footprint
Social Media
1
Sightings
Data Quality
7 sources
Confidence: High
EUVD NVD CVE.org EPSS Vulnrichment Vendor CIRCL GitHub

How this decision was reached

The engine reads each signal below and applies a fixed list of rules from top to bottom. The first rule that matches sets the recommended action – like a statement, every line is shown.

SignalValue
Severity HIGH
CISA KEV No
Public POC No
EPSS 0.3%
Patch available Yes
Active threat No
Deciding rule
HIGH severity (CVSS 7.0-8.9)
What every action level means
Emergency Immediate action required. Criteria: CRITICAL + in CISA KEV (actively exploited) without patch, OR CRITICAL + EPSS > 30% without patch, OR CRITICAL + active threat signals without patch.
Act Now Prioritize within 24-48h. Criteria: in KEV with patch available, OR CRITICAL + public POC, OR HIGH + EPSS > 10%, OR CRITICAL + active threat, OR any CRITICAL severity.
This Week Schedule remediation this week. Criteria: HIGH severity (CVSS 7.0-8.9). Patch within normal change window.
This Month Plan within 30 days. Criteria: MEDIUM severity (CVSS 4.0-6.9), lower exploitation probability. Include in regular patch cycle.
Monitor Track and reassess. Criteria: LOW severity (CVSS 0.1-3.9), minimal exploitation risk. No immediate action needed.

SSVC AssessmentENISA

SSVC Decision
Out-of-Cycle
Exploitation
Poc
System Exposure· derived
Open
Automatable
Yes
Human Impact
High
Technical Impact
Partial

Priority Score

38
Low Medium High Critical
KEV: 0
EPSS: 0
CVSS: +38
PoC: 0
Weaponized: 0
Threat intel: 0
Gov advisory: 0

Attack Technique

Path traversal exploits occur when applications use user-controlled input to construct file system paths without proper validation.

Vendor StatusVendor

This site uses cookies essential for authentication and security. No tracking or analytics cookies are used. Privacy Policy