5 exercises — Practice vocabulary for security architecture patterns: API gateway authentication, secrets manager, vault pattern, defence in depth, and the DMZ.
0 / 11 completed
1 / 11
An architect says: "The API gateway handles authentication for all our microservices." A developer asks why this is done at the gateway level rather than in each service. Which explanation is correct?
The API gateway as authentication boundary is the "perimeter authentication" pattern — enforce identity at the entry point so internal services can focus on their business logic rather than security plumbing.
This pattern is part of the broader "API gateway" security pattern set: the gateway also handles rate limiting (preventing DDoS and abuse), TLS termination (so internal traffic can use lighter protocols), and request logging (centralised audit trail). The internal trust model is the key design decision: after the gateway authenticates the caller, do internal services trust the gateway's forwarded identity header (simpler, requires network-level controls), or does each service re-validate a token (stronger, works across trust domains)? Zero-trust architectures lean toward re-validation; traditional perimeter models lean toward internal trust. The architect's choice should be explicit and documented.
Key vocabulary:
• API gateway — an infrastructure component that handles cross-cutting concerns (authentication, rate limiting, routing) for API traffic
• perimeter authentication — validating identity at the network entry point before requests reach internal services
• zero trust — a security model where no internal network location is inherently trusted; every request is authenticated and authorised
2 / 11
A security engineer explains: "We use a secrets manager to store credentials — nothing sensitive goes in environment variables or config files." Why is this the recommended approach?
Environment variables and config files have a long history of becoming the source of credential leaks — through git commits, debug log output, crash dumps, and container image layers. A secrets manager eliminates these leak vectors.
Common secrets manager implementations: HashiCorp Vault (self-hosted), AWS Secrets Manager, GCP Secret Manager, Azure Key Vault. The "vault pattern" extends this to credential rotation: the secrets manager generates new credentials on a schedule, notifies consuming services, and the old credentials expire. This means even if credentials are exfiltrated, they become invalid quickly. The audit log capability is also crucial for incident response — "which services accessed the production database credentials in the 24 hours before the incident?" is answerable from a secrets manager audit trail, not from environment variables.
Key vocabulary:
• secrets manager — a service that stores, manages access to, and optionally rotates sensitive credentials and configuration
• credential rotation — the automated replacement of credentials on a schedule to limit the window of exposure if they are compromised
• secret sprawl — the anti-pattern where credentials are scattered across config files, environment variables, and source code repositories
3 / 11
An architect describes "the vault pattern for credential rotation." What problem does this pattern solve?
Dynamic, short-lived credentials are the gold standard of secrets management — a stolen credential that expires in an hour has dramatically less value to an attacker than one that is valid indefinitely.
HashiCorp Vault's "dynamic secrets" feature is the canonical implementation: instead of creating a database user with a permanent password, Vault creates a new database user on each request with a 1-hour TTL. The service uses the credential for the duration of its work, and Vault revokes it after TTL expiry. This means: (1) credential dumps (stolen database password files) become largely worthless — the credentials are already expired; (2) credential rotation is continuous and automatic, not a quarterly manual task; (3) every credential issuance is audited, showing exactly which service requested access to which database at what time. The pattern works for any external service (AWS IAM, databases, certificates).
Key vocabulary:
• vault pattern — the architecture of using a centralised secrets manager to issue, rotate, and revoke credentials dynamically
• dynamic secrets — short-lived credentials generated on demand for a specific service and automatically revoked after their TTL
• TTL (time to live) — the duration a credential remains valid before automatic expiry and revocation
4 / 11
An architect describes "defence in depth" as a core security architecture principle. What does this mean in practice?
Defence in depth acknowledges that no single security control is perfect — every control has failure modes, vulnerabilities, or bypass conditions. Layering independent controls ensures that control failures don't produce system failures.
The principle comes from military strategy (multiple defensive lines) but is fundamental to security architecture. In cloud environments, defence in depth is implemented across multiple dimensions: (1) Network: VPC segmentation, security groups, NACLs, WAF; (2) Identity: MFA, short-lived tokens, privileged access management; (3) Data: encryption at rest, encryption in transit, data classification; (4) Application: input validation, output encoding, SAST/DAST; (5) Detection: SIEM, anomaly detection, audit logging. The architecture document should explicitly map threats to their layered controls so gaps are visible and each layer's effectiveness can be evaluated independently.
Key vocabulary:
• defence in depth — the security principle of stacking multiple independent controls so failure of one does not compromise the whole system
• layered security — implementing security controls at multiple architecture levels (network, identity, data, application, monitoring)
• security control — a specific mechanism (firewall rule, encryption, authentication) that reduces a specific security risk
5 / 11
A network architect mentions "the demilitarized zone (DMZ)." A developer who has only worked with cloud infrastructure asks what a DMZ is and whether it applies to cloud architectures. Which explanation is correct?
The DMZ concept translates directly to cloud networking — public subnets accessible from the internet form the DMZ; private subnets accessible only from within the VPC form the internal zone; and the controls between them enforce the trust boundary.
In AWS terms: Public Subnet (DMZ) contains load balancers and NAT gateways — accessible from the internet via Security Groups. Private Subnet (Application Layer) contains EC2 instances or ECS services — not directly internet-accessible, only reachable from the public subnet. Data Subnet (Internal) contains RDS databases and ElastiCache — reachable only from the application layer. Each boundary has explicit Security Group rules defining what traffic is permitted. The DMZ principle limits what an attacker who compromises a public-facing component can do — they can reach the application layer but not jump directly to the database.
Key vocabulary:
• DMZ (demilitarized zone) — a network segment between the public internet and the internal trusted network, hosting public-facing services
• public subnet — the cloud equivalent of a DMZ; resources have internet-routable addresses and can receive inbound traffic
• private subnet — resources are not internet-accessible; reachable only from within the VPC or via explicit routing rules
6 / 11
Sarah (Lead Security Engineer) sends a Slack message to the team: 'We're implementing a centralized logging solution. All services will forward their logs to our ELK stack. This allows us to quickly identify and respond to security incidents.' What is Sarah primarily describing in this message?
Sarah is describing a centralized logging solution – specifically, collecting and analyzing log data. The ELK stack (Elasticsearch, Logstash, Kibana) is commonly used for this purpose. This allows teams to proactively identify security incidents based on event patterns and anomalies, not simply patching vulnerabilities or encrypting data.
7 / 11
Mark (a junior developer) posts this comment on a code review: 'I've added rate limiting to the endpoint. It's set to 10 requests per minute.' David (Senior Developer) replies: 'That's good, but what happens if someone uses an API key?' Which of the following best describes David's concern?
David's concern highlights that rate limiting alone doesn't address authentication. API keys introduce a separate attack vector (e.g., unauthorized access via key manipulation) that needs to be considered alongside rate limits. The core issue is not just the volume of requests but also how those requests are authenticated and authorized.
8 / 11
During a standup meeting, Emily (a developer) says: 'We're using a WAF to protect our web application.' John (Team Lead) asks, 'What does that actually *do*?' Which of the following best describes a Web Application Firewall?
A WAF (Web Application Firewall) acts as a shield between the internet and your application. It inspects HTTP traffic and blocks malicious requests based on rules configured to mitigate common web vulnerabilities – like SQL injection or XSS. This is distinct from database management systems or simply monitoring performance.
9 / 11
A PR description reads: 'Implemented OAuth 2.0 authorization flow for user authentication.' Liam (Security Engineer) comments: 'Ensure you're using the latest best practices for token storage and rotation to minimize risk.' What is Liam primarily advising?
While implementing OAuth 2.0 correctly is important, the security of tokens and their rotation are critical best practices. Tokens can be compromised if not properly managed – rotating them reduces the window of opportunity for attackers to exploit stolen credentials. This aligns with a defense-in-depth approach.
10 / 11
Alex (a developer) is discussing security architecture with Ben (an architect). Ben says: 'We're using the 'least privilege' principle. Each service only has access to the resources it absolutely needs.' What does this mean in practical terms?
The principle of least privilege dictates that each component (service, user) should only have the minimum level of access required to perform its intended function. This limits the blast radius if a service is compromised – attackers can't leverage elevated privileges to move laterally across the system. It's about minimizing potential damage.
11 / 11
During a Slack conversation, Chloe (a DevOps engineer) asks: 'Our new microservice needs to access a database. Should we use a VPN?' Mark (Security Architect) responds: 'It depends on the sensitivity of the data and network traffic. A DMZ could be an option.' What is a DMZ in this context?
A DMZ (Demilitarized Zone) creates a buffer zone between an internal network and the public internet. Services placed in the DMZ are accessible from the outside world but are isolated from the sensitive resources of the internal network – reducing the attack surface. It's a key element of layered security.
What will I learn from the "Security Pattern Vocabulary — Security Architecture Language | CoderLingo" exercise?
5 advanced exercises practising security architecture pattern vocabulary — API gateway authentication, secrets manager, vault pattern, defence in depth, and DMZ.
Is this exercise free to use?
Yes. Every exercise on CoderSlingo, including this one, is free to use with no account, sign-up, or paywall required.
How many questions are in this exercise?
This set contains 11 multiple-choice questions, each with a detailed explanation shown after you answer.
Do I need to create an account to track my progress?
No account is required. Your progress bar and score reset each time you reload the page, but you can retry the exercise as many times as you like.
Who is this Security Architecture Language exercise for?
This exercise is built for IT professionals and non-native English speakers who need to read, write, and discuss security architecture language topics confidently at work.
What happens if I answer a question incorrectly?
You will see the correct answer highlighted along with a detailed explanation of why it is correct -- so every wrong answer becomes a learning moment, not just a lost point.
Can I retry this exercise?
Yes -- click "Try again" on the results screen at any time to reset your score and go through all the questions again.
How long does this exercise take to complete?
Most learners finish all 11 questions in under 10 minutes, since each question is answered by clicking a single option.
Where can I find more Security Architecture Language exercises?
See the full Security Architecture Language exercises hub for more vocabulary drills on this topic.
Is this exercise mobile-friendly?
Yes -- the exercise works on any device with a modern browser, including phones and tablets, with no app download required.