secure-exec 0.0.0-nathan-release-0-3-0.2076211

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/README.md ADDED
@@ -0,0 +1,31 @@
1
+ # secure-exec
2
+
3
+ The public SDK for secure-exec, a fully virtualized runtime for executing
4
+ untrusted JavaScript inside a kernel isolation boundary.
5
+
6
+ This package re-exports the curated public surface. For low-level and advanced
7
+ APIs, use `@secure-exec/core`.
8
+
9
+ ## Install
10
+
11
+ ```sh
12
+ npm install secure-exec
13
+ ```
14
+
15
+ ## Usage
16
+
17
+ ```ts
18
+ import { NodeRuntime } from "secure-exec";
19
+
20
+ const rt = await NodeRuntime.create();
21
+ const { stdout, exitCode } = await rt.exec("console.log('hi', 1 + 1)");
22
+ console.log(stdout, exitCode);
23
+ await rt.dispose();
24
+ ```
25
+
26
+ Guest code runs inside a virtualized VM with no network access by default.
27
+ Opt into the network by passing a permission policy:
28
+
29
+ ```ts
30
+ const rt = await NodeRuntime.create({ permissions: { network: "allow" } });
31
+ ```
@@ -0,0 +1,2 @@
1
+ export type { HostDirectoryMount, HostToolDefinition, HostToolExample, NodeRuntimeCreateOptions, NodeRuntimeExecOptions, NodeRuntimeExecResult, NodeRuntimeFetchInput, NodeRuntimeFetchResponse, NodeModulesMount, NodeRuntimeListener, NodeRuntimeListenerQuery, NodeRuntimeProcess, NodeRuntimeRunResult, NodeRuntimeSpawnOptions, NodeRuntimeWaitForListenerOptions, } from "@secure-exec/core";
2
+ export { NodeRuntime } from "@secure-exec/core";
package/dist/index.js ADDED
@@ -0,0 +1 @@
1
+ export { NodeRuntime } from "@secure-exec/core";
package/package.json ADDED
@@ -0,0 +1,30 @@
1
+ {
2
+ "name": "secure-exec",
3
+ "version": "0.0.0-nathan-release-0-3-0.2076211",
4
+ "type": "module",
5
+ "license": "Apache-2.0",
6
+ "main": "./dist/index.js",
7
+ "types": "./dist/index.d.ts",
8
+ "files": [
9
+ "dist",
10
+ "README.md"
11
+ ],
12
+ "exports": {
13
+ ".": {
14
+ "types": "./dist/index.d.ts",
15
+ "import": "./dist/index.js",
16
+ "default": "./dist/index.js"
17
+ }
18
+ },
19
+ "scripts": {
20
+ "build": "tsc",
21
+ "check-types": "tsc --noEmit"
22
+ },
23
+ "dependencies": {
24
+ "@secure-exec/core": "0.0.0-nathan-release-0-3-0.2076211"
25
+ },
26
+ "devDependencies": {
27
+ "@types/node": "^22.10.2",
28
+ "typescript": "^5.7.2"
29
+ }
30
+ }