@genobank/biofs 1.6.6 → 1.6.9
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/CHANGELOG.md +134 -16
- package/dist/commands/biofiles.d.ts +9 -0
- package/dist/commands/biofiles.d.ts.map +1 -0
- package/dist/commands/biofiles.js +112 -0
- package/dist/commands/biofiles.js.map +1 -0
- package/dist/commands/labs/list.d.ts +19 -0
- package/dist/commands/labs/list.d.ts.map +1 -0
- package/dist/commands/labs/list.js +98 -0
- package/dist/commands/labs/list.js.map +1 -0
- package/dist/commands/share.d.ts +10 -0
- package/dist/commands/share.d.ts.map +1 -0
- package/dist/commands/share.js +186 -0
- package/dist/commands/share.js.map +1 -0
- package/dist/index.js +54 -11
- package/dist/index.js.map +1 -1
- package/dist/lib/ai/classifier.d.ts +1 -3
- package/dist/lib/ai/classifier.d.ts.map +1 -1
- package/dist/lib/ai/classifier.js +17 -37
- package/dist/lib/ai/classifier.js.map +1 -1
- package/dist/lib/api/client.d.ts +46 -0
- package/dist/lib/api/client.d.ts.map +1 -1
- package/dist/lib/api/client.js +167 -7
- package/dist/lib/api/client.js.map +1 -1
- package/dist/lib/auth/server.d.ts.map +1 -1
- package/dist/lib/auth/server.js +2 -11
- package/dist/lib/auth/server.js.map +1 -1
- package/dist/lib/biofiles/resolver.d.ts.map +1 -1
- package/dist/lib/biofiles/resolver.js +59 -75
- package/dist/lib/biofiles/resolver.js.map +1 -1
- package/dist/lib/config/constants.d.ts +1 -0
- package/dist/lib/config/constants.d.ts.map +1 -1
- package/dist/lib/config/constants.js +3 -3
- package/dist/lib/config/constants.js.map +1 -1
- package/dist/lib/utils/logger.d.ts +5 -6
- package/dist/lib/utils/logger.d.ts.map +1 -1
- package/dist/lib/utils/logger.js +5 -23
- package/dist/lib/utils/logger.js.map +1 -1
- package/dist/types/api.d.ts +21 -0
- package/dist/types/api.d.ts.map +1 -1
- package/dist/types/biofiles.d.ts +2 -2
- package/dist/types/biofiles.d.ts.map +1 -1
- package/package.json +2 -2
- package/.claude/settings.local.json +0 -33
- package/BIOFS_FEDERATED_NETWORK_ARCHITECTURE.md +0 -1071
- package/BIOFS_NODE_CLIENT_ARCHITECTURE.md +0 -557
- package/BIOFS_NODE_IMPLEMENTATION_PLAN.md +0 -2164
- package/BUBBLEWRAP_INTEGRATION.md +0 -486
- package/BUBBLEWRAP_QUICKSTART.md +0 -356
- package/BUBBLEWRAP_README.md +0 -466
- package/BUBBLEWRAP_STRATEGIC_ANALYSIS.md +0 -625
- package/GEMINI_REMOVAL_COMPLETE.md +0 -311
- package/debug_credentials.js +0 -60
- package/dist/commands/sandbox.d.ts +0 -10
- package/dist/commands/sandbox.d.ts.map +0 -1
- package/dist/commands/sandbox.js +0 -418
- package/dist/commands/sandbox.js.map +0 -1
- package/dist/lib/sandbox/bubblewrap.d.ts +0 -125
- package/dist/lib/sandbox/bubblewrap.d.ts.map +0 -1
- package/dist/lib/sandbox/bubblewrap.js +0 -343
- package/dist/lib/sandbox/bubblewrap.js.map +0 -1
- package/examples/sandbox-usage.ts +0 -361
|
@@ -1,343 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
/**
|
|
3
|
-
* Bubblewrap Sandbox Integration for BioFS-CLI
|
|
4
|
-
*
|
|
5
|
-
* Provides secure isolation for genomic data processing operations
|
|
6
|
-
* using Linux namespaces via bubblewrap.
|
|
7
|
-
*
|
|
8
|
-
* Security guarantees:
|
|
9
|
-
* - Process isolation (PID namespace)
|
|
10
|
-
* - Network isolation (NET namespace)
|
|
11
|
-
* - Filesystem isolation (MOUNT namespace)
|
|
12
|
-
* - IPC isolation (IPC namespace)
|
|
13
|
-
* - Seccomp syscall filtering
|
|
14
|
-
* - Capability dropping
|
|
15
|
-
*
|
|
16
|
-
* @module lib/sandbox/bubblewrap
|
|
17
|
-
*/
|
|
18
|
-
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
19
|
-
if (k2 === undefined) k2 = k;
|
|
20
|
-
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
21
|
-
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
22
|
-
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
23
|
-
}
|
|
24
|
-
Object.defineProperty(o, k2, desc);
|
|
25
|
-
}) : (function(o, m, k, k2) {
|
|
26
|
-
if (k2 === undefined) k2 = k;
|
|
27
|
-
o[k2] = m[k];
|
|
28
|
-
}));
|
|
29
|
-
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
30
|
-
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
31
|
-
}) : function(o, v) {
|
|
32
|
-
o["default"] = v;
|
|
33
|
-
});
|
|
34
|
-
var __importStar = (this && this.__importStar) || (function () {
|
|
35
|
-
var ownKeys = function(o) {
|
|
36
|
-
ownKeys = Object.getOwnPropertyNames || function (o) {
|
|
37
|
-
var ar = [];
|
|
38
|
-
for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
|
|
39
|
-
return ar;
|
|
40
|
-
};
|
|
41
|
-
return ownKeys(o);
|
|
42
|
-
};
|
|
43
|
-
return function (mod) {
|
|
44
|
-
if (mod && mod.__esModule) return mod;
|
|
45
|
-
var result = {};
|
|
46
|
-
if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
|
|
47
|
-
__setModuleDefault(result, mod);
|
|
48
|
-
return result;
|
|
49
|
-
};
|
|
50
|
-
})();
|
|
51
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
52
|
-
exports.BubblewrapSandbox = void 0;
|
|
53
|
-
exports.isSandboxAvailable = isSandboxAvailable;
|
|
54
|
-
exports.getSandboxVersion = getSandboxVersion;
|
|
55
|
-
const child_process_1 = require("child_process");
|
|
56
|
-
const util_1 = require("util");
|
|
57
|
-
const fs = __importStar(require("fs-extra"));
|
|
58
|
-
const path = __importStar(require("path"));
|
|
59
|
-
const os = __importStar(require("os"));
|
|
60
|
-
const logger_1 = require("../utils/logger");
|
|
61
|
-
const execFileAsync = (0, util_1.promisify)(child_process_1.execFile);
|
|
62
|
-
/**
|
|
63
|
-
* Bubblewrap sandbox wrapper for secure genomic data processing
|
|
64
|
-
*/
|
|
65
|
-
class BubblewrapSandbox {
|
|
66
|
-
constructor(config = {}) {
|
|
67
|
-
// Secure defaults for genomic data processing
|
|
68
|
-
this.config = {
|
|
69
|
-
isolateNetwork: config.isolateNetwork ?? true,
|
|
70
|
-
isolatePID: config.isolatePID ?? true,
|
|
71
|
-
isolateIPC: config.isolateIPC ?? true,
|
|
72
|
-
isolateUTS: config.isolateUTS ?? true,
|
|
73
|
-
enableSeccomp: config.enableSeccomp ?? true,
|
|
74
|
-
dropCapabilities: config.dropCapabilities ?? true,
|
|
75
|
-
hostname: config.hostname ?? 'biofs-sandbox',
|
|
76
|
-
workingDir: config.workingDir ?? '/workspace',
|
|
77
|
-
env: config.env ?? {},
|
|
78
|
-
mounts: config.mounts ?? [],
|
|
79
|
-
allowDevices: config.allowDevices ?? true,
|
|
80
|
-
allowProc: config.allowProc ?? true,
|
|
81
|
-
useTmpfs: config.useTmpfs ?? true,
|
|
82
|
-
dieWithParent: config.dieWithParent ?? true,
|
|
83
|
-
newSession: config.newSession ?? true,
|
|
84
|
-
uid: config.uid ?? os.userInfo().uid,
|
|
85
|
-
gid: config.gid ?? os.userInfo().gid,
|
|
86
|
-
};
|
|
87
|
-
}
|
|
88
|
-
/**
|
|
89
|
-
* Check if bubblewrap is available on the system
|
|
90
|
-
*/
|
|
91
|
-
static async isAvailable() {
|
|
92
|
-
try {
|
|
93
|
-
await execFileAsync('which', ['bwrap']);
|
|
94
|
-
return true;
|
|
95
|
-
}
|
|
96
|
-
catch {
|
|
97
|
-
return false;
|
|
98
|
-
}
|
|
99
|
-
}
|
|
100
|
-
/**
|
|
101
|
-
* Get bubblewrap version
|
|
102
|
-
*/
|
|
103
|
-
static async getVersion() {
|
|
104
|
-
try {
|
|
105
|
-
const { stdout } = await execFileAsync('bwrap', ['--version']);
|
|
106
|
-
return stdout.trim();
|
|
107
|
-
}
|
|
108
|
-
catch (error) {
|
|
109
|
-
throw new Error(`Failed to get bubblewrap version: ${error}`);
|
|
110
|
-
}
|
|
111
|
-
}
|
|
112
|
-
/**
|
|
113
|
-
* Execute a command in a sandboxed environment
|
|
114
|
-
*/
|
|
115
|
-
async exec(command, options = {}) {
|
|
116
|
-
if (!await BubblewrapSandbox.isAvailable()) {
|
|
117
|
-
throw new Error('bubblewrap is not installed. Install with: sudo apt-get install bubblewrap');
|
|
118
|
-
}
|
|
119
|
-
const bwrapArgs = await this.buildBwrapArgs(command);
|
|
120
|
-
logger_1.Logger.debug('Executing sandboxed command:', {
|
|
121
|
-
command: command.join(' '),
|
|
122
|
-
config: this.config,
|
|
123
|
-
});
|
|
124
|
-
try {
|
|
125
|
-
const { stdout, stderr } = await execFileAsync('bwrap', bwrapArgs, {
|
|
126
|
-
timeout: options.timeout,
|
|
127
|
-
maxBuffer: options.maxBuffer ?? 10 * 1024 * 1024, // 10MB default
|
|
128
|
-
encoding: 'utf8',
|
|
129
|
-
});
|
|
130
|
-
return {
|
|
131
|
-
stdout,
|
|
132
|
-
stderr,
|
|
133
|
-
exitCode: 0,
|
|
134
|
-
};
|
|
135
|
-
}
|
|
136
|
-
catch (error) {
|
|
137
|
-
logger_1.Logger.error('Sandboxed command failed:', {
|
|
138
|
-
command: command.join(' '),
|
|
139
|
-
error: error.message,
|
|
140
|
-
stderr: error.stderr,
|
|
141
|
-
});
|
|
142
|
-
return {
|
|
143
|
-
stdout: error.stdout || '',
|
|
144
|
-
stderr: error.stderr || error.message,
|
|
145
|
-
exitCode: error.code || 1,
|
|
146
|
-
};
|
|
147
|
-
}
|
|
148
|
-
}
|
|
149
|
-
/**
|
|
150
|
-
* Build bubblewrap argument array from config
|
|
151
|
-
*/
|
|
152
|
-
async buildBwrapArgs(command) {
|
|
153
|
-
const args = [];
|
|
154
|
-
// Essential system mounts (read-only)
|
|
155
|
-
args.push('--ro-bind', '/usr', '/usr');
|
|
156
|
-
args.push('--ro-bind', '/lib', '/lib');
|
|
157
|
-
if (await fs.pathExists('/lib64')) {
|
|
158
|
-
args.push('--ro-bind', '/lib64', '/lib64');
|
|
159
|
-
}
|
|
160
|
-
if (await fs.pathExists('/bin')) {
|
|
161
|
-
args.push('--ro-bind', '/bin', '/bin');
|
|
162
|
-
}
|
|
163
|
-
if (await fs.pathExists('/sbin')) {
|
|
164
|
-
args.push('--ro-bind', '/sbin', '/sbin');
|
|
165
|
-
}
|
|
166
|
-
// /proc filesystem
|
|
167
|
-
if (this.config.allowProc) {
|
|
168
|
-
args.push('--proc', '/proc');
|
|
169
|
-
}
|
|
170
|
-
// /dev devices
|
|
171
|
-
if (this.config.allowDevices) {
|
|
172
|
-
args.push('--dev', '/dev');
|
|
173
|
-
}
|
|
174
|
-
// Temporary filesystem for /tmp
|
|
175
|
-
if (this.config.useTmpfs) {
|
|
176
|
-
args.push('--tmpfs', '/tmp');
|
|
177
|
-
}
|
|
178
|
-
// Custom mounts
|
|
179
|
-
for (const mount of this.config.mounts) {
|
|
180
|
-
const mountFlag = mount.readonly ? '--ro-bind' : '--bind';
|
|
181
|
-
const resolvedSource = path.resolve(mount.source);
|
|
182
|
-
// Verify source exists
|
|
183
|
-
if (!await fs.pathExists(resolvedSource)) {
|
|
184
|
-
throw new Error(`Mount source does not exist: ${resolvedSource}`);
|
|
185
|
-
}
|
|
186
|
-
args.push(mountFlag, resolvedSource, mount.target);
|
|
187
|
-
}
|
|
188
|
-
// Working directory
|
|
189
|
-
if (this.config.workingDir) {
|
|
190
|
-
args.push('--chdir', this.config.workingDir);
|
|
191
|
-
}
|
|
192
|
-
// Network isolation
|
|
193
|
-
if (this.config.isolateNetwork) {
|
|
194
|
-
args.push('--unshare-net');
|
|
195
|
-
}
|
|
196
|
-
// PID isolation
|
|
197
|
-
if (this.config.isolatePID) {
|
|
198
|
-
args.push('--unshare-pid');
|
|
199
|
-
}
|
|
200
|
-
// IPC isolation
|
|
201
|
-
if (this.config.isolateIPC) {
|
|
202
|
-
args.push('--unshare-ipc');
|
|
203
|
-
}
|
|
204
|
-
// UTS isolation (hostname)
|
|
205
|
-
if (this.config.isolateUTS) {
|
|
206
|
-
args.push('--unshare-uts');
|
|
207
|
-
args.push('--hostname', this.config.hostname);
|
|
208
|
-
}
|
|
209
|
-
// User namespace
|
|
210
|
-
args.push('--unshare-user');
|
|
211
|
-
args.push('--uid', this.config.uid.toString());
|
|
212
|
-
args.push('--gid', this.config.gid.toString());
|
|
213
|
-
// Drop capabilities
|
|
214
|
-
if (this.config.dropCapabilities) {
|
|
215
|
-
args.push('--cap-drop', 'ALL');
|
|
216
|
-
}
|
|
217
|
-
// Seccomp filter
|
|
218
|
-
if (this.config.enableSeccomp) {
|
|
219
|
-
// Create temporary seccomp filter file
|
|
220
|
-
const seccompFilter = await this.createSeccompFilter();
|
|
221
|
-
args.push('--seccomp', '3');
|
|
222
|
-
// TODO: Pass seccomp filter via fd 3
|
|
223
|
-
}
|
|
224
|
-
// Die with parent
|
|
225
|
-
if (this.config.dieWithParent) {
|
|
226
|
-
args.push('--die-with-parent');
|
|
227
|
-
}
|
|
228
|
-
// New session
|
|
229
|
-
if (this.config.newSession) {
|
|
230
|
-
args.push('--new-session');
|
|
231
|
-
}
|
|
232
|
-
// Environment variables
|
|
233
|
-
for (const [key, value] of Object.entries(this.config.env)) {
|
|
234
|
-
args.push('--setenv', key, value);
|
|
235
|
-
}
|
|
236
|
-
// Command separator
|
|
237
|
-
args.push('--');
|
|
238
|
-
// Actual command to execute
|
|
239
|
-
args.push(...command);
|
|
240
|
-
return args;
|
|
241
|
-
}
|
|
242
|
-
/**
|
|
243
|
-
* Create seccomp filter for syscall restrictions
|
|
244
|
-
*
|
|
245
|
-
* Allows safe syscalls for file I/O, memory management, and process control
|
|
246
|
-
* Blocks dangerous syscalls like ptrace, mount, kexec, etc.
|
|
247
|
-
*/
|
|
248
|
-
async createSeccompFilter() {
|
|
249
|
-
// TODO: Implement seccomp BPF filter
|
|
250
|
-
// For now, bubblewrap's default filter is sufficient
|
|
251
|
-
return '';
|
|
252
|
-
}
|
|
253
|
-
/**
|
|
254
|
-
* Create a pre-configured sandbox for genomic file download
|
|
255
|
-
*/
|
|
256
|
-
static forDownload(outputDir) {
|
|
257
|
-
return new BubblewrapSandbox({
|
|
258
|
-
isolateNetwork: false, // Need network for S3/IPFS
|
|
259
|
-
isolatePID: true,
|
|
260
|
-
isolateIPC: true,
|
|
261
|
-
mounts: [
|
|
262
|
-
{ source: outputDir, target: '/output', readonly: false },
|
|
263
|
-
{
|
|
264
|
-
source: path.join(os.homedir(), '.genobank/credentials.json'),
|
|
265
|
-
target: '/credentials.json',
|
|
266
|
-
readonly: true,
|
|
267
|
-
},
|
|
268
|
-
],
|
|
269
|
-
workingDir: '/output',
|
|
270
|
-
});
|
|
271
|
-
}
|
|
272
|
-
/**
|
|
273
|
-
* Create a pre-configured sandbox for genomic file upload
|
|
274
|
-
*/
|
|
275
|
-
static forUpload(inputPath, tempDir) {
|
|
276
|
-
return new BubblewrapSandbox({
|
|
277
|
-
isolateNetwork: false, // Need network for S3
|
|
278
|
-
isolatePID: true,
|
|
279
|
-
isolateIPC: true,
|
|
280
|
-
mounts: [
|
|
281
|
-
{ source: inputPath, target: '/input', readonly: true },
|
|
282
|
-
{ source: tempDir, target: '/temp', readonly: false },
|
|
283
|
-
{
|
|
284
|
-
source: path.join(os.homedir(), '.genobank/credentials.json'),
|
|
285
|
-
target: '/credentials.json',
|
|
286
|
-
readonly: true,
|
|
287
|
-
},
|
|
288
|
-
],
|
|
289
|
-
workingDir: '/temp',
|
|
290
|
-
});
|
|
291
|
-
}
|
|
292
|
-
/**
|
|
293
|
-
* Create a pre-configured sandbox for local file processing (no network)
|
|
294
|
-
*/
|
|
295
|
-
static forProcessing(inputPath, outputDir) {
|
|
296
|
-
return new BubblewrapSandbox({
|
|
297
|
-
isolateNetwork: true, // NO NETWORK - prevent exfiltration
|
|
298
|
-
isolatePID: true,
|
|
299
|
-
isolateIPC: true,
|
|
300
|
-
mounts: [
|
|
301
|
-
{ source: inputPath, target: '/data/input', readonly: true },
|
|
302
|
-
{ source: outputDir, target: '/data/output', readonly: false },
|
|
303
|
-
],
|
|
304
|
-
workingDir: '/data',
|
|
305
|
-
});
|
|
306
|
-
}
|
|
307
|
-
/**
|
|
308
|
-
* Create a pre-configured sandbox for research job execution
|
|
309
|
-
*/
|
|
310
|
-
static forJob(jobConfig) {
|
|
311
|
-
const mounts = jobConfig.inputs.map((input, index) => ({
|
|
312
|
-
source: input,
|
|
313
|
-
target: `/data/input/${index}`,
|
|
314
|
-
readonly: true,
|
|
315
|
-
}));
|
|
316
|
-
mounts.push({
|
|
317
|
-
source: jobConfig.outputDir,
|
|
318
|
-
target: '/data/output',
|
|
319
|
-
readonly: false,
|
|
320
|
-
});
|
|
321
|
-
return new BubblewrapSandbox({
|
|
322
|
-
isolateNetwork: !jobConfig.allowNetwork,
|
|
323
|
-
isolatePID: true,
|
|
324
|
-
isolateIPC: true,
|
|
325
|
-
mounts,
|
|
326
|
-
workingDir: '/data',
|
|
327
|
-
});
|
|
328
|
-
}
|
|
329
|
-
}
|
|
330
|
-
exports.BubblewrapSandbox = BubblewrapSandbox;
|
|
331
|
-
/**
|
|
332
|
-
* Convenience function to check if sandboxing is available
|
|
333
|
-
*/
|
|
334
|
-
async function isSandboxAvailable() {
|
|
335
|
-
return BubblewrapSandbox.isAvailable();
|
|
336
|
-
}
|
|
337
|
-
/**
|
|
338
|
-
* Convenience function to get sandbox version info
|
|
339
|
-
*/
|
|
340
|
-
async function getSandboxVersion() {
|
|
341
|
-
return BubblewrapSandbox.getVersion();
|
|
342
|
-
}
|
|
343
|
-
//# sourceMappingURL=bubblewrap.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"bubblewrap.js","sourceRoot":"","sources":["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