Skip to content

design-15 S6a: secret:// operator targets + Sub-Store auto-sync - #16

Closed
lr00rl wants to merge 1 commit into
feat/design-15-chain-edgesfrom
feat/design-15-substore-integration
Closed

design-15 S6a: secret:// operator targets + Sub-Store auto-sync#16
lr00rl wants to merge 1 commit into
feat/design-15-chain-edgesfrom
feat/design-15-substore-integration

Conversation

@lr00rl

@lr00rl lr00rl commented Jul 20, 2026

Copy link
Copy Markdown
Contributor

Summary

design-15 §7 server slice (Sub-Store stays a separate companion):

  • secret:// operator targets: a declared payload operator-target field may carry secret://<key>; the gateway resolves it from the plugin's own encrypted vault (pluginsecret:<pluginID>) before binding and rewrites the payload, so a saved Sub-Store endpoint backs http.operator.do without the URL re-crossing the browser. Unknown/malformed refs fail loud; resolution is audited without the value.
  • Vault isolation preserved: the new pluginSecretValue in plugin_host.go is the single non-broker read path — TestNoHTTPHandlerReachesThePluginSecretStore still confines store accessors to that file.
  • Auto-sync: every committed vpn-core mutation (CRUD/bind/unbind/rotate + applied line-user tasks) re-arms a 30s debounced trigger; on fire, if the companion has a saved endpoint and autosync=1, the server invokes import as the system actor (allow/deny audited). Silent skip when disabled/inactive; no generic event bus (design-15 appendix C).

Stacked on #15. Companion artifact/UI slice lands in the sub-store repo.

Verification

  • gofmt/go vet clean; go test ./internal/server/ ok (20s) incl. the vault-isolation guard
  • New tests: secret:// resolve/rewrite/passthrough/missing/malformed/cross-namespace, autosync gate matrix, invoke-once with bound endpoint, inactive skip, failure → deny audit

Refs LatticeNet/lattice#2, #13#15.

design-15 §7 (no plugin merge): declared payload operator-target fields
may now carry secret://<key>, resolved from the plugin's own encrypted
vault before binding — so a saved Sub-Store endpoint can back
http.operator.do without the URL re-crossing the browser. Resolution
goes through plugin_host.go's new pluginSecretValue, the single
non-broker read path the vault isolation test permits.

Every committed vpn-core mutation (identity CRUD, bindings, rotation,
applied line-user changes) re-arms a 30s debounced trigger; on fire, if
the Sub-Store companion has a saved endpoint and autosync enabled, the
server invokes its import as the system actor with allow/deny audits.
Silent skip when disabled or inactive; no generic event bus (appendix C).
@lr00rl

lr00rl commented Jul 22, 2026

Copy link
Copy Markdown
Contributor Author

Superseded by #20, which rebased the complete remaining Design 15 stack onto alpha/v0.2.2 and passed go test, go vet, gosec, govulncheck, formatting, and Docker contract CI before merge as 86422a1.

@lr00rl lr00rl closed this Jul 22, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant