interface DeclaredPermissions

What a plugin is allowed to touch — enforced by starting its Deno subprocess with exactly the matching --allow-net/--allow-read/--allow-write flags and nothing wider (lanrurugi_plugin::pool::Worker::spawn), constitution Principle IV. Declaring less than a plugin actually needs fails loudly at the call site (a denied fetch/file op throws); there is no way to request "read access to one specific file" here beyond PluginInfoResult.sidecar_files, which the host resolves itself rather than granting real filesystem access for.

Properties

net: string[]

Exact hostnames this plugin's fetch() calls are allowed to reach — verify every one against a real URL literal in the plugin's own source before shipping it; an empty array means no network access at all.

read: boolean
write: boolean

Usage

import { type DeclaredPermissions } from "crates/lanrurugi-plugin/dispatcher/plugin-sdk.ts";