Skip to content

Windows 10: apply_patch rejects authorized E: paths with “path contains a reparse point” in 0.160.0 #50617

Open

Description

@windmcc11-oss

Environment

  • Windows 10, build 19045
  • Codex CLI, backend, and npm package: 0.160.0
  • Sandbox: workspace-write, with two authorized directories on E:
  • Project and file names below are redacted.

Problem
apply_patch rejects both absolute and relative project file paths with “path contains a reparse point.” Source files remain unchanged, and tests never start.

Expected behavior
Edits within the authorized workspace should succeed when the paths pass the applicable security checks.

Read-only diagnostic results

  • No ReparsePoint attribute was found on the drive root, project directories, or target files checked.
  • QueryDosDeviceW maps E: to \Device\HarddiskVolume2.
  • NtCreateFile with OBJ_DONT_REPARSE on ??\E:<project><file> returns NTSTATUS 0xC000050B, mapped to Win32 error 4395.
  • The same read-only operation on \Device\HarddiskVolume2<project><file> succeeds.

This difference was reproduced for two existing files. No write bypass was attempted.

Possible connection
PR #47672 addresses drive-alias handling in windows-sandbox-rs/src/no_reparse_dir.rs while retaining reparse checks. That change is already included in 0.160.0.

However, the 0.160.0 exec-server implementation still constructs a drive-letter NT path and does not use QueryDosDeviceW.

These observations are consistent with a similar drive-alias issue, but the failing runtime call has not been traced, so the root cause is not confirmed. I have not verified a fix in a newer version.

Could maintainers check whether exec-server needs an equivalent secure fix? If already addressed, please identify the fixing commit and first official release containing it. Please also confirm Windows 10 regression coverage with OBJ_DONT_REPARSE protection retained.

The original request/tool-call ID and a standalone diagnostic script are unavailable.

Activity

  1. added
    bug
    CLI
    windows-os
    sandbox
    tool-calls
    on Oct 3, 2026
  2. github-actions commented on Oct 3, 2026

    @github-actions
    Contributor

    Potential duplicates detected. Please review them and close your issue if it is a duplicate.

    Powered by Codex Action

  3. bubustudioofficial commented on Oct 11, 2026

    @bubustudioofficial

    Additional update: The problem persists with bundled Codex CLI 0.162.0-alpha.17.2.

    Native diagnostics still show 0xC000050B / Win32 4395 when reading authorized E: drive paths, while the equivalent same-volume device-path read succeeds.

    The dedicated apply_patch backend version and exact failing call remain unverified. No security protections were bypassed.

    Please confirm whether a supported fix is planned and which release will contain it.

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    CLIbugsandboxtool-callswindows-os

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions