Skip to content

Confine import_markdown_directory to an allowed base path #1515

Closed

Description

@malibio

Overview

The import_markdown_directory Tauri command reads a caller-supplied directory path with only exists/is-file checks and no confinement to an allowed root.

Problem Statement

Under the current single-user-local trust model this is acceptable, but it is exactly the kind of method that becomes dangerous if the socket/pipe boundary is ever weak (see the Windows pipe finding). A confined base directory is defense-in-depth.

Proposed Solution

Confine imports to a configured base directory (or an explicitly user-selected root), rejecting paths outside it.

Acceptance Criteria

  • Import is confined to an allowed base directory
  • Code passes bun run quality:fix; tests pass

Technical Specifications

Reference Files

  • packages/desktop-app/src-tauri/src/commands/import.rs (~218-227)

Related Issues

Activity

  1. malibio commented on Jul 6, 2026

    @malibio
    CollaboratorAuthor

    Frontend baseline: 147 test files / 3948 tests passed

  2. self-assigned this
    on Jul 6, 2026
  3. added a commit that references this issue on Jul 6, 2026
    273f157
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions