Skip to content

security(edge): bind private Cargo fallback URL to exact crate resource #115

Open

Description

@the1mills

assertProviderDestination() currently gives GitHub and npm path-level resource confinement, but the cargo-registry case only checks url.origin === grant.origin.

That leaves a confused-deputy gap: a capability granting crate A on a private Cargo registry can plan a request to another path/crate on the same origin if the broker credential is broader than one crate.

Do not guess one private-registry URL layout. First define/version the supported private Cargo request forms, then:

  • bind every allowed URL form to the exact grant.resource crate name;
  • reject path traversal/percent-encoding ambiguity and alternate crate coordinates;
  • keep exact credential-free HTTPS origin confinement;
  • add negative tests for same-origin/wrong-crate requests;
  • ensure the credential broker independently scopes or rechecks the crate resource rather than relying only on host isolation;
  • update the interface contract if multiple Cargo URL forms need an explicit resource-path template or request kind.

Until this is specified, private Cargo fallback should remain fail-closed for URL shapes that cannot be proven resource-bound.

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