Skip to content

security(analytics): cross_language_patterns.py has same cross-project leak as #12330 (scoped fix risky — detector couples project_root to ChromaDB path) #12356

Closed

Description

@mrveiss

Discovered fixing #12330 (PR #12355 scoped the other 5 leaking analytics endpoints). autobot-backend/api/analytics/endpoints/cross_language_patterns.py has the SAME missing-source_id-scoping leak, but its CrossLanguagePatternDetector couples project_root to its ChromaDB/embedding-cache path, so a scoped fix is behaviorally risky and was deliberately left out of #12355 to keep that PR focused. Fix here: scope by source_id (via resolve_scan_root from endpoints/shared.py) AND ensure the detector's ChromaDB/embedding-cache keying is per-source so one project can't see another's cross-language patterns. Security (cross-project data isolation). Refs #12330 #12355.

Activity

  1. github-actions commented on Jul 24, 2026

    @github-actions
    Contributor

    PR #12374 (merged to Dev_new_gui) references this issue with a close keyword.

    fix(security): scope cross_language_patterns analytics by source_id (#12356)

    If this issue is fully resolved, close it manually. If work remains, no action is needed.

  2. mrveiss commented on Jul 24, 2026

    @mrveiss
    OwnerAuthor

    Delivered in PR #12374 (merged to Dev_new_gui, code-review MERGE-READY): cross_language_patterns analytics scoped by source_id (per-source cache key, ChromaDB where-filter, embedding-cache key) — cross-project leak closed on every path.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions