@fungi.computer/truffle 0.2.2 → 0.3.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/private-files-patch.js +3 -17
- package/dist/private-invocation-computer.d.ts +224 -12
- package/dist/private-invocation-computer.js +162 -22
- package/dist/private-invocation-files.d.ts +3 -2
- package/dist/private-invocation-files.js +22 -3
- package/dist/private-local-agent-control.d.ts +2 -2
- package/dist/private-local-bwrap.d.ts +9 -7
- package/dist/private-local-bwrap.js +26 -21
- package/dist/private-local-computer-processes.d.ts +15 -0
- package/dist/private-local-computer-processes.js +13 -0
- package/dist/private-local-containment.d.ts +15 -13
- package/dist/private-local-containment.js +49 -65
- package/dist/private-local-delegation.d.ts +3 -3
- package/dist/private-local-delegation.js +32 -19
- package/dist/private-local-exec-review.d.ts +12 -0
- package/dist/private-local-exec-review.js +62 -0
- package/dist/private-local-exec-rules.d.ts +16 -0
- package/dist/private-local-exec-rules.js +441 -0
- package/dist/private-local-git-exclude.js +25 -15
- package/dist/private-local-linux-sandbox.d.ts +5 -5
- package/dist/private-local-linux-sandbox.js +63 -30
- package/dist/private-local-mail.d.ts +2 -2
- package/dist/private-local-mesh-links.d.ts +4 -1
- package/dist/private-local-mesh-links.js +50 -3
- package/dist/private-local-native-digests.js +1 -1
- package/dist/private-local-native-install-error.d.ts +2 -0
- package/dist/private-local-native-install-error.js +10 -0
- package/dist/private-local-native-staging.d.ts +7 -8
- package/dist/private-local-native-staging.js +132 -43
- package/dist/private-local-permission-mode.d.ts +10 -0
- package/dist/private-local-permission-mode.js +18 -0
- package/dist/private-local-runtime-host.d.ts +28 -5
- package/dist/private-local-runtime-host.js +404 -66
- package/dist/private-local-sandbox-policy.d.ts +30 -11
- package/dist/private-local-sandbox-policy.js +223 -373
- package/dist/private-local-sandbox.d.ts +30 -25
- package/dist/private-local-sandbox.js +190 -100
- package/dist/private-local-seatbelt.d.ts +7 -13
- package/dist/private-local-seatbelt.js +55 -32
- package/dist/private-local-service-contract.d.ts +5 -4
- package/dist/private-local-service-discovery.d.ts +19 -7
- package/dist/private-local-service-discovery.js +4 -3
- package/dist/private-local-service-listener.js +40 -2
- package/dist/private-local-service-log.d.ts +18 -0
- package/dist/private-local-service-log.js +6 -0
- package/dist/private-local-service-owner.d.ts +18 -10
- package/dist/private-local-service-owner.js +119 -25
- package/dist/private-local-service.js +30 -3
- package/dist/private-local-session-discovery.d.ts +2 -1
- package/dist/private-local-session-discovery.js +18 -6
- package/dist/private-mcp-form-contract.d.ts +10 -1
- package/dist/private-mcp-form-contract.js +10 -1
- package/dist/private-mcp-form-session.d.ts +39 -3
- package/dist/private-mcp-form-session.js +28 -5
- package/dist/private-oyster-mcp-auth.d.ts +1 -1
- package/dist/private-oyster-mcp-auth.js +139 -7
- package/dist/private-provider-rejection.js +1 -1
- package/dist/seatbelt/safe-base.sbpl +2 -2
- package/native/bin/bwrap-build-source/Dockerfile +2 -0
- package/native/bin/bwrap-build-source/README.md +6 -6
- package/native/bin/bwrap-build-source/pin.mjs +2 -2
- package/native/bin/bwrap-build-source/record.mjs +12 -1
- package/native/bin/bwrap-build-source/vendor/seccomp-unix-block.c +10 -7
- package/native/bin/bwrap-build.json +3 -2
- package/native/bin/fungi-apply-patch +0 -0
- package/native/bin/fungi-seccomp-workspace.bpf +0 -0
- package/native/bin/fungi-seccomp-workspace.bpf.sha256 +1 -0
- package/package.json +23 -17
|
@@ -10,15 +10,35 @@ export declare function resolveAgentFolder(project: string, folder: string): {
|
|
|
10
10
|
export type LocalSandboxPolicy = Readonly<{
|
|
11
11
|
projectRoot: string;
|
|
12
12
|
writableRoot: string;
|
|
13
|
+
/** Whole Git administration and Agent state, read-only in Workspace. */
|
|
13
14
|
readOnly: readonly string[];
|
|
14
|
-
immovable: readonly string[];
|
|
15
15
|
}>;
|
|
16
|
+
/** The host, never project configuration, chooses every writable cache grant. */
|
|
17
|
+
export type LinuxSandboxProfile = LocalSandboxPolicy & Readonly<{
|
|
18
|
+
mode: "workspace" | "read-only";
|
|
19
|
+
writable: readonly string[];
|
|
20
|
+
hidden: readonly string[];
|
|
21
|
+
temporaryDirectory: string;
|
|
22
|
+
/** Host-selected cache carve-out to prepare before rendering bwrap mounts. */
|
|
23
|
+
fungiCache: string | undefined;
|
|
24
|
+
sshAgentSocket: string | undefined;
|
|
25
|
+
sshAgentMask: string | undefined;
|
|
26
|
+
}>;
|
|
27
|
+
export declare function linuxSandboxProfile(policy: LocalSandboxPolicy, mode: "workspace" | "read-only", temporaryDirectory: string, host: NodeJS.ProcessEnv,
|
|
28
|
+
/** Pass the real passwd home in production; fixtures supply their own. */
|
|
29
|
+
osHome: string, platform?: "linux" | "darwin"): LinuxSandboxProfile;
|
|
30
|
+
/** Private persistent Agent temp, not the staging directory or host /tmp. */
|
|
31
|
+
export declare function agentSandboxTemporaryDirectory(agentId: string, project: string): string;
|
|
16
32
|
export declare class UnsafeNativePayload extends Error {
|
|
17
33
|
readonly name = "UnsafeNativePayload";
|
|
18
34
|
}
|
|
19
35
|
export declare class UnsafeHostCode extends Error {
|
|
20
36
|
readonly name = "UnsafeHostCode";
|
|
21
37
|
}
|
|
38
|
+
/** A symlinked Git marker cannot be protected by a bind on its logical name. */
|
|
39
|
+
export declare class UnsafeGitMarker extends Error {
|
|
40
|
+
readonly name = "UnsafeGitMarker";
|
|
41
|
+
}
|
|
22
42
|
/**
|
|
23
43
|
* Packed CLI identity is supplied by the Node bin wrapper, which loaded both
|
|
24
44
|
* paths before spawning Bun. This is an admission check, not an integrity
|
|
@@ -28,15 +48,14 @@ export declare function assertHostCodeOutsideAgent(project: string, cli: string,
|
|
|
28
48
|
/** Refuse both logical and resolved native source locations in the whole
|
|
29
49
|
* Agent project or Git administration before verifying source bytes. */
|
|
30
50
|
export declare function assertHostOwnedNativeFile(project: string, path: string): void;
|
|
31
|
-
/** Host liveness check for private PID-named run reclamation. */
|
|
32
|
-
export type NativeRunLivenessProbe = (pid: number) => void;
|
|
33
|
-
/** New private inode, never a link or bind of an installed payload. */
|
|
34
|
-
export declare function privateNativeDirectory(project: string, probe?: NativeRunLivenessProbe): string;
|
|
35
|
-
export declare function stageNativeBytes(directory: string, label: string, bytes: Uint8Array): string;
|
|
36
51
|
/** One logical/resolved authority for Files, bwrap and Seatbelt. */
|
|
37
52
|
export declare function protectedSandboxPaths(paths: readonly string[]): string[];
|
|
38
|
-
/**
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
53
|
+
/** Git owns the representation of the selected folder's worktree and common dir. */
|
|
54
|
+
export declare function gitDirectories(project: string, root: string, path?: string): {
|
|
55
|
+
common: string;
|
|
56
|
+
worktree: string;
|
|
57
|
+
} | undefined;
|
|
58
|
+
/** Remote names from the protected common config only, never a racy worktree path. */
|
|
59
|
+
export declare function protectedGitRemoteNames(project: string, common: string, path: string): ReadonlySet<string> | undefined;
|
|
60
|
+
/** Recompute for each command: the prior command may have initialized Git. */
|
|
61
|
+
export declare function sandboxPolicy(project: string, folder: string): LocalSandboxPolicy;
|