MCPcopy Create free account
hub / github.com/NVIDIA/OpenShell / policy_with_process

Function policy_with_process

crates/openshell-supervisor-process/src/process.rs:1438–1446  ·  view source on GitHub ↗

Helper to create a minimal `SandboxPolicy` with the given process policy.

(process: ProcessPolicy)

Source from the content-addressed store, hash-verified

1436
1437 /// Helper to create a minimal `SandboxPolicy` with the given process policy.
1438 fn policy_with_process(process: ProcessPolicy) -> SandboxPolicy {
1439 SandboxPolicy {
1440 version: 1,
1441 filesystem: FilesystemPolicy::default(),
1442 network: NetworkPolicy::default(),
1443 landlock: LandlockPolicy::default(),
1444 process,
1445 }
1446 }
1447
1448 /// Unknown names may yield `Ok(None)` (`… not found …`) or `Err` when NSS fails first
1449 /// (e.g. `ENOENT: No such file or directory`).

Calls

no outgoing calls