Skip to content

fix(security): restrict localhost file-serving endpoints #23

@ubugeeei

Description

@ubugeeei

Finding

The backend serves local media paths from request parameters while applying permissive CORS. This is a high-risk local-file exposure surface for a desktop app.

Evidence

  • backend/src/main.rs media handlers accept path query values.
  • backend/src/util.rs resolves user-provided paths.
  • Shared response helpers apply wildcard-style CORS.

Acceptance criteria

  • Restrict readable paths to explicit project/user-approved roots or signed requests.
  • Reject untrusted origins.
  • Add tests for rejected path/origin combinations.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions