Defense in Depth: How Replit Secures Every Layer of the Vibe Coding Stack
Replit layers its security controls so that no single one is the last line of defense, from development sandboxes to production hosting. Internal services follow zero-trust principles: short-lived tokens and mTLS between service pairs. Sandboxes are seccomp-hardened Linux containers that are being migrated to microVMs, and Determinate Nix keeps dependencies patched. Dev and prod databases are separated with forkable snapshots, and an append-only git sidecar preserves history. A credential-injecting sidecar proxy keeps secrets and MCP OAuth tokens out of app code. Before publish, apps are scanned with combined SAST/SCA and LLM tooling, and each customer gets its own GCP project with Cloud Run and Cloud Armor.
Related posts
- Replit’s Architecture Behind Secure Agent Work
Replit easyNoviceReplit's Agent Habitat secures agent work through four layers: least-privilege connectors with a credential broker that injects vault secrets only into authorized requests, microVM isolation with a hardened kernel, production changes gated behind engineering review and combined static, dependency and AI security scanning, and audit logs that stream to a SIEM. The microVM design blocked exploitation of recently disclosed Linux kernel flaws. Replit also patched affected Node.js, Python and PHP tooling centrally and deployed WAF rules. The post is largely a product overview, with modest architectural detail and a note on planned eBPF-based detection of suspicious agent activity.
- Server-side sandboxing: Containers and seccomp
Figma mediumAdept
Containers and seccomp offer lighter-weight sandboxing than VMs, but both shift much more configuration responsibility onto the user. Container escape risk depends on the runtime implementation, kernel primitives and configuration, and a sandboxed container still needs network, credential and data isolation to limit damage if compromised. Seccomp-only sandboxes suit pure-compute programs: Figma allows only writing to already-open file descriptors, exiting, memory allocation and fetching the time. Building allowlists with strace, restructuring programs so risky syscalls happen before untrusted input is processed, and maintaining brittle allowlists are the main costs, in exchange for very low overhead.
- Server-side sandboxing: An introduction
Figma easyNovice
Server-side workloads like image processing, parsing and thumbnailing often depend on memory-unsafe C++ libraries with histories of exploitable bugs (e.g. ImageTragick), so Figma isolates them with sandboxing rather than relying solely on preventing vulnerabilities. Three primitives are compared at a high level: VMs (Firecracker via AWS Lambda), containers (nsjail using namespaces, cgroups and seccomp), and direct seccomp syscall allowlists built with libseccomp for pure-computation workloads. Seccomp offers strong security and minimal overhead but high upfront development cost, while containers are easier to ship but have more security pitfalls. A questionnaire covering environment, isolation granularity, latency, cost, development effort and operational ownership helps teams choose an approach.
- Zero Trust and Docker Desktop: An Introduction
Docker easyNoviceZero Trust principles from NIST SP 800-207 can be applied to Docker Desktop development environments through host hardening, least privilege, network microsegmentation, strong authentication, monitoring and immutability. Enhanced Container Isolation (ECI) in Hardened Docker Desktop runs even --privileged containers unprivileged, remaps container root via user namespaces, blocks sensitive syscalls and restricts Docker Engine API access. Further controls include bridge/Macvlan networks and air-gapped containers for segmentation, SSO/SCIM plus Registry and Image Access Management for authorization, Docker Scout SBOM-based policy checks, and --read-only root filesystems paired with selective read/write volumes.
- How security and tenant isolation allows Deno Subhosting to run untrusted code securely
Deno easyNoviceDeno Deploy and Deno Subhosting isolate untrusted tenant code using layered defenses mapped to a five-point threat model: per-deployment V8 isolates, a virtualized filesystem, and separate VPCs for ingress and outbound traffic. Each isolate runs in its own process on a restricted Deno runtime, inside Linux namespaces, with seccomp filters to detect unusual syscalls. For resource fairness, cgroups cap CPU, memory and I/O, and an internal WatchDog service kills isolates that exceed memory limits, block the event loop, or show abusive patterns such as crypto mining. The mechanisms are described at a high level, without configuration or implementation specifics.