Skip to content

add demands CreateDataSet scope even when the target data set already exists #677

Description

@jennijuju

The requirement is static because the preflight runs at Synapse setup, before data-set resolution — at that point the flow doesn't know whether it will create a data set or just add pieces to an existing one. So it asks for the worst case.

Consequence: a least-privilege key scoped to AddPieces only (exactly the kind of key the scoped-sessions feature encourages) can't run add against an existing data set, even though the operation it would actually perform is fully authorized. The gating error tells the owner to grant CreateDataSet for an upload that will never create anything.

Same pattern check is worth doing for import (same upload flow) when fixing.

Metadata

Metadata

Assignees

No one assigned

    Labels

    team/filecoin-pin"Filecoin Pin" project is a stakeholder for this work.team/fs-wgFOC working group is a stakeholder for this work, and thus wants to track it on their project board.

    Type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions