GuestPolicy
# Language Settings: Policy
Guest "policies" define the access rights granted to a given guest language VM. Policies are defined by the host and
enforced at runtime.
Content copied to clipboard
elide.meta.GuestPolicy
Types
Properties
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Functions
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
## Policies: Allow-all.
Allows all host access for the guest language. This means the guest language can load classes, access I/O, and
perform other potentially sensitive or dangerous operations. Exercise extreme caution enabling this policy.
Content copied to clipboard
bool allow_all = 1;
Link copied to clipboard
Whether to allow the guest language to call native code. Defaults to `false`.
Content copied to clipboard
bool allow_native = 5;
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Maximum execution time to allow for execution within this guest; there is a sensible Elide-wide default if
unspecified. Expressed in a count of milliseconds. `0` disables the restriction.
Content copied to clipboard
uint64 execution_time = 11;
Link copied to clipboard
Whether to allow the guest language to access host-side environment. Defaults to `false`.
Content copied to clipboard
bool host_env = 8;
Link copied to clipboard
Whether to allow the guest language to access host-side networking. Defaults to `false`.
Content copied to clipboard
bool host_net = 7;
Link copied to clipboard
Link copied to clipboard
## Policies: Integrated.
Allows some host access for the guest language; this includes values shared in callbacks and invocation bindings.
The guest language can only load certain classes, cannot access host I/O (by default), and is *allowed* to call
native code; this mode should be used when all executing code is under the developer's control.
Content copied to clipboard
bool integrated = 2;
Link copied to clipboard
## Policies: Isolated.
Allows no host access for the guest language. This means the guest language cannot load classes, access host I/O,
or perform other potentially sensitive or dangerous operations. Resources used by guest languages can be capped
or otherwise controlled.
Content copied to clipboard
bool isolated = 3;
Link copied to clipboard
Maximum memory to allow for allocation within this guest language; there is a sensible Elide-wide default if
unspecified. Expressed as a count of bytes. `0` disables the restriction.
Content copied to clipboard
uint32 max_memory = 9;
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Whether to allow process control for the guest; the guest will be able to launch OS-native processes if this flag
is activated. In most secure operating modes this flag defaults to being off.
Content copied to clipboard
bool processes = 12;
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
## Policies: Sandbox.
Like the `ISOLATED` policy, but applies a stronger sandbox; allows no host access for the guest language. This
means the guest language cannot load classes, access host I/O, or perform other potentially sensitive or
dangerous operations. Resources used by guest languages can be capped or otherwise controlled.
If available, hardware isolation is used; otherwise, software isolation is used.
Content copied to clipboard
bool sandbox = 4;
Link copied to clipboard
Link copied to clipboard
Maximum stack depth to allow for execution within this guest; there is a sensible Elide-wide default if
unspecified. Specified as a numeric count. `0` disables the restriction.
Content copied to clipboard
uint32 stack_depth = 10;
Link copied to clipboard
Whether to allow thread control for the guest; the guest will be able to launch OS-native threads if this flag is
activated. In most secure operating modes this flag defaults to being off.
Content copied to clipboard
bool threads = 13;
Link copied to clipboard
Link copied to clipboard
## Policies: Allow-all.
Allows all host access for the guest language. This means the guest language can load classes, access I/O, and
perform other potentially sensitive or dangerous operations. Exercise extreme caution enabling this policy.
Content copied to clipboard
bool allow_all = 1;
Link copied to clipboard
## Policies: Integrated.
Allows some host access for the guest language; this includes values shared in callbacks and invocation bindings.
The guest language can only load certain classes, cannot access host I/O (by default), and is *allowed* to call
native code; this mode should be used when all executing code is under the developer's control.
Content copied to clipboard
bool integrated = 2;
Link copied to clipboard
## Policies: Isolated.
Allows no host access for the guest language. This means the guest language cannot load classes, access host I/O,
or perform other potentially sensitive or dangerous operations. Resources used by guest languages can be capped
or otherwise controlled.
Content copied to clipboard
bool isolated = 3;
Link copied to clipboard
## Policies: Sandbox.
Like the `ISOLATED` policy, but applies a stronger sandbox; allows no host access for the guest language. This
means the guest language cannot load classes, access host I/O, or perform other potentially sensitive or
dangerous operations. Resources used by guest languages can be capped or otherwise controlled.
If available, hardware isolation is used; otherwise, software isolation is used.
Content copied to clipboard
bool sandbox = 4;
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
open fun <ContainingT : Message?, T> newFileScopedGeneratedExtension(singularType: Class<out Any>, defaultInstance: Message): GeneratedMessage.GeneratedExtension<ContainingT, T>
Link copied to clipboard
open fun <ContainingT : Message?, T> newMessageScopedGeneratedExtension(scope: Message, descriptorIndex: Int, singularType: Class<out Any>, defaultInstance: Message): GeneratedMessage.GeneratedExtension<ContainingT, T>
Link copied to clipboard
open fun parseDelimitedFrom(input: InputStream, extensionRegistry: ExtensionRegistryLite): GuestPolicy
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard