-
Notifications
You must be signed in to change notification settings - Fork 0
Security
krwg edited this page Jul 8, 2026
·
1 revision
How the cultiva-plugins registry maintains integrity and what authors must respect.
flowchart LR
R[registry.json sha256 map]
D[Download from baseUrl]
V[Verify hash before load]
S[Sandbox execution]
R --> D --> V --> S
Cultiva refuses to load plugin files whose hash does not match the registry entry.
| Rule | Why |
|---|---|
| No secrets in source | Plugin folders are public on GitHub |
Declare permissions accurately |
RPC calls are allowlist-gated |
Minimize network usage |
Only fetch trusted HTTPS endpoints |
| Escape user HTML in sheets | Prevent XSS in main window DOM |
| Bump version on every change | sha256 + catalog clarity |
Plugins run in an opaque-origin iframe:
- No
window.electron - No direct Cultiva DOM access
- No Node.js APIs
- Storage is namespaced per plugin id
Main-window UI is injected by plugin-manager — treat all HTML as untrusted input on the host side too.
Bundled files listed in manifest.data are read via Electron IPC in the desktop app only. Paths are restricted to the plugin install directory.
Default registry URL points to this repo (krwg/cultiva-plugins). Users can override the URL in advanced settings — they trust whichever registry they configure.
For third-party registries: same sha256 rules apply if using Cultiva 1.7+.
- Cultiva core: SECURITY.md — private disclosure
- Plugin in this registry: open a security issue or email maintainer — do not exploit
-
postMessagetarget origin'*'in sandbox bridge -
Audio()not permission-gated likefetch - Failed plugin init may silently remove install entry (core UX issue)
Tracked under milestone 1.7 Linden · Plugin Hardening.