Skip to content

Grants and lockfiles

Manifest and lockfile

wago.json records what the project wants:

json
{
  "$schema": "https://wago.sh/v0/schema.json",
  "plugins": {
    "wago-org/wasi": "^0.0.0"
  }
}

wago-lock.json records what Wago resolved and what you approved: exact versions, required and granted capabilities, budgets, and opaque plugin configuration.

Commit both files. Review lockfile changes like a native dependency update.

Review grants

sh
wago plugin inspect wago-org/wasi
wago plugin grant wago-org/wasi

Automation should name the decision:

sh
wago plugin add wago-org/wasi \
  --allow host.imports \
  --no-input

--allow-all and --deny-all are available, but an explicit capability list is easier to review.

Privileged plugin capabilities

CapabilityAuthorizes
host.importsHost functions and active caller resolution
host.environmentWago's narrow host environment
module.compileCompile transforms and observations
instance.lifecycleInstance creation and close hooks
instance.invokeRuntime-managed call hooks
runtime.lifecycleRuntime shutdown and cleanup
instance.manageRestricted managed instances

Some grants include budgets such as a live instance cap or per-instance declared memory limit.

Plugin authority and guest authority

Plugin grants control access to privileged Wago APIs. Guest capabilities such as fs.read and net.outbound describe what the module may use. Runtime Policy applies the guest layer.

Neither layer turns arbitrary plugin Go code into a sandbox. Plugins remain native open-source dependencies.

Programmatic registration

go
if err := rt.Use(
	extension,
	wago.WithPluginGrants(wago.PluginHostImports),
); err != nil {
	return err
}

Supplying WithPluginGrants enables strict authorization for every declared and exercised privileged capability.

Next

Released under the Apache 2.0 License.