Code Room
System designMediumsd-g063
Subject Content deliveryLevel Mid–Senior~35 minCommon in Distributed systems interviewsIndustries Technology, Software development

Question

Design secure content delivery for paid media (e.g., premium audio/video or paid downloads) over a CDN where files are cached at the edge for performance, but access must be restricted to entitled, paying users and must respect geo/license restrictions. The challenge: the edge serves cached bytes without calling your origin, so how do you enforce per-user authorization on a cached object without killing cache efficiency?

What a strong answer looks like

Clarify scale and constraints first. Propose a clean component breakdown, then go deep on the hard parts — data model, bottlenecks, consistency, failure modes — and name the trade-offs you are making.

Narrate your design
Loading whiteboard…
Run or narrate your approach, then ask the coach.