PracHub
QuestionsPremiumLearningGuidesCheatsheetNEWCoaches
|Home/System Design/Google

Design key management service

Last updated: Mar 29, 2026

Quick Overview

This question evaluates system design and security competencies—specifically cryptographic key lifecycle management, HSM integration, access control, auditing, multi-tenant isolation, and scalability—within the System Design domain.

  • hard
  • Google
  • System Design
  • Software Engineer

Design key management service

Company: Google

Role: Software Engineer

Category: System Design

Difficulty: hard

Interview Round: Technical Screen

Design a key management service where a client provides a key ID and receives the corresponding key material. Specify APIs, key generation and storage (HSM versus software), access control, auditing, key rotation, usage limits, and security and threat model. Discuss latency, availability, and blast radius of compromise.

Quick Answer: This question evaluates system design and security competencies—specifically cryptographic key lifecycle management, HSM integration, access control, auditing, multi-tenant isolation, and scalability—within the System Design domain.

Related Interview Questions

  • Design an Online Coding Judge Platform - Google (medium)
  • Design a pub-sub replay system - Google (hard)
  • How to host many domains on one IP? - Google (medium)
  • Design street-view image ingestion and storage system - Google (hard)
  • Design a global real-time notification system - Google (medium)
Google logo
Google
Sep 6, 2025, 12:00 AM
Software Engineer
Technical Screen
System Design
3
0

Design a Key Management Service (KMS)

You are asked to design a production-grade, multi-tenant Key Management Service. A client provides a key identifier (ID) and receives the corresponding key material or a cryptographic service backed by that key.

Assume this is for a large-scale environment with strict security, availability, and latency requirements.

Requirements

  1. APIs
    • Define APIs to create/manage keys and to use keys (e.g., encrypt/decrypt, sign/verify, generate data keys).
    • Support key identifiers, versions, and idempotency.
  2. Key Generation and Storage
    • Describe how keys are generated (entropy, algorithms) and where they are stored (HSM vs. software).
    • Address import/bring-your-own-key (BYOK) and export policy.
  3. Access Control
    • Specify authentication and authorization models (per-tenant, per-key), including least privilege and policy expressiveness.
  4. Auditing
    • Provide comprehensive audit logging that is tamper-evident.
  5. Key Rotation
    • Support automatic and manual rotation; define key states (enabled, disabled, scheduled for destruction) and versioning semantics.
  6. Usage Limits
    • Define per-key and per-principal quotas, rate limits, and safe usage patterns.
  7. Security and Threat Model
    • Enumerate critical threats and mitigations (insider, external attacker, HSM compromise, replay, downgrade, side-channels).
  8. Latency and Availability
    • State targets/expectations and techniques (caching, envelope encryption, multi-region, failover) to meet them.
  9. Blast Radius of Compromise
    • Discuss isolation boundaries and how to limit impact if a key, service component, region, or HSM is compromised.

Note: Best practice is that master keys never leave the HSM. If requirements demand returning key material, constrain it to explicitly exportable, ephemeral data keys with additional controls.

Solution

Show

Comments (0)

Sign in to leave a comment

Loading comments...

Browse More Questions

More System Design•More Google•More Software Engineer•Google Software Engineer•Google System Design•Software Engineer System Design
PracHub

Master your tech interviews with 7,500+ real questions from top companies.

Product

  • Questions
  • Learning Tracks
  • Interview Guides
  • Resources
  • Premium
  • For Universities
  • Student Access

Browse

  • By Company
  • By Role
  • By Category
  • Topic Hubs
  • SQL Questions
  • Compare Platforms
  • Discord Community

Support

  • support@prachub.com
  • (916) 541-4762

Legal

  • Privacy Policy
  • Terms of Service
  • About Us

© 2026 PracHub. All rights reserved.