Design secure architectures

SAA-C03 notes, 30% of the exam, updated November 2026

Security is the largest SAA-C03 domain (30% of scored content). Questions are short scenarios, and nearly all of them come down to one of three things: who is allowed to act, which network path is allowed, or how data is protected. The wrong answers usually work but are less secure, or secure but need more effort than the managed option. When two answers both work, pick the one with temporary credentials, private connectivity and the least privilege.

Shared responsibility and global infrastructure

  • AWS is responsible for security of the cloud: facilities, hardware, the hypervisor, and the managed-service software. You are responsible for security in the cloud: IAM, data, network configuration, guest OS and patching on EC2.
  • The split moves with the service. On EC2 you patch the OS. On RDS, AWS patches the engine and OS, but you still control security groups, parameter settings and who can connect. On Lambda and S3, AWS runs the platform, and you own the code, the permissions and the data.
  • A Region is a separate geographic area with its own resources and data. Data stays in a Region unless you move it, which matters for data residency. An Availability Zone is one or more data centres in a Region. Deploying across at least two AZs is the baseline for any production design. Edge locations serve CloudFront, Route 53 and Global Accelerator, and are not Regions.
  • AWS Artifact gives you AWS’s compliance reports (SOC, PCI, ISO) and lets you accept agreements. It answers “how do I get AWS’s audit report”.

Identity and access management

How IAM decides

AWS evaluates every request against every policy that applies:

  1. An explicit deny anywhere wins, always.
  2. Otherwise the request needs an explicit allow in a policy that is not blocked by a guardrail.
  3. With no allow, the default is an implicit deny.

Several policy types can apply to one request:

Policy type Attached to What it does
Identity-based User, group or role Grants permissions to that identity
Resource-based Resource (S3 bucket, SQS queue, KMS key, Lambda function, secret) Grants access to named principals, including other accounts
Service control policy (SCP) Organization root, OU or account Caps the maximum permissions in member accounts. Grants nothing on its own
Permissions boundary User or role Caps what that identity’s own policies can grant
Session policy An assumed-role or federated session Narrows permissions for that session
Resource control policy (RCP) Organization, OU or account Caps what can be done to resources in member accounts, such as forcing HTTPS or blocking outside principals

For access within one account, an identity policy or a resource policy that allows is enough. For cross-account access, both sides must allow: the resource policy (or role trust policy) in the owning account, and an identity policy in the calling account.

Users, groups, roles and best practice

  • A user is a long-lived identity with a password and optional access keys. A group is a set of users (groups can’t be nested and can’t be principals). A role has no credentials of its own. Something assumes it and receives temporary credentials from STS.
  • Least privilege: start from nothing and add. Use IAM Access Analyzer to find resources shared outside your account or organization, to generate policies from CloudTrail activity, and to find unused permissions. Use the credential report and “last used” data to retire stale keys.
  • Root user: turn on MFA, don’t create access keys for it, lock it away, and use it only for the few tasks that need it (changing the account’s support plan, closing the account, restoring IAM permissions, some billing settings). Organizations can centralise root access management for member accounts.
  • MFA options are virtual authenticator apps, FIDO2 security keys and hardware tokens. A policy condition aws:MultiFactorAuthPresent can require MFA for sensitive actions.
  • Policy elements: Effect, Principal (resource policies only), Action, Resource, Condition. Useful conditions: aws:SourceIp, aws:SourceVpce, aws:SecureTransport, aws:PrincipalOrgID (allow anyone in my organization, without listing accounts), aws:RequestedRegion and aws:PrincipalTag for attribute-based access control.
  • Roles for compute: EC2 gets credentials from a role through an instance profile (read from the instance metadata service, rotated automatically). Lambda uses an execution role. ECS tasks use a task role. Never put long-term access keys on a server or in code.
  • IMDSv2 (session-token based) protects instance credentials from SSRF attacks. Require it on new instances.

Cross-account access and role switching

  • The standard pattern: Account B creates a role with permissions and a trust policy naming Account A. A user in A (with permission to call sts:AssumeRole) assumes it and gets temporary credentials, which expire (15 minutes to 12 hours, one hour by default).
  • Role switching in the console is the same thing for a person.
  • For a third-party vendor, add an external ID to the trust policy so the vendor can’t be tricked into acting on your behalf for another customer (the confused deputy problem).
  • Resource policies (S3, SQS, SNS, KMS, Lambda) can grant access cross-account directly with no role. The caller then keeps its own permissions, whereas assuming a role means giving up the original permissions for the session. That matters when a job must read from a bucket in another account and write to one in its own.
  • AWS Resource Access Manager (RAM) shares resources such as subnets, Transit Gateways, Route 53 Resolver rules and License Manager configurations with other accounts or an organization, instead of duplicating them. VPC sharing lets many accounts run workloads in subnets owned by one central networking account.

Multi-account strategy

  • AWS Organizations groups accounts into OUs, gives consolidated billing (one invoice, pooled volume discounts, shared Reserved Instance and Savings Plans benefit) and applies SCPs.
  • SCPs are guardrails. They don’t apply to the management account, they limit even the root user of a member account, and they don’t grant anything. “Prevent every account from leaving the organization, disabling CloudTrail or using Regions other than eu-west-1, even for administrators” is an SCP. Use a deny list (allow everything, deny specific actions) or an allow list.
  • AWS Control Tower builds a landing zone: a multi-account environment with a management account, log archive and audit accounts, preventive controls (SCPs), detective controls (Config rules) and Account Factory for vending new accounts. “Set up a secure multi-account environment with best-practice guardrails quickly” is Control Tower.
  • Separate accounts by workload, environment and function. An account is the strongest isolation boundary in AWS, so one account for security tooling and one for logs is standard.
  • AWS Firewall Manager applies WAF rules, Shield Advanced protections, security group policies and Network Firewall policies across an organization from one place.

Federation and sign-in

Need Service
Employees signing in to many AWS accounts and apps with corporate identities IAM Identity Center (successor to AWS SSO) with permission sets, connected to an external IdP over SAML/SCIM, to its own directory, or to AD
An existing SAML 2.0 identity provider and just a few accounts IAM identity provider with roles users assume
Users signing in to your web or mobile app (sign-up, MFA, social login) Cognito user pools (issue JWTs)
App users or guests needing temporary AWS credentials, for example to upload to S3 Cognito identity pools (federated identities, exchange a token for STS credentials)
Microsoft Active Directory on AWS AWS Managed Microsoft AD (real AD, trust with on-premises), AD Connector (proxy to on-premises AD, stores nothing), Simple AD (basic Samba-based, no trusts)

Use federation, not IAM users, when you have more than a handful of people or a corporate directory. “Employees use their existing corporate credentials” means federation.

Workloads, applications and network security

VPC building blocks

  • A VPC spans a Region. A subnet lives in one AZ. AWS reserves 5 IP addresses in every subnet. A VPC CIDR is between /16 and /28, and you can add secondary CIDRs.
  • A public subnet has a route to an internet gateway (and its instances have public or Elastic IPs). A private subnet has no such route. The classic three-tier layout: load balancer in public subnets, app tier in private subnets, database in private (or isolated) subnets, each tier spread across at least two AZs.
  • A NAT gateway sits in a public subnet and lets private instances start outbound connections to the internet while blocking inbound. It lives in one AZ, so deploy one per AZ for availability (a single shared one is cheaper but is a single point of failure and incurs cross-AZ charges). IPv6 outbound-only uses an egress-only internet gateway. A NAT instance is the old self-managed option.
  • Route tables decide where traffic goes. Most specific route wins. Traffic to peering, Transit Gateway, VPN and endpoints all needs a route.
  • VPC Flow Logs record accepted and rejected traffic metadata to CloudWatch Logs, S3 or Firehose. They don’t capture payloads. Traffic Mirroring copies packets for inspection.

Security groups vs network ACLs

Security group Network ACL
Applies to Network interfaces (instances, endpoints, load balancers, RDS) Whole subnet
State Stateful: return traffic allowed automatically Stateless: allow return traffic explicitly, including ephemeral ports 1024–65535
Rules Allow only, all rules evaluated Allow and deny, evaluated lowest number first
Source in a rule CIDR, prefix list, or another security group CIDR only
Default Inbound denied, outbound allowed Default NACL allows all; a custom NACL denies all

To block one malicious IP use a NACL deny because security groups can’t deny. For “the database accepts traffic only from the app tier”, reference the app tier’s security group as the source, and it keeps working as instances come and go.

Reaching AWS services without the internet

Option Works with How Cost
Gateway endpoint S3 and DynamoDB only Route table entry with a prefix list Free
Interface endpoint (PrivateLink) Most AWS services and partner or your own services ENI with a private IP in your subnet, DNS name resolves to it Hourly per AZ plus per GB
S3 interface endpoint S3 from on-premises or other VPCs over VPN/Direct Connect ENI Paid
  • Endpoint policies limit what can be done through the endpoint, and bucket policies can require aws:SourceVpce so data is only reachable from your VPC.
  • A gateway endpoint also removes NAT gateway data processing charges for S3 and DynamoDB traffic, so it is both the secure and the cheap answer.
  • AWS PrivateLink lets you expose your own service (behind a Network Load Balancer) to other VPCs and accounts one-way, with no peering and no CIDR overlap problems. Consumers can’t reach anything else in your VPC.

Edge protection

Service Layer and job
AWS WAF Layer 7. Web ACL rules for SQL injection, cross-site scripting, rate-based rules, IP sets, geo match, bot control, managed rule groups. Attach to CloudFront, ALB, API Gateway, AppSync, Cognito user pools
AWS Shield Standard Free, automatic, protects against common layer 3/4 DDoS attacks on all customers
Shield Advanced Paid. Larger attack protection for CloudFront, Route 53, Global Accelerator, ALB, NLB, Elastic IPs. Shield Response Team, cost protection, WAF at no extra rule cost
AWS Network Firewall Managed stateful and stateless inspection inside the VPC, domain filtering, Suricata rules
CloudFront / Route 53 / Global Accelerator Absorb attacks at the edge because they have large distributed capacity

Typical DDoS-resilient design: CloudFront and Route 53 in front, ALB behind with WAF, Auto Scaling for the app tier, and the origin locked so only CloudFront can reach it (an AWS managed prefix list for CloudFront in the ALB’s security group, or a secret header).

Securing connections to on-premises

  • Site-to-Site VPN: IPsec over the internet, two tunnels per connection (two endpoints in different AZs), about 1.25 Gbps per tunnel, set up in minutes. Needs a virtual private gateway or Transit Gateway on the AWS side and a customer gateway device.
  • Direct Connect: dedicated private network link (1, 10 or 100 Gbps dedicated; smaller hosted connections through partners). Consistent latency, but not encrypted by default, and takes weeks to provision. For encryption use a VPN over a public VIF, a VPN over Direct Connect, or MACsec on supported dedicated connections.
  • Direct Connect + VPN backup is the usual resilient hybrid design. Client VPN is for remote users to reach a VPC.

Secrets and application configuration

Secrets Manager Parameter Store (SecureString)
Automatic rotation Built in (Lambda-based, with RDS, Redshift, DocumentDB integrations) Not built in
Cost Per secret per month plus API calls Standard parameters free; advanced tier paid
Cross-Region replication Yes No
Pick when Database credentials that must rotate, secrets shared across accounts Configuration values, flags and simple secrets

Both encrypt with KMS and are read at runtime through the instance or task role, so nothing is hard-coded or stored in plain environment variables or user data. Lambda, ECS and CloudFormation can reference both.

Cognito, GuardDuty, Macie and the other security services

Service Answers the question
CloudTrail Who made which API call, when and from where. Event history shows 90 days of management events. Create a trail (ideally an organization trail with log file validation, to S3) for longer. CloudTrail Lake queries events with SQL
AWS Config What was this resource’s configuration over time, and does it comply with my rules? Managed rules, conformance packs, auto-remediation through Systems Manager
GuardDuty Is something malicious happening? Threat detection from CloudTrail, VPC Flow Logs, DNS logs, plus S3, EKS, RDS, Lambda and malware scanning protection
Inspector Do my EC2 instances, container images in ECR and Lambda functions have known vulnerabilities or unintended network exposure?
Macie Is there sensitive data (PII, credentials) in my S3 buckets?
Security Hub One place to see and prioritise findings from GuardDuty, Inspector, Macie and others across accounts, plus security standard checks
Detective Investigate the root cause of a finding using a behaviour graph
Audit Manager Collect evidence for audits continuously
Trusted Advisor Checks including open security groups, exposed access keys and MFA on root

Threat vectors outside AWS: DDoS (Shield, CloudFront, Route 53, Auto Scaling), SQL injection and XSS (WAF), brute-force and credential stuffing (WAF rate limits, Cognito, MFA), port scans and unwanted ports (security groups, NACLs, Network Firewall).

Data security controls

Encryption at rest with KMS

  • AWS managed keys (aws/s3, aws/ebs) are created for you. You can view them but not edit their policies, and they rotate every year automatically. Customer managed keys let you set the key policy, enable rotation (yearly by default, or custom period), disable, delete (7 to 30 day waiting period) and share cross-account.
  • The key policy is the primary access control for a KMS key. IAM policies only work if the key policy allows IAM to control access. Cross-account use needs the key policy in the owner account and an IAM policy in the caller’s account.
  • Envelope encryption: KMS encrypts small data keys, and the data keys encrypt the data (KMS directly encrypts at most 4 KB). Services do this for you.
  • Multi-Region keys share key material across Regions so ciphertext from one can be decrypted in another. Imported key material and external key stores are for strict key-origin requirements.
  • CloudHSM is a single-tenant, dedicated hardware module (FIPS 140-2 level 3) where you control the keys and AWS cannot see them. Pick it when a rule demands dedicated HSMs or customer-held key custody. KMS is the default otherwise.
  • Symmetric KMS keys are the default. Use asymmetric keys for signing or when public-key encryption must happen outside AWS.

Service defaults to know:

Service At-rest encryption notes
S3 All new objects are encrypted with SSE-S3 by default. Options: SSE-S3, SSE-KMS (audit trail, key policy control, request quota applies), DSSE-KMS (two layers), SSE-C (you send the key each request), client-side
EBS Encrypt per volume, or turn on encryption by default per Region. Snapshots and volumes made from them stay encrypted
RDS / Aurora Choose at creation. You can’t encrypt an existing unencrypted instance in place. Snapshot, copy the snapshot with encryption, restore. Read replicas match the source
DynamoDB Always encrypted at rest (AWS owned, AWS managed or customer managed key)
EFS, FSx, Redshift, SQS, SNS Encryption option with KMS

An encrypted EBS snapshot can only be shared with another account if it uses a customer managed key that the other account may use. Snapshots with the AWS managed key can’t be shared. The recipient should copy and re-encrypt with their own key.

Encryption in transit and certificates

  • Use TLS everywhere. AWS Certificate Manager (ACM) provisions public certificates for free, installs them on ELB, CloudFront and API Gateway, and renews them automatically (DNS validation renews cleanly). You can’t export public ACM certificates to put on an EC2 instance’s web server. ACM certificates are Regional. A certificate for CloudFront must be in us-east-1. ACM Private CA issues internal certificates (paid).
  • ALB and NLB can terminate TLS (offload), or pass encrypted traffic through to targets for end-to-end encryption. Enforce HTTPS with a redirect rule, aws:SecureTransport in S3 bucket policies, rds.force_ssl for PostgreSQL, and require TLS on Redis.
  • CloudFront can enforce viewer HTTPS and talk HTTPS to the origin. Field-level encryption protects specific form fields all the way to the application.

S3 access control and protection

  • Block Public Access at account and bucket level stops accidental exposure. New buckets have it on by default. ACLs are disabled by default through Object Ownership set to bucket owner enforced, so use policies, not ACLs.
  • Bucket policies grant or deny, including across accounts and with conditions (aws:SourceVpce, aws:PrincipalOrgID, aws:SecureTransport). Access Points give each application its own policy and network origin on a shared bucket. S3 Access Grants map directory identities to data.
  • Presigned URLs give time-limited access to one object using the signer’s permissions. CloudFront signed URLs and cookies do the same for private content behind a distribution. Origin access control (OAC) keeps the bucket private so only your distribution reads it (replaces the older origin access identity).
  • Versioning keeps every version and protects against overwrite and accidental delete (a delete adds a delete marker). MFA Delete requires MFA to permanently delete a version.
  • Object Lock (needs versioning) gives write-once-read-many (WORM):
    • Governance mode: users with special permission can override or delete.
    • Compliance mode: nobody can delete or shorten retention before the date, including root.
    • Legal hold: indefinite lock without a date, independent of retention.
  • S3 Glacier Vault Lock does the same job for a Glacier vault with an immutable policy. AWS Backup Vault Lock locks backups.
  • Replication (needs versioning on both buckets): CRR across Regions for compliance, latency or DR; SRR in the same Region for log aggregation or copies to another account. It applies to new objects. Batch Replication copies existing ones. Replication Time Control targets 15 minutes.

Data governance, classification and retention

  • Macie discovers and classifies sensitive data in S3. Tags, S3 Storage Lens and Inventory report on what you hold.
  • Lake Formation gives column, row and cell-level permissions on data lakes, centrally.
  • Retention: S3 lifecycle rules expire or archive data, DynamoDB TTL deletes expired items, CloudWatch Logs has a retention setting, Backup plans have retention periods. Compliance needs (retain 7 years, can’t delete) point to Object Lock, Vault Lock and Backup Vault Lock.
  • Data recovery and backups: AWS Backup centralises policy-based backups of EBS, EFS, RDS, DynamoDB, FSx, S3, EC2 and more, with cross-Region and cross-account copies, Organizations-wide policies and vault lock. RDS has automated backups (0–35 days, point-in-time restore) and manual snapshots. EBS has incremental snapshots (Data Lifecycle Manager automates them, Recycle Bin recovers deleted ones). DynamoDB has point-in-time recovery for 35 days and on-demand backups.
  • Key rotation and certificates: KMS customer managed keys rotate yearly with the option to change the period; Secrets Manager rotates credentials on a schedule; ACM renews certificates; rotate IAM user keys or, better, remove them.

Mapping compliance requirements

Requirement Pick
Prove no one changed or deleted data Object Lock compliance mode, CloudTrail log file validation
Data must stay in a given country Choose the Region, SCP denying other Regions, replication only inside allowed Regions
Keys must be under your exclusive control CloudHSM or KMS with external key store
Audit all key use KMS with CloudTrail
Continuous config compliance AWS Config rules and conformance packs
Find exposed PII Macie
Evidence for auditors Artifact (AWS reports), Audit Manager

Exam checklist

  • No long-term credentials on compute. Use roles, instance profiles and execution roles.
  • A cross-account role needs a trust policy on one side and permissions on the other.
  • “Across all accounts, even administrators”: SCP. “Quickly set up governed multi-account environment”: Control Tower.
  • “Employees, corporate credentials, many accounts”: IAM Identity Center. “App users”: Cognito user pools. “App users need AWS credentials”: identity pools.
  • “Block an IP address”: NACL deny. “App tier to database only”: security group referencing a security group.
  • “Private access to S3 or DynamoDB from a VPC”: gateway endpoint. “Any other AWS service, or your own service privately”: interface endpoint or PrivateLink.
  • “SQL injection, XSS, rate limit”: WAF. “DDoS”: Shield, CloudFront, Route 53.
  • “Encrypted, dedicated connection to on-premises”: VPN over Direct Connect. “Quick encrypted link”: Site-to-Site VPN.
  • “Rotate database passwords automatically”: Secrets Manager. “Cheap configuration values”: Parameter Store.
  • “Only CloudFront can read the bucket”: origin access control. “Temporary access to one object”: presigned URL.
  • “Nobody can delete, not even root”: Object Lock compliance. “Encrypt an existing unencrypted RDS”: snapshot, copy encrypted, restore.
  • “Share an encrypted snapshot”: customer managed key plus key access for the other account.
  • “Sensitive data in S3”: Macie. “Threats from logs”: GuardDuty. “Vulnerabilities on instances”: Inspector. “Who did this API call”: CloudTrail.

Test what you just read. 45 practice questions on design secure architectures.

Practise this domain

All SAA-C03 notes