Jun 22, 2026·6 min read·34 visits
A multi-tenant isolation bypass in stigmem-node allows authenticated users of one tenant to read, modify, and delete data belonging to all other tenants due to a lack of SQL tenant_id filters in the decay, quarantine, and tombstone systems.
A critical vulnerability exists in the stigmem-node package when running the opt-in stigmem-plugin-multi-tenant plugin. Due to a failure to enforce tenant-scoping filters on database queries within the decay sweep, quarantine moderation, and right-to-be-forgotten (RTBF) subsystems, an authorized caller belonging to one tenant can access, modify, and delete facts belonging to all other tenants. This broken object level authorization (BOLA) vulnerability allows cross-tenant data manipulation and information leakage.
The application stigmem-node supports multi-tenant deployments via the stigmem-plugin-multi-tenant plugin. This plugin implements logical data separation by assigning a tenant_id to each record in a shared relational database. Multi-tenant isolation models rely on database queries systematically filtering records according to the authenticated caller's tenant identifier.
Three subsystems within the core codebase fail to apply the required tenant_id restrictions: decay sweeps (lifecycle/decay.py), quarantine moderation (routes/quarantine.py), and Right-to-Be-Forgotten (RTBF) tombstones (lifecycle/tombstones.py). This structural omission exposes an attack surface where any caller with write access to a single tenant can read, modify, or erase data across all other tenant partitions.
The vulnerability is classified under CWE-863 (Incorrect Authorization) and CWE-284 (Improper Access Control). The security impact represents a complete compromise of tenant integrity and availability, as a low-privileged tenant user can trigger global data expiration and control moderation flows belonging to other organizations on the same node.
The root cause of this vulnerability lies in the shared-schema multi-tenancy implementation used by stigmem-node. All tenant data resides within the same SQLite tables, utilizing a tenant_id column to distinguish between records owned by different tenants. To maintain strict isolation boundaries, every data manipulation and selection query must execute with a static or dynamic predicate specifying tenant_id = ?.
In the vulnerable version of stigmem-node, the decay sweep worker fetches expired facts by querying the database using timestamp values without appending a tenant_id check. Because the SQL statements query the global facts table without isolation constraints, candidate selection matches facts from every tenant in the system. When the background job executes, it applies expiration overrides globally.
Similarly, the quarantine moderation route resolves fact lookups by targeting only the fact_id, ignoring the caller's active tenant identifier. Lastly, the RTBF system retrieves active tombstones based strictly on entity URIs. This omission permits tombstones registered by Tenant B to be parsed and applied during Tenant A's read path, enabling unauthorized, cross-tenant data suppression.
In node/src/stigmem_node/lifecycle/decay.py, the candidate-selection SQL queries were executed without a tenant_id constraint, leading to a global table scan.
# BEFORE PATCH (Vulnerable)
def _select_ttl_candidates(
conn: Any, effective_ttl: int, scope: str | None, now_dt: datetime
) -> list[str]:
cutoff = (now_dt - timedelta(seconds=effective_ttl)).isoformat()
sql = (
"SELECT f.id FROM facts f "
"LEFT JOIN fact_validity_overrides fvo ON fvo.fact_id = f.id "
"WHERE f.timestamp <= ? "
"AND COALESCE(fvo.valid_until, f.valid_until) IS NULL "
"AND NOT (entity LIKE 'stigmem:%' AND entity NOT LIKE 'stigmem://%') "
"AND NOT (relation LIKE 'stigmem:%' AND relation NOT LIKE 'stigmem://%')"
)
params: list[Any] = [cutoff]The patched code introduces a strict tenant_id parameter to the function signatures, appends AND f.tenant_id = ? to the SQL query, and binds the caller's active tenant identifier to the query parameters.
# AFTER PATCH (Fixed)
def _select_ttl_candidates(
conn: Any, effective_ttl: int, scope: str | None, now_dt: datetime, tenant_id: str
) -> list[str]:
cutoff = (now_dt - timedelta(seconds=effective_ttl)).isoformat()
sql = (
"SELECT f.id FROM facts f "
"LEFT JOIN fact_validity_overrides fvo ON fvo.fact_id = f.id "
"WHERE f.timestamp <= ? "
"AND f.tenant_id = ? " # Added tenant-scoping predicate
"AND COALESCE(fvo.valid_until, f.valid_until) IS NULL "
"AND NOT (entity LIKE 'stigmem:%' AND entity NOT LIKE 'stigmem://%') "
"AND NOT (relation LIKE 'stigmem:%' AND relation NOT LIKE 'stigmem://%')"
)
params: list[Any] = [cutoff, tenant_id]This same modification pattern was applied to _select_confidence_candidates in decay.py, _get_quarantined_fact in routes/quarantine.py, and _get_tombstone_filter in routes/facts/common.py. The remediation effectively binds all database filters to the verified session of the active caller, preventing cross-tenant leakage at the SQL layer. This fix is structurally complete, though long-term security depends on developers maintaining these predicates in future SQL queries.
An attacker can exploit this vulnerability with standard, low-privileged write credentials for an authorized tenant (e.g., Tenant B). The objective is to retrieve metadata and destroy active records within Tenant A (commonly running on the default workspace).
First, the attacker uses the decay sweep endpoint to execute a reconnaissance query. By sending an HTTP POST request to /v1/decay/sweep with the parameter dry_run set to true, the attacker forces the system to perform a global database scan. Because the SQL query lacks isolation predicates, the response returns the count of all facts stored across the entire multi-tenant server, confirming the volume of Tenant A's data.
POST /v1/decay/sweep HTTP/1.1
Host: vulnerable-node.stigmem.internal
Authorization: Bearer <Tenant-B-Write-Token>
Content-Type: application/json
{
"ttl_seconds": 0,
"dry_run": true
}Second, the attacker weaponizes the sweep by repeating the request with dry_run set to false. The application backend fetches all records older than zero seconds across all tenants, and writes an override setting valid_until to now() for each matched fact ID. Consequently, Tenant A's active database contents are immediately flagged as expired and purged from active queries, executing a cross-tenant denial of service.
The successful exploitation of GHSA-6GQW-JQV7-V88M leads to a high-impact breach of data integrity and availability, alongside low-impact confidentiality exposure. The CVSS v4.0 score is rated at 7.2 with the vector CVSS:4.0/AV:N/AC:L/AT:N/PR:L/UI:N/VC:L/VI:H/VA:H/SC:N/SI:N/SA:N.
The high rating for Integrity (VI:H) stems from the attacker's capability to modify other tenants' data states. By abusing the missing tenant filter in the quarantine route, a malicious tenant administrator can unilaterally approve or reject quarantined data belonging to other organizations, disrupting the ingestion workflows.
The high rating for Availability (VA:H) is driven by the potential for permanent or temporary data destruction via the decay sweep. An attacker can set arbitrary expiration constraints globally, forcing data to disappear from legitimate user queries. Confidentiality exposure remains low (VC:L) because raw data records are not fully dumped through the sweep endpoints, though record counts are directly leaked.
To remediate GHSA-6GQW-JQV7-V88M, systems administrators must upgrade the stigmem-node package to version 0.9.0a12 or newer. This version enforces standard tenant-parameter binding on all dynamic database selections. Organizations using the package in a single-tenant layout are not actively exposed but should upgrade to maintain robust code hygiene.
If upgrading immediately is not possible, administrators should disable the multi-tenant plugin by updating the configuration file or environment variables to set STIGMEM_MULTI_TENANT_ENABLED="false". Disabling multi-tenancy restricts the application context to a single default namespace, nullifying cross-tenant traversal vectors.
Web Application Firewalls (WAF) can be configured to block ad-hoc POST requests to /v1/decay/sweep and /v1/quarantine endpoints originating from untrusted tenants. Additionally, monitoring logs should flag any invocation of decay sweeps that occur outside scheduled maintenance windows or are initiated by non-administrative users.
CVSS:4.0/AV:N/AC:L/AT:N/PR:L/UI:N/VC:L/VI:H/VA:H/SC:N/SI:N/SA:N| Product | Affected Versions | Fixed Version |
|---|---|---|
stigmem-node eidetic-labs | < 0.9.0a12 | 0.9.0a12 |
| Attribute | Detail |
|---|---|
| CWE ID | CWE-863 (Incorrect Authorization) |
| Attack Vector | Network (AV:N) |
| CVSS v4.0 Score | 7.2 (High) |
| Impact | High (Integrity and Availability Compromise) |
| Exploit Status | Proof-of-Concept |
| KEV Status | Not Listed |
The software performs an authorization check when an actor attempts to access a resource, but it does not correctly verify that the actor is authorized to access that resource.
An incomplete sanitization vulnerability exists in rclone's SFTP backend before version 1.75.0 when performing server-side hashing operations on Windows hosts. Due to PowerShell treating Unicode smart quotes as equivalent to ASCII single quotes, malicious file paths can escape command string delimiters and execute arbitrary commands on the remote system.
A critical path traversal and authorization bypass vulnerability exists in the rclone serve restic command when multi-user isolation is enabled using the --private-repos flag. Due to a middleware desynchronization flaw, authenticated users can access, modify, or delete backup repositories belonging to other tenants.
A logic vulnerability in the rclone S3 backend implementation allows an unauthenticated adjacent-network attacker to intercept temporary AWS STS credentials. During HTTP redirection handling, the application fails to verify whether a protocol scheme change occurred (such as transitioning from HTTPS to HTTP). If a secure request is redirected to an unencrypted endpoint on the same host, rclone continues to forward the highly sensitive X-Amz-Security-Token header in cleartext.
CVE-2025-15366 is a command injection vulnerability in Python's standard imaplib module, occurring due to the improper neutralization of carriage returns (\r), line feeds (\n), and null bytes (\x00). When an application passes user-controlled input into standard IMAP library calls, an attacker can break out of the line-oriented protocol context and execute arbitrary IMAP directives with the privileges of the authenticated session.
A path traversal vulnerability (Zip Slip variant) exists in rclone's archive extract functionality before version 1.74.4. The command fails to sanitize relative directory components in archive headers, allowing files to be written outside the target directory or cloud prefix. This issue can result in arbitrary file writes or cloud object overwrites depending on the permissions of the credentials used. Nick Craig-Wood authored the patch on June 29, 2026, which was released in version 1.74.4 on July 14, 2026. This vulnerability is assigned CVE-2026-59732 and is cataloged as GHSA-4vr5-p2gc-h23p. This report provides a detailed root cause analysis, code-level diff, and remediation steps.
A local encoding path traversal vulnerability exists in rclone versions from v1.51.0 up to v1.75.0. When non-default local encoding parameters (such as Slash, None, or Raw) are specified, rclone's standard decoder maps safely encoded fullwidth dot-dot characters back into native directory traversal components. Since the local backend historically lacked a post-resolution path containment check, these relative segments resolved outside the designated synchronization root, allowing arbitrary file creation and modification on the host system.