Skip to content

Authorize O_TRUNC before applying truncation #1320

Description

@wdcui

The current fs engine and resolver-managed backends can apply O_TRUNC before the caller permissions are checked. A denied open may therefore empty a file, and the intended Linux-compatible behavior of O_RDONLY|O_TRUNC also needs confirmation with the original fs author. Define the desired semantics, then coordinate resolver authorization with InMem and Overlay truncation timing and add focused permission tests. Deferred from #1318 to keep that PR behavior-neutral.

Activity

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

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions