Hacker News new | ask | show | jobs
by kentonv 61 days ago
It's true that V8 isolates are more risky than micro VMs*. However, it's also true that micro VMs are more risky than giving each tenant their own machine.

At some point you have to decide where along the spectrum you want to put the boundary of "acceptable" for your workload.

Some people argue that isolates are below the necessary threshold and micro VMs are above it. But this isn't really based on any rigorous mathematical analysis, it's mostly vibes. It used to be that people said VMs weren't secure enough for critical workloads, but few people say that these days.

I would argue that we (Cloudflare) have demonstrated that the isolate model can work fine if done carefully: we've been doing it this way for nearly a decade with no breaches.

* Not "strictly riskier", though. There are some risks micro VMs have that V8 isolates do not. Micro VMs that allow tenants to run arbitrary x86 code place a huge amount of trust in the hardware to be exactly correct; a trusted JIT makes it much easier to work around hardware bugs when they are found.

2 comments

I'm the original poster that said v8 isolates aren't a great sandbox and I would state that I didn't say they were impossible to use as a sandbox. I know you all at cloudflare are doing a ton on top of v8 isolates to make them secure.

I think as a general rule you'd just want multiple uncorrelated layers of isolation. If you aren't willing to spend what cf does on securing v8 isolates I think process isolation + seccomp + v8 isolates might be enough, otherwise all of our browsers would be ticking time bombs.

I agree! Just to be clear, by "security critical" I mean the tier where you'd also refuse shared VMs. I'm not convinced most people have workloads and threat models that actually need the isolation they say they want, nor a fully considered notion of what their preferred primitive buys them (per your footnote, and any number of other issues I'm completely unaware of). But I like and appreciate Workers, and am grateful to be paying less because Cloudflare bin-packed more.