Security Notes
System Design

Approaching Open-Ended Security System Design in Technical Interviews

26 min read 15 sections 7 model answers verified 2026-10 version 1 · updated 2026-10-24

Last verified2026-10 Also see: Secure multi-tenant CI runner platform (the full worked design this page's example points at) · Mock: threat-model a privileged node agent (a worked hour on a narrower prompt) · Threat modelling (STRIDE, data-flow diagrams) · System design foundations (the generic 30-minute framework and the numbers) · Sandbox isolation


Start here: the basics in plain words

An open-ended design question is one with no answer key. "Design a platform that runs untrusted code." "Secure our build cluster." "We want engineers to SSH into production; make it safe." The interviewer has a system in mind, usually one they operate, and wants to watch you turn a vague sentence into a defensible architecture in under an hour, out loud, while they poke at it.

You are not being graded on the final diagram. You are being graded on the process: whether you ask before you build, whether you can draw a trust boundary and say what crosses it, whether you rank threats instead of listing them, whether you name the cost of each control, and whether you can be told "that won't work" without falling apart.

Trust boundary

A line on the diagram where the level of trust changes: a request from the internet entering your API, customer code entering your runner, a job's packet leaving for the network. Every boundary needs an "and what checks that?" answer.

Threat model

The structured answer to "who attacks whom, through what, to get what". Not a list of scary words; a table with an attacker, a target, a path and a control.

Blast radius

What is lost when one specific thing fails or is compromised. The number you minimise: one job, one host, one tenant, the whole fleet.

Trade-off

Every control costs latency, money, developer friction or operational load. Saying the cost out loud is the difference between a list and a design.

Signposting

Telling the interviewer where you are in the process and where you are going next. It lets them steer you early instead of letting you run into a wall for ten minutes.

Fail-closed

When a control breaks, the system refuses rather than allows. The default for security controls; the thing you must explicitly justify when you choose fail-open.

Memory hook

scope, sketch, boundaries, threats, controls, costs, summary. Seven words, roughly eight minutes each. If you can say where you are in that list at any moment, you are in control of the interview.


What is this?

A method for the hour: eight phases with timings, the questions to ask in each, what to say out loud, and how to recover when the interviewer challenges you. It is deliberately mechanical. Under pressure, mechanical is what survives.

Why it matters

Candidates with strong knowledge fail these interviews in predictable ways: they start listing controls before they know the system, they draw every box but no boundaries, they treat the first pushback as a verdict, or they run out of time with no summary. Interviewers at companies that run untrusted code at scale (CI platforms, code-execution sandboxes, agent runtimes) use exactly this format because the job is exactly this: ambiguous requirements, hostile input, real hardware, no answer key.


The framework

  1. Phase 1 · 0–5 min · Clarify the promptbrowserscope before design
    • Restate in one sentence; ask 3–4 questions whose answers change the architecture
  2. Phase 2 · 5–10 min · Assumptions and constraintsdnssay what you are assuming
    • Hardware, scale, tenancy, compliance, what "secure" means for this interviewer
  3. Phase 3 · 10–20 min · Baseline designserverthe boring version first
    • Control plane vs data plane, the request or job lifecycle, the boxes and arrows
  4. Phase 4 · 20–30 min · Trust boundaries and threatsattackwho attacks whom
    • Draw the lines; walk STRIDE across each; produce a ranked table
  5. Phase 5 · 30–45 min · Controls, rankeddefendbiggest blast radius first
    • Go deep on two or three; name the rest
  6. Phase 6 · 45–52 min · Trade-offs and failure modesrenderwhat it costs, how it fails
    • Latency, money, friction; fail-open vs fail-closed; what breaks when a control breaks
  7. Phase 7 · throughout · Narrative controltlssignpost, check alignment, drive the board
  8. Phase 8 · when it happens · Recover when stuck or challengedosisolate the assumption, pivot

Phase 1: Clarify the prompt and define scope

What is this?The first five minutes decide whether you design the right system. The prompt is deliberately vague; the interviewer has answers to questions you have not asked yet.

How it worksRestate the prompt in one sentence that names the untrusted input and the valuable thing it is near. Then ask only questions whose answers would change your design. Three or four is right; eight is stalling.

The question bank, grouped by what each answer changes:

Who is the user, and who is the attacker?

"Are jobs from our own engineers, from customers, or from anyone who can open a pull request?" Changes the whole isolation tier.

What is shared?

"Do two customers' workloads run on the same machine at the same time?" Changes sandbox choice and side-channel posture.

What must it reach?

"Does a job need the internet, our internal network, the customer's network, cloud APIs?" Changes egress design and identity.

What hardware, and where?

"Bare-metal we own, cloud, both? Any macOS?" Changes the virtualisation story and whether cloud metadata is a threat.

What scale and latency?

"Jobs per day, how long, how fast must one start?" Changes whether you can afford a VM per job and whether you pool.

What does 'secure' mean here?

"Is the fear a tenant reading another tenant, a tenant reaching our prod, or us being blamed for a customer's supply-chain compromise?" Changes what you rank first.

What exists today?

"Is there a current system I am hardening, or is this greenfield?" Changes whether you propose migration steps.

Compliance and audit?

"Any requirement that we prove what ran, or keep logs for a period?" Changes provenance and logging design.

In practiceWhat you would say, for the prompt "secure our multi-tenant build cluster that runs untrusted code":

text
"Let me restate: we run other people's code, including strangers' pull requests, on shared hardware that also
has routes to things we care about. I want to bound what a job can reach, keep and impersonate.
Before I draw anything:
  1. Are the workloads from GitHub Actions and Buildkite, or our own API too?           ← token model
  2. Do tenants share hosts concurrently, or can I dedicate?                              ← sandbox tier, side channels
  3. Do jobs need to reach anything private: our network, customer VPCs, cloud APIs?      ← egress and identity
  4. What is the hardware: Linux racks, cloud, Apple Silicon for macOS builds?             ← virtualisation choices
I'll assume answers where you don't have them and say so."
🎯

On the job. This is the same conversation you have at the start of a real design review. The engineer who asks "who can submit a job?" before "which sandbox?" is the one whose design survives contact with the product.


Phase 2: Assumptions and constraints

What is this?Whatever the interviewer did not answer, you decide, out loud, so your design can be judged against your assumptions rather than against theirs.

How it worksState the baseline in one breath: the hardware, the scale, the trust model, the budget for latency. Write it in the corner of the board; you will point at it later when you defend a trade-off.

In practice

text
Assumptions (say them, write them):
  hardware   bare-metal Linux racks (AMD EPYC x86-64, AmpereOne arm64), Apple Silicon hosts for macOS via Apple's vz
             framework (two guests per host max), burst capacity in AWS and GCP
  scale      ~1M jobs/day, mean 6 min, p95 30 min → ~4k concurrent, plan 12k burst
  trust      every job is hostile; a PR from a fork is a stranger's code with root inside its sandbox
  must reach public registries, GitHub, optionally a customer-declared allowlist; never our internals or cloud metadata
  budget     sandbox start under 1 s on Linux; macOS pooled; 5–10 % CPU overhead acceptable for isolation
  failure    security controls fail closed; a down egress proxy means jobs wait, not jobs bypass

If the interviewer corrects an assumption, thank them and change it; that is the system working.


Phase 3: Baseline design

What is this?The boring version of the system, drawn before any hardening, so there is something to put boundaries on. Candidates who skip this end up hardening boxes that do not exist yet.

How it worksSeparate the control plane (what you trust: API, scheduler, provisioner, token broker, audit sink) from the data plane (what runs untrusted code: hosts, sandboxes, their network). Then narrate one job's life from event to destruction. Name the real components: a Kubernetes cluster or a host agent on bare metal, Firecracker or gVisor or a vz guest per job, BuildKit for image builds, a Go proxy for egress, Buildkite or GitHub Actions as the job source.

         control plane (trusted)                       data plane (assume compromised)
   webhook → scheduler → provisioner → token broker    host agent → sandbox per job → egress proxy → internet
                                   └→ audit/provenance sink  ◄──────── logs, write-only from jobs

Say the lifecycle in eight steps: event, schedule, mint identity, provision, run, egress, collect, destroy. Each step is a place a boundary will go in the next phase.

In practiceThe sentence that shows you know what you drew:

text
"Everything left of this line never executes customer code. Everything right of it I assume is compromised at
any given moment, so every arrow from right to left is a boundary I'll come back to.   ← the interviewer now knows your model

Phase 4: Trust boundaries and adversarial threat modelling

What is this?The phase that separates security design from system design. You draw the lines where trust changes and walk attacks across each one, producing a ranked table rather than a brainstorm.

How it works

Draw the boundaries

internet to control plane; control plane to host; host to sandbox; sandbox to network; sandbox to storage (caches, artifacts); human to anything (break-glass).

Walk STRIDE across each boundary

(Spoofing, Tampering, Repudiation, Information disclosure, Denial of service, Elevation of privilege). You do not need all six at every line; you need the two or three that matter.

Name attacker, target, path, impact

then rank by blast radius.

In practiceThe table you build on the board, for the build cluster:

text
 #  attacker → target             path                                   blast radius        rank
 1  job → host kernel             syscall bug, runc/BuildKit escape      every tenant on host  1
 2  job → control plane           network route + auth bug               whole platform        1
 3  job → other tenant            shared cache, shared segment, SMT      one tenant            2
 4  job → cloud account           IMDS from a cloud-burst sandbox        cloud account         2
 5  job → customer cloud          over-broad OIDC trust policy           one customer          3
 6  PR job → release build        poisoned cache restored by trusted job one tenant's releases 2
 7  human → node                  break-glass shell lands on the host    every tenant on host  2
 8  platform → customer           we alter or misattribute artifacts     reputation, all       3

The ranking is the point. Two boundaries get the deep dives; the rest get a sentence each.

📰

Real incident — Capital One (2019). The pieces you need to know. A web application firewall ran on a cloud virtual machine. Cloud VMs can ask a local metadata service, at a fixed link-local address, for temporary credentials belonging to the VM's assigned role. Server-side request forgery (SSRF) is when an attacker makes a server fetch a URL of the attacker's choosing. What went wrong. A misconfiguration let an outsider make the firewall host fetch the metadata address. The response was the role's credentials; the role had permission to list and read storage buckets. Roughly a hundred million customer records were copied out. Why it's bad. Nothing was "hacked" in the exploit sense. A request crossed one trust boundary (internet to firewall) and was relayed across a second (host to metadata service) that nobody had drawn, and the credential on the far side was far broader than the host needed. The lesson for this interview. When you draw "sandbox to network", ask what else is on that network. The metadata service is the classic undrawn boundary; a job in cloud burst capacity that can reach it has the instance's identity. Draw it, block it at the datapath, give the instance no useful role, and require the metadata service's hop-limited mode so the answer cannot be forwarded.

🎯

On the job. The threat table is the artefact that outlives the meeting. In a real review it becomes the list of controls with owners; in the interview it is the thing you point at when the interviewer asks "why that first?" and you answer "because row one is every tenant on the host".


Phase 5: Technical controls and defence in depth

What is this?Now, and only now, the controls. Ranked by the table, with two or three explored deeply and the rest named so the interviewer knows you know they exist.

How it worksFor each control say three things: what it bounds, what layer it lives at, and what it costs. Depth is a second sentence about mechanism; a third sentence about how it fails.

Runtime isolation

A VM per job (Firecracker on the Linux racks, a vz guest on Apple Silicon) gives each job a sacrificial kernel; gVisor inside the Linux VM adds a second wall around the Docker build step. Bounds rows 1 and 3. Costs a few percent CPU, more on I/O.

Control-plane unreachability

The host agent calls out to the control plane over mutual TLS; nothing in the job network can open a connection inward. Bounds row 2. Costs nothing but discipline.

Workload identity

Single-use runner registration minted by a broker; jobs get OIDC tokens describing themselves and exchange them for minutes-long cloud credentials pinned to immutable repository IDs. Bounds rows 5 and 8. Costs customer onboarding effort.

Egress policy

Datapath allows only the proxy; the proxy allowlists host names per job and logs every connection; tenants get dedicated egress IP pools. Bounds rows 4 and 6 partly, and catches exfiltration. Costs: fail-closed means a proxy outage is a platform outage.

Cache partitioning

Tenant, repository, trust class; content-addressed entries with a controller-signed manifest; per-job cache credentials. Bounds row 6. Costs cache hit rate.

Break-glass inside the sandbox

On-demand sshd inside the job's VM, SSH certificates minted per session, unique OS user, recorded. Bounds row 7. Costs a slower debug path than "ssh to the node".

Provenance from the controller

The controller, not the job, signs what ran, from what source, in which image, fetching what. Bounds row 8 and meets SLSA Build L3's separation rule. Costs a controller that must observe every input.

Automated TLS for platform endpoints

certmagic or equivalent issuing certificates for internal endpoints so there is never a long-lived wildcard key on a host. Small, but interviewers notice when the boring parts are right.

In practiceGoing deep on one, the way the interviewer wants to hear it:

text
"Row one first: job to host kernel. The control is a VM per job. On the EPYC and AmpereOne hosts that's a
Firecracker microVM booted from a read-only golden image with a per-job scratch disk and a per-job tap device.
Mechanism: the job's syscalls hit the guest kernel; reaching the host means a second bug in the VMM or KVM,
and Firecracker's jailer runs the VMM as an unprivileged user in a chroot with seccomp, so even that is bounded.
Failure: if someone ships a privileged pod or a hostPath for convenience, the wall is gone, so admission policy
on the cluster rejects those outright; and if the VMM has a bug we treat the host as compromised, drain it,
and re-image, which is why hosts are immutable in the first place.
Cost: a few percent of CPU, more for small-file I/O; I'd offer bigger VMs rather than weaker isolation."

That is four sentences, each doing a job: what, how, how it fails, what it costs.


Phase 6: Trade-offs, failure modes and blast radius

What is this?The phase that proves you have operated something. Every control you named has a cost and a way to break; say both before you are asked.

How it worksWalk your controls and for each ask "what happens when this is down, and what happens when this is wrong?"

ControlWhen it is downWhen it is wrongDecision
Egress proxyJobs cannot fetch; platform stallsAllowlist too broad: exfiltration pathFail closed; proxy per rack; alert on denies
Token brokerNo new jobs startOver-scoped token: cross-job accessFail closed; short lifetimes make "wrong" short-lived
VM per jobCapacity drops to zero on that hostEscape: host compromisedImmutable hosts, drain and re-image; second wall inside
Cache signingEvery restore misses; builds slowKey reachable from a job: poisonSigner outside the job; misses are acceptable, poison is not
ProvenanceReleases blocked by the verifierController lies: undetectable from insideReproducible builds let a customer rebuild and compare
Break-glassEngineers cannot debugShell reaches the hostsshd lives inside the VM; there is no host path to grant

Then the two sentences every interviewer waits for: "This fails closed, and here is what that costs." And: "The blast radius of the worst realistic failure is one tenant's jobs on one host for the minutes until drain, not the fleet."

🎯

On the job. The real trade-off meetings are about hit rates and startup latency, not kernels. A design whose only argument is "it's more secure" loses to the team that ships faster. Bring the number: "a VM per job costs us 6 % CPU and 300 ms start; a shared kernel costs us every tenant on the host when runc has its next CVE."


Phase 7: Narrative control and thinking out loud

What is this?The meta-skill: making your process visible so the interviewer can follow it, steer it and credit it.

How it works

Signpost phase changes.

"That's scope; I'll state assumptions now, then draw the baseline." It costs five seconds and prevents the interviewer from wondering whether you have a plan.

Narrate decisions, not just conclusions.

"I'm choosing a VM per job rather than gVisor alone because the threat is a stranger's root code and I want a sacrificial kernel" beats "we'll use Firecracker".

Check alignment at boundaries.

"Before I go deep on egress, is that where you'd like me to spend time, or is identity more interesting for you?" They will tell you, and you have just saved ten minutes.

Own the board.

Draw the diagram yourself, label the boundaries, write the threat table. The interviewer should be looking at your structure, not theirs.

Keep a visible parking lot.

When a tangent appears ("what about GPU jobs?"), write it in the corner and say you will return to it if time allows. It shows control without dismissing the question.

Use the clock.

Say "I have about fifteen minutes; I'll do two deep dives and then trade-offs" at the half-way mark.

In practicePhrases that do the work:

text
"Let me restate where we are: scope and assumptions done, baseline drawn, I've ranked eight threats and I'm
about to go deep on the top two. Shout if you'd rather I take a different one."
"I'm going to make a call here and move on: VM per job. I'll justify it in trade-offs."
"Parking that; it's a good question and it changes the macOS story. Back to egress."

Phase 8: Recovering when stuck or challenged

What is this?The interviewer will push: "that won't work", "we tried that", "what if the proxy is compromised?". This is not a verdict. It is the part of the interview where they find out whether you can debug your own design.

How it worksThe move is always the same: find the assumption the challenge breaks, say it, and redesign from there.

"That won't work here."

Ask which assumption is wrong. "Is it the two-guests-per-host limit, or the start latency?" Then redesign that one piece, not the whole system.

"What if X is compromised?"

Treat it as a new row in the threat table. "If the proxy is compromised, the attacker has the allowlists and the logs; they can't reach the control plane because the proxy has no inbound route to it either; the blast radius is exfiltration from jobs on that rack until we detect and rotate." Then name the detection.

"Why not Y instead?"

Give Y its due, then the deciding factor. "gVisor alone would be faster to start and cheaper on I/O; the deciding factor is that a Sentry bug is a host compromise, and our tenants are strangers."

"You're running out of time."

Jump to summary. A complete summary of a partial design scores better than a partial deep dive with no summary.

You realise you were wrong

Say it in one sentence and fix it. "I said hostNetwork was fine for the agent; it isn't, it bypasses the egress datapath. Removing it." Interviewers score the correction.

Blank

Go back to the table. "Let me re-read the threat ranking and pick the next row." The structure is there precisely for this moment.

Interviewer gives a new fact

Thank them, write it in assumptions, say what it changes. "Cloud burst means IMDS is in scope; adding a datapath drop and hop-limit on the instance side."

In practiceA real exchange, and the recovery:

text
Interviewer: "Your egress proxy does hostname allowlists. A build runs `npm install`, and a dependency's
              postinstall script talks to a CDN that also hosts the attacker's bucket. Now what?"

You:  "Right: the allowlist is by host name, and a shared CDN host name can front both. So host-name allowlists
       are not a complete control for CDN-hosted destinations; I had assumed registries were distinct hosts.
       Two moves. First, for the registries we care about we mirror them internally, so the allowlist points
       at our mirror and the CDN isn't needed at build time. Second, where the CDN is unavoidable I treat
       it as a logged, rate-limited path and rely on the next layer: the credentials in that job are minutes
       long and scoped to that job, so what leaks is worth little. I'll add 'shared CDN hostnames' as a row
       in the threat table with 'mirror plus short-lived credentials' as the control."    ← assumption named, control adjusted, table updated
🎯

On the job. This exact loop is a production incident review: a control was assumed to cover a case, it did not, you name the gap, you add a layer. Candidates who can do it calmly in the interview are the ones who do it calmly at three in the morning.


The hour, compressed: a worked example

The prompt: "Secure a heterogeneous, multi-tenant build cluster running untrusted arbitrary code." The full design is on the multi-tenant CI runner platform page; this is the shape of the hour.

  1. 0–5 · Restate and askbrowser"strangers' code with root near things we care about"
    • Sources (GitHub/Buildkite/own API)? Shared hosts? What must jobs reach? Hardware incl. macOS?
  2. 5–10 · AssumednsEPYC + AmpereOne racks, Apple Silicon vz, cloud burst; ~4k concurrent; every job hostile; fail closed
  3. 10–20 · Baselineservercontrol plane (API, scheduler, provisioner, broker, audit) vs data plane (host agent, sandbox, proxy)
    • Lifecycle: event → schedule → mint identity → provision → run → egress → collect → destroy
  4. 20–30 · Boundaries and threatsattackeight rows, ranked; rows 1 and 2 are "every tenant" or "whole platform"
  5. 30–45 · Controlsdefenddeep: VM per job (+ gVisor for builds), egress datapath + proxy; named: JIT tokens, OIDC with immutable ids, partitioned signed caches, in-VM break-glass, controller-signed provenance
  6. 45–52 · Trade-offsrenderfail-closed proxy, macOS capacity, cache hit rate, isolation overhead, cloud IMDS
  7. 52–60 · Summaryrenderthree invariants (reach, keep, pretend), build order, one question back

In practiceThe summary you end on:

text
"Three invariants. A job can reach only the proxy and its allowlist. A job keeps nothing: VM, disk, tap,
tokens and cache credentials are per-job and destroyed together, verified by the host agent. A job can
pretend to be nothing but itself: single-use registration, OIDC pinned to immutable ids, provenance signed
by the controller. Build order: isolation and immutable hosts, then egress, then the token broker, then
caches, then break-glass, then provenance. If you only let me ship two, it's the first two."

What interviewers actually score

Not a published rubric, but what the feedback forms tend to ask:

Scoping

did they ask the questions that change the design, and stop asking when they had enough?

Structure

could the interviewer tell where the candidate was at every point?

Boundaries

were trust boundaries explicit, and did each have an answer for what crosses it and what checks it?

Prioritisation

did they go deep on what matters, by blast radius, rather than on what they know best?

Depth

on the deep dives, did they reach mechanism and failure mode, not just the name of a tool?

Trade-offs

did they name costs unprompted and make a call?

Resilience

when challenged, did they isolate the assumption and adjust, or defend or collapse?

Communication

did they drive the board, check alignment, and finish with a summary?

🎯

On the job. The same eight items are a good self-review for a design document. If a doc has no explicit boundaries, no ranked threats and no costs, it is a list of tools, and it will be read as one.


Interview Q&A

Q
How do you structure a 45-to-60-minute open-ended security system design interview to guarantee coverage from scoping to deep-dive mitigations?
Model answer

I run eight phases with rough timings and say where I am as I move. Five minutes to restate the prompt and ask three or four questions that change the design, five to state assumptions and constraints, ten to draw the baseline with control plane and data plane and narrate one job's lifecycle, ten to draw trust boundaries and build a ranked threat table, fifteen for controls with two or three deep dives chosen by blast radius, seven for trade-offs and failure modes including what fails closed, and the last five for a summary of invariants and build order plus a question back. Signposting each transition and checking alignment before the deep dives is what guarantees coverage, because the interviewer redirects me early instead of late, and a complete summary of a partial design always beats a partial deep dive with no summary.

Q
What clarifying questions should you ask when tasked with securing a heterogeneous, multi-tenant build cluster running untrusted arbitrary code?
Model answer

Only the ones whose answers change the architecture. Who submits jobs, our engineers or strangers' pull requests, because that sets the isolation tier. Whether tenants share hosts concurrently, because that decides sandbox choice and side-channel posture. What jobs must reach, public registries only or our network, customer networks and cloud APIs, because that decides egress and identity. What the hardware is, bare-metal Linux, cloud, Apple Silicon for macOS, because that decides the virtualisation story and whether cloud metadata is in scope. And what secure means to them, a tenant reading another tenant, a tenant reaching production, or us being blamed for a customer's supply-chain compromise, because that sets what I rank first. Then I state assumptions for anything they leave open and move on.

Q
How do you systematically define trust boundaries between container runtimes like gVisor, hypervisors like Apple's vz, and the underlying bare-metal host?
Model answer

I draw a line wherever the code on one side is trusted differently from the code on the other, then ask what crosses it and what checks it. Job to runtime: the job's syscalls cross to gVisor's Sentry or the guest kernel, so the check is that layer's implementation and its seccomp policy. Runtime to host: the Sentry's host syscalls or the VMM's KVM and virtio operations cross to the host kernel, checked by the Sentry's own seccomp filter or the jailer around the VMM. Guest to macOS host under vz: virtio devices and the framework's entitlements. Host to control plane: the host agent's mutual TLS calls, deliberately one-way. Sandbox to network: the tap device, checked by the datapath rules and the proxy. Naming each crossing and its check is what turns "we use gVisor" into a boundary, and it is what lets me rank which crossing a bug would be worst in.

Q
How do you design a secure identity and token-minting lifecycle using OIDC workload identity, ephemeral runner tokens and unique OS credentials without persistent secret sprawl?
Model answer

The rule is that every credential a job can see is created for that job and dies with it. A broker in the control plane holds the only long-lived secrets, the GitHub app key or the Buildkite cluster token, and uses them to mint a single-use runner registration per job, GitHub's just-in-time config or a Buildkite job acquisition token. Inside the sandbox the runner gets the job token and can request an OIDC token that describes the job, which customers exchange for minutes-long cloud credentials pinned to immutable repository and owner ids rather than names. Cache and artifact credentials are minted per job for that tenant's namespace. For humans, break-glass sessions get an SSH certificate valid for one job and one window, landing in a unique OS account inside the VM. Nothing is written to a config file on a host, so there is nothing to sprawl, and when the VM is destroyed the identities are already expired.

Q
How do you evaluate and defend the trade-offs between hypervisor isolation like Apple's vz and kernel-intercept sandboxing like gVisor on startup latency, throughput and escape risk?
Model answer

I compare them on who answers the job's syscalls and what one bug buys. gVisor answers them in a Go process on the host, which starts in well under a second, costs little for CPU-bound work and a lot for syscall-heavy small-file I/O, and whose worst case is that a Sentry bug is a host compromise. A microVM, Firecracker on Linux or a vz guest on Apple Silicon, gives the job its own kernel, starts in under a second on Linux but tens of seconds on macOS, costs a few percent of CPU and more on I/O through virtio, and whose worst case needs a second bug in the VMM to reach the host. For strangers' root code on shared hardware I defend the VM, and I put gVisor inside it for the Docker build step so the most escape-prone step has two walls. For our own trusted builds I would accept gVisor alone where latency matters, and I say that distinction out loud because it shows the choice is threat-driven rather than reflexive.

Q
How do you specify data-plane egress controls such as custom proxy firewalls and dedicated egress IP pools to mitigate SSRF and credential exfiltration?
Model answer

Specify it in layers with the failure mode of each. At the datapath, the job's interface can reach only the proxy; link-local including the cloud metadata address, private ranges, the control plane and other tenants' segments are dropped. At the proxy, a per-job allowlist of host names resolved by the proxy itself, so a job lying to its own resolver gains nothing, with every connection logged and denies treated as signal. Per tenant, a dedicated egress IP pool so customers can allowlist us without allowlisting everyone. Then I name where it is weak: shared CDN host names front both registries and attackers' buckets, so I mirror the registries I care about and rely on short-lived, job-scoped credentials to make what leaks worthless. SSRF through our own control plane is handled separately by never giving the control plane a route into the job network, and the proxy fails closed, which I state as a cost rather than hide.

Q
What verbal strategies and frameworks do you use to recover your train of thought when an interviewer pokes a hole in your isolation model or says an approach is unfeasible?
Model answer

The same move every time: find the assumption the challenge breaks, say it in one sentence, and redesign that piece. If they say an approach is unfeasible I ask which constraint I got wrong, the macOS guest limit or the start latency, then fix only that. If they ask what happens when something is compromised I treat it as a new row in the threat table, state the blast radius and the detection, and move on. If I realise I was wrong I say so and correct it, because the correction is scored. If I go blank I go back to the ranked table and pick the next row, which is exactly why I built it. And if time is short I jump to the summary of invariants and build order. The framework exists for the moment of pressure; the structure on the board is what I recover into.