Relationships
#4598 datastore setup extension over serve: resolve --config expressions with per-caller authorization
Opened by zack · 11/10/2026
Follow-up to swamp-club#4569. Local datastore setup extension now resolves env and vault expressions in --config and persists them unresolved. Setup through serve (the datastore.setup.extension request, e.g. swamp datastore setup extension --server) refuses a config that holds expressions instead of resolving it, because the config is client text and the handler only checks admin on the model kind, while serve authorizes vault access per vault (vaultAccessResource) and treats env reads from caller-supplied text as privileged (authorizeExpressionReferences / EnvAccess).
Proposal: in handleDatastoreSetupExtension, analyze the payload config expressions and require read on each vault a vault.get names, and the same env permission serve applies to run inputs, before resolving with the server's environment and vaults. Then the serve adapter's resolveConfigExpressions can resolve instead of refuse. Tests should cover a refusal for an unreadable vault, an env reference without the env permission, and a successful resolution for an authorized caller.
Open
No activity in this phase yet.
Sign in to post a ripple.