← Back to release summary

FileSystemAccess: add "write" access mode

Category
File APIs
Type
New or changed feature
Status
Proposed (Chrome Proposed)
Intent stage
None

Summary

The File System Access API defines two access modes for file system entries: "read" and "readwrite". These modes are used when querying or requesting permission to an entry. An issue with the current model is that operations requiring only file system modification, such as FileSystemHandle.remove(), are forced to request broad "readwrite" permission. This behavior poses some unnecessary security risks. To address this, we propose a more granular, "write" permission mode. This new mode will allow applications to request only the permission to write to a file or directory, without also gaining permission to read from it.

Motivation

The File System Access API defines two access modes for file system entries: "read" and "readwrite". These modes are used when querying or requesting permission to an entry. An issue with the current model is that operations requiring only file system modification, such as FileSystemHandle.remove(), are forced to request broad "readwrite" permission. This behavior poses some unnecessary security risks.

Standards & signals

Ecosystem

Explainers: https://github.com/WICG/file-system-access/pull/462/files

View on chromestatus.com