Skip to content
  1. Home
  2. workspace
Checking…
Demo view — sanitized data only. Sign in over HTTPS to create projects and manage the workspace.

AI Engineering Workspace

Partial

Chat, files, terminal and preview in one place. Chat sessions run on a durable Postgres-backed queue (chat only: no tools or shell). Live models need an API key; the terminal is unavailable.

Project files

read-only

app/src/lib/crypto.ts

1// AES-256-GCM secret storage. Master key lives outside the repo (0600) and is never returned by any API.
2import crypto from "node:crypto";
3import fs from "node:fs";
4import os from "node:os";
5import path from "node:path";
6
7const KEY_FILE = path.join(os.homedir(), ".config/zoo-cloud-studio/master.key");
8export function masterKey(): Buffer {
9 if (!fs.existsSync(KEY_FILE)) { fs.mkdirSync(path.dirname(KEY_FILE), { recursive: true, mode: 0o700 }); fs.writeFileSync(KEY_FILE, crypto.randomBytes(32).toString("hex"), { mode: 0o600, flag: "wx" }); }
10 return Buffer.from(fs.readFileSync(KEY_FILE, "utf8").trim(), "hex");
11}
12export function encrypt(plain: string) {
13 const iv = crypto.randomBytes(12); const c = crypto.createCipheriv("aes-256-gcm", masterKey(), iv);
14 const ct = Buffer.concat([c.update(plain, "utf8"), c.final()]);
15 return { ciphertext: ct.toString("base64"), iv: iv.toString("base64"), tag: c.getAuthTag().toString("base64") };
16}
17export function decrypt(r: { ciphertext: string; iv: string; tag: string }): string {
18 const d = crypto.createDecipheriv("aes-256-gcm", masterKey(), Buffer.from(r.iv, "base64")); d.setAuthTag(Buffer.from(r.tag, "base64"));
19 return Buffer.concat([d.update(Buffer.from(r.ciphertext, "base64")), d.final()]).toString("utf8");
20}
21export const hintOf = (s: string) => s.length > 10 ? `${s.slice(0, 4)}…${s.slice(-4)}` : "••••";
22

Conversation

Partial
Sign in to start AI sessions.

Task checklist

  • Application shell deployed
  • Persistent projects
  • Agent runtime
  • Sandboxed terminal

Execution activity

No agent sessions. Git HEAD 548ed73 on master.

Approval requests

None pending.