Skip to content

Provider driver contract and operation allowlist #34

Closed

Description

@somethingwithproof

Summary

Drivers are interchangeable behind one interface and can build only read operations.

Requirements

  • REQ-DRV-001 Every driver MUST implement the ProviderDriver interface: endpoints, verify, discover, collect, and estimate.
  • REQ-DRV-002 Each driver MUST declare a fixed list of provider operations, and its request builder MUST refuse any other before signing.
  • REQ-DRV-003 Drivers MUST return typed error classes (auth, permission, throttled, transient, malformed, config, budget) and MUST NOT pass provider text to pages.
  • REQ-DRV-004 Each driver MUST ship a metric catalog from which templates, data source names, and script server fields are generated.
  • REQ-DRV-005 A driver MUST be loaded only for accounts that use its provider.

Acceptance criteria

  • A test enumerates each driver's buildable operations and compares them with its allowlist.
  • A fake driver passes the core's contract tests.

References

Dependencies

Activity

  1. added
    type: requirementA testable behavior the plugin must have
    area: driversProvider driver contract and implementations
    area: securityTrust boundaries, permissions, and secret safety
    on Nov 14, 2026
  2. somethingwithproof commented on Nov 15, 2026

    @somethingwithproof
    OwnerAuthor

    Done in #81 and #82, but neither PR closed this issue. Each acceptance criterion is met on main:

    • Operations against the allowlist: tests/Unit/DigitalOceanDriverTest.php ("allows only GET under the three documented prefixes, and every catalog path") checks every operation and every catalog path against the guard, and refuses writes and undocumented paths. tests/Unit/DriverContractTest.php ("lists only read operations for every registered driver") does the same for every production driver.
    • Fake driver: FakeDriver in tests/Unit/DriverContractTest.php passes the core's contract tests, including the guarded-transport refusal.
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

    area: driversProvider driver contract and implementationsarea: securityTrust boundaries, permissions, and secret safetyphase: 1 coreCore and DigitalOceanpriority: highNeeded for its milestonetype: requirementA testable behavior the plugin must have

    Projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions