Self-study deck · aligned to AWS Certified Security – Specialty (SCS-C03)

AWS Security
& Governance

Govern a multi-account organization, design least-privilege identity, detect and respond to threats, and protect infrastructure and data — at production depth and exam depth.

Use ← → / Space to navigate · I contents · O overview · T theme · F fullscreen

AWS Security & Governance

Contents

Click any line to jump there · press I to return to this page

Chapter 1

Orientation

The mental model, the multi-account reference architecture, and how the SCS-C03 exam is built.

Shared responsibility

Who secures what depends on the service model

AWS secures the cloud itself; you secure what you put in it. The line moves with abstraction.

LayerEC2 (IaaS)ECS/EKS on FargateLambda, S3, DynamoDB
Physical, hypervisor, global networkAWSAWSAWS
Guest OS patching and hardeningYouAWSAWS
Container image and runtime configYouYou—
Network rules (SG, NACL, endpoints)YouYouYou (if in a VPC)
IAM: who can call whatYouYouYou
Data classification and encryption choiceYouYouYou
Logging, detection, responseYouYouYou

Identity, data, and detection are always yours. Exam answers that hand those to AWS are wrong. Compliance reports for the AWS side come from AWS Artifact.

Defense in depth

Four kinds of control, layered

Every chapter maps its services to these layers. Good designs use all four, not just one.

Preventive

  • Stop the action before it happens.
  • SCPs, RCPs, declarative policies, IAM, permission boundaries.
  • Security groups, NACLs, WAF, Block Public Access.
  • KMS key policies, S3 Object Lock.

Detective

  • Notice when something happens or drifts.
  • CloudTrail, Config rules, GuardDuty, Inspector, Macie.
  • Security Hub and Security Hub CSPM, Access Analyzer.
  • CloudWatch metric filters and alarms.

Responsive

  • Act on a detection, ideally automatically.
  • EventBridge → Lambda, Step Functions, SSM Automation.
  • Config auto-remediation, Shield Response Team.
  • Isolation playbooks, credential revocation.

Recovery

  • Return to a known-good state.
  • AWS Backup with vault lock, snapshots, versioning.
  • Golden AMIs, IaC redeploy, Application Recovery Controller.
  • Post-incident review feeds new preventive controls.

Exam heuristic: prefer a preventive control when the question says "ensure it can never happen", a detective one for "identify" or "audit", and an automated responsive one for "with the least operational effort".

Reference architecture

The multi-account security baseline

Based on the AWS Security Reference Architecture (SRA) and the Control Tower landing zone.

Management account

  • Owns AWS Organizations, billing, and organization policies.
  • Runs no workloads; very few humans have access.
  • Delegates security services to other accounts.

Security Tooling (Audit) account

  • Delegated administrator for GuardDuty, Security Hub, Inspector, Macie, Detective, Config, Access Analyzer, Firewall Manager.
  • Security team works here, read-only into workloads.

Log Archive account

  • Organization CloudTrail, Config, VPC Flow Logs, and Security Lake data.
  • Immutable storage: S3 Object Lock, restrictive bucket and KMS key policies.
  • Almost nobody can delete anything here.

Network account

  • Transit Gateway, inspection VPC with Network Firewall, egress, DNS.
  • Shares subnets and TGW with workload accounts through AWS RAM.

Workload accounts

  • One account per application and environment.
  • Separate OUs for Prod and Non-prod with different guardrails.

Sandbox, Suspended, Forensics

  • Sandbox: experiments with spend and Region limits.
  • Suspended: deny-all SCP before closing an account.
  • Forensics: isolated account for evidence and analysis.
Security service map

Which service answers which question

Most exam questions reduce to picking the right service for a job, then the right feature of it.

QuestionPrimary services
Who may do what, where?IAM, IAM Identity Center, Organizations policies, Access Analyzer, Verified Permissions
What happened, and who did it?CloudTrail (and Lake), CloudWatch Logs, VPC Flow Logs, Security Lake, Athena
Is something malicious going on?GuardDuty, Detective, Security Hub
Is something misconfigured or vulnerable?Config, Security Hub CSPM, Inspector, Trusted Advisor
Where is my sensitive data?Macie, CloudWatch Logs data protection, SNS message data protection
How do I block bad traffic?WAF, Shield, Network Firewall, DNS Firewall, security groups, NACLs
How is data protected?KMS, CloudHSM, ACM, Private CA, Secrets Manager, S3 Object Lock, AWS Backup
The exam

AWS Certified Security – Specialty (SCS-C03)

Replaced SCS-C02 on 2 December 2025. 3–5 years of cloud security experience recommended.

Content domains

DomainWeightDeck
1 Detection16%Chapter 4
2 Incident Response14%Chapter 5
3 Infrastructure Security18%Chapter 6
4 Identity and Access Management20%Chapter 3
5 Data Protection18%Chapter 7
6 Security Foundations and Governance14%Chapter 2

Format

  • 65 questions: 50 scored + 15 unscored (not marked).
  • Types: multiple choice, multiple response, ordering, matching.
  • Ordering and matching need every element right for credit.
  • Scaled score 100–1,000; pass at 750.
  • Compensatory: you pass on the total, not per domain.
  • No penalty for guessing: answer everything.
What changed

SCS-C02 → SCS-C03

Same six-domain shape, with logging and detection reorganized and newer topics added.

Restructured

  • C02 "Threat Detection and IR" + "Logging and Monitoring" became C03 "Detection" + "Incident Response".
  • IAM grew from 16% to 20%; Infrastructure fell from 20% to 18%.
  • Domain 6 renamed "Security Foundations and Governance".

Added

  • Validate findings to assess scope and impact (2.2.3).
  • OCSF ingestion and third-party WAF rules (3.1.4).
  • GenAI guardrails, OWASP Top 10 for LLMs (3.2.7).
  • Inter-node encryption for EMR, EKS, SageMaker AI, Nitro (5.1.3).
  • Imported vs AWS-generated key material (5.3.3).
  • Masking with Logs/SNS data protection (5.3.4).
  • Multi-Region keys and Private CA (5.3.5).

Removed

  • ASFF as a named topic (Security Hub CSPM still uses it).
  • TCP/IP and OSI fundamentals, TLS concepts.
  • Policy element basics (Principal, Action, Resource, Condition).
  • Host-based firewalls, Reachability Analyzer, VIF design, S3 static websites.
How to use this deck

A study loop that sticks

Read a part, do its lab, then answer the self-check out loud without notes.

Per part

  • Read the concept slides; redraw the diagrams from memory.
  • Study the "Exam traps" slide: these are the distractors you will see.
  • Answer the scenarios before reading the answer column.

Per chapter

  • Run the matching lab in a sandbox organization.
  • Answer the self-check questions; revisit anything you hesitate on.
  • Write one page of your own notes in plain words.

Before the exam

  • Re-read every "Exam traps" and "Exam-style scenarios" slide.
  • Use the keyword cheat sheet in the back matter.
  • Take an official practice question set on AWS Skill Builder.

Navigation: ← → or Space to move, I for Contents, O for overview, T for theme, F for fullscreen. Every Contents line is a link.

Chapter 2

Security foundations and governance

Accounts as the isolation boundary, organization-wide guardrails, and proof that the estate stays compliant.

Chapter 2 · Part 2.1

Multi-account with AWS Organizations

Why the account is the strongest boundary in AWS, and how to structure hundreds of them.

Task 6.1.1 · Why multi-account

The account is the hardest boundary AWS gives you

IAM mistakes, quotas, and incidents stop at the account edge; that is why every landing zone starts here.

Isolation

  • IAM principals have no access to another account unless both sides allow it.
  • A compromised workload account cannot read the log archive account.
  • Service quotas and API throttling are per account and Region.

Blast radius

  • Separate prod, non-prod, and sandbox so an experiment cannot touch prod data.
  • Security tooling lives in accounts that workload teams cannot administer.
  • An account can be quarantined by moving it to a restrictive OU.

Governance and cost

  • Guardrails attach to OUs, so policy follows the account’s purpose.
  • Consolidated billing and cost allocation per account.
  • Compliance scope (e.g. PCI) can be limited to specific accounts.

Exam signal: “isolate”, “limit blast radius”, “separate teams or environments” → separate accounts grouped in OUs, not more IAM policies in one account.

Task 6.1.1 · Building blocks

How AWS Organizations is put together

One management account, one root, a tree of OUs, and member accounts that inherit policy from every parent.

Entities

  • Management account: creates the org, pays the bill, owns policies.
  • Root: top of the tree; exactly one per org.
  • OU: container for accounts or OUs; up to five levels below the root.
  • Member account: belongs to exactly one parent at a time.

Feature sets

  • All features: required for SCPs, RCPs, declarative, tag and backup policies.
  • Consolidated billing only: no policy types at all.
  • Moving to all features needs every invited account to approve (90-day handshake).

Integrations

  • Trusted access: lets a service act across the org (e.g. org trail, StackSets).
  • Delegated administrator: a member account that runs a service for the org.
  • Organizations is global, hosted in us-east-1.

Default quotas worth remembering

ItemValue
Accounts per organization10 by default (adjustable; management account requests it)
OUs per organization / nesting depth2,000 / five levels below the root
SCP size / RCP size10,240 / 5,120 characters
Directly attached per root, OU, accountSCP 10 · RCP 5 (incl. RCPFullAWSAccess) · declarative 10
Task 6.1.1 · OU design

A reference OU structure

Group accounts by function and control needs, not by org chart; guardrails attach to these OUs.

OUPurposeTypical accountsTypical guardrails
SecuritySecurity tooling and evidenceLog Archive, Security Tooling (Audit), ForensicsDeny deleting logs; only security team roles
InfrastructureShared platform servicesNetwork (TGW, egress), Shared Services, DNSRestrict who can change routing and endpoints
Workloads / ProdProduction applicationsOne account per app or team per environmentStrict region deny, encryption, no IAM users
Workloads / Non-prodDev, test, stagingMirrors prod accountsSame baseline, looser instance types
SandboxExperiments, no prod dataPer-developer accountsBudget limits, no connectivity to corp network
Policy StagingTest new guardrailsCopies of real account typesCandidate SCPs/RCPs before rollout
SuspendedAccounts being closed or quarantinedCompromised or retired accountsDeny-all SCP except break-glass role

Attach guardrails to OUs, not to individual accounts: new accounts inherit them automatically and the policy count stays manageable.

Task 6.1.4 · Delegated administration

Keep the management account empty

Policies don’t restrict the management account, so anything running there is outside your guardrails.

Management account rules

  • No workloads, no developers, very few human principals.
  • SCPs and RCPs never apply to it.
  • Used for billing, Organizations, Control Tower, and delegations.
  • Root user protected with MFA and monitored.

Typical delegated admins

ServiceDelegate to
GuardDuty, Security Hub, Inspector, Macie, DetectiveSecurity Tooling
IAM Access Analyzer, IAM root accessSecurity Tooling
Firewall ManagerSecurity Tooling or Network
AWS Config aggregator / conformance packsSecurity Tooling
CloudFormation StackSets, AWS BackupInfrastructure / Shared Services
aws organizations enable-aws-service-access --service-principal guardduty.amazonaws.com
aws guardduty enable-organization-admin-account --admin-account-id 222233334444   # from management account
aws organizations list-delegated-administrators                                       # audit who holds what
Task 6.1.1 · Account lifecycle

Creating, joining, quarantining, and closing accounts

Each path leaves different access behind; know which role exists and who can reach root.

Created by the org

  • CreateAccount (or Account Factory) builds the account inside the org.
  • Creates OrganizationAccountAccessRole trusted by the management account.
  • With centralized root access on, it has no root credentials.

Invited existing account

  • Account accepts a handshake (valid 15 days).
  • No access role is created; add one yourself.
  • Its existing root password and IAM users stay; clean them up.

Quarantine and close

  • Move to Suspended OU with a deny-all SCP (except break-glass).
  • CloseAccount from the management account; 90-day post-closure period.
  • Closed accounts still count toward the quota until permanently closed.

An account can leave the org only if it has the info needed to stand alone (payment method, contact). Block organizations:LeaveOrganization with an SCP.

Exam traps · Organizations

Where answers go wrong

Most wrong options rely on the management account being governed like everyone else.

Management account

  • SCPs/RCPs do not restrict it, even when attached to the root.
  • Running security tools there means they are ungoverned.
  • Use a delegated admin member account instead.

Invited accounts

  • They lack OrganizationAccountAccessRole.
  • “Cannot assume role into new member” → was it invited, not created?
  • Root and IAM users from before joining still exist.

Consolidated billing only

  • No SCPs, RCPs, or other policy types.
  • Fix: enable all features (all members must approve).
  • Delegated admins also need trusted access enabled.
Chapter 2 · Part 2.2

Organization policies: SCP, RCP, declarative

Guardrails that cap identities, cap resources, and lock service configuration across every account.

Task 6.1.3 · Policy types

Two families of organization policy

Authorization policies cap what IAM allows; management policies configure services and settings.

PolicyFamilyWhat it controlsGrants?
Service control policy (SCP)AuthorizationMax permissions of IAM users and roles (incl. member root) in member accountsNever
Resource control policy (RCP)AuthorizationMax permissions on resources in member accounts, whoever callsNever
Declarative policy (EC2 policy)ManagementEnforced EC2/VPC/EBS service attributes (e.g. IMDSv2, block public AMIs)n/a
Tag policyManagementAllowed tag keys, case, and values; optional enforcementn/a
Backup policyManagementAWS Backup plans deployed to accountsn/a
AI services opt-outManagementWhether AWS AI services may store/use your contentn/a
Chat applications, Security Hub, and newer typesManagementService-specific settings; check the live listn/a

Effective permission = identity/resource policy allow ∩ every SCP ∩ every RCP ∩ permission boundary ∩ session policy. Any explicit deny wins.

Task 6.1.3 · SCP mechanics

How SCPs are evaluated

An action must be allowed at every level from the root to the account, and denied at none.

Inheritance

  • FullAWSAccess is attached everywhere by default.
  • Allow: needed at root, every OU on the path, and the account.
  • Deny: one deny at any level blocks the action.
  • At least one SCP must remain attached to every entity.

Scope

  • Affects IAM users and roles in member accounts, including the member root user.
  • Does not affect the management account.
  • Does not affect service-linked roles.
  • Does not affect principals from other accounts using your resources.

Syntax (full IAM language)

  • SCPs now support conditions, resource ARNs, and NotAction in Allow.
  • NotResource works in Allow and Deny.
  • Wildcards may appear anywhere in Action.
  • No Principal element in SCPs.

Test new SCPs in a Policy Staging OU; use IAM service last-accessed data and CloudTrail AccessDenied events to find impact before attaching to the root.

Task 6.1.3 · SCP strategies

Deny list vs allow list

Most organizations keep FullAWSAccess and add targeted denies; allow lists suit tightly regulated OUs.

Deny list (common)

  • Keep FullAWSAccess; add explicit Deny statements.
  • New AWS services are available by default.
  • Easy to reason about and extend.

Allow list

  • Replace FullAWSAccess with an allow of approved services.
  • New services are blocked until approved.
  • More maintenance; easy to break a workload.
{
  "Version": "2012-10-17",
  "Statement": [{
    "Sid": "DenyOutsideApprovedRegions",
    "Effect": "Deny",
    "NotAction": ["iam:*", "organizations:*", "sts:*", "support:*", "cloudfront:*", "route53:*", "budgets:*"],
    "Resource": "*",
    "Condition": {
      "StringNotEquals": {"aws:RequestedRegion": ["ap-southeast-1", "ap-northeast-1"]},
      "ArnNotLike": {"aws:PrincipalArn": "arn:aws:iam::*:role/BreakGlassAdmin"}
    }
  }]
}
Task 6.1.3 · SCP guardrails

Guardrails almost every organization attaches

Each one protects a control that an account administrator could otherwise switch off.

Protect detection

  • Deny cloudtrail:StopLogging, DeleteTrail, UpdateTrail.
  • Deny guardduty:DeleteDetector, DisassociateFromAdministratorAccount.
  • Deny config:StopConfigurationRecorder, DeleteDeliveryChannel.
  • Deny disabling Security Hub, Access Analyzer, Macie.

Protect the platform

  • Deny organizations:LeaveOrganization.
  • Deny changes to roles named OrganizationAccountAccessRole or AWSControlTower*.
  • Deny modifying central network and log resources.
  • Exempt a platform role with aws:PrincipalArn.

Raise the baseline

  • Deny iam:CreateUser / CreateAccessKey (no long-term keys).
  • Deny unencrypted EBS or RDS creation (condition keys).
  • Deny s3:PutAccountPublicAccessBlock changes.
  • Require tags on create with aws:RequestTag + Null.
{"Effect": "Deny",
 "Action": ["cloudtrail:StopLogging", "cloudtrail:DeleteTrail", "guardduty:DeleteDetector", "config:StopConfigurationRecorder"],
 "Resource": "*",
 "Condition": {"ArnNotLike": {"aws:PrincipalArn": "arn:aws:iam::*:role/SecurityPlatformAdmin"}}}
Task 6.1.3 · RCP mechanics

Resource control policies cap what can be done to your resources

RCPs travel with the resource, so they also restrict principals from outside your organization.

How they work

  • Attached to root, OU, or account like SCPs; evaluated for the resource owner’s account.
  • RCPFullAWSAccess is attached everywhere and cannot be detached.
  • Custom RCPs: Deny statements only, Principal must be "*".
  • Up to 5 attached per entity (including RCPFullAWSAccess), 5,120 characters.

Scope

  • Applies to every caller, including other orgs and the member root user.
  • Not the management account’s resources.
  • Not calls made by service-linked roles.
  • Not AWS managed KMS keys.

Supported services (subset)

  • S3, STS, KMS, SQS, Secrets Manager.
  • Also DynamoDB, ECR, CloudWatch Logs, Cognito, EventBridge, and more.
  • Not every service: check the live list before relying on it.
  • Unsupported services ignore the RCP silently.

Use an SCP to stop *your* identities doing something; use an RCP to stop *anyone* doing something to *your* resources (e.g. a bucket policy that grants a stranger access).

Task 6.1.3 · Choosing the guardrail

SCP, RCP, permission boundary, or resource policy?

Pick by who is being restricted and who owns the control.

ControlRestrictsSet byTypical use
SCPPrincipals in member accountsOrg adminsRegion deny, protect security services, block IAM users
RCPAccess to resources in member accountsOrg adminsOrg-only access to S3/KMS/Secrets, enforce TLS
Permission boundaryOne IAM user or roleAccount adminsLet developers create roles safely
Session policyOne assumed-role or federated sessionCallerScope down a session at assume time
Resource-based policyAccess to one resourceResource ownerCross-account bucket or key access
VPC endpoint policyCalls through one endpointNetwork ownerOnly org buckets via the S3 endpoint

None of the guardrails grant anything. A request still needs an allow in an identity-based or resource-based policy.

Task 6.1.3 · Declarative policies

Declarative policies lock service configuration

Instead of denying API calls, they set the desired state at the service control plane and keep it there.

EC2 policy attributeValuesEffect
vpc_block_public_accessoff · block_ingress · block_bidirectionalStop IGW traffic; control whether exclusions are allowed
serial_console_accessenabled · disabledAllow or block EC2 serial console
image_block_public_accessunblocked · block_new_sharingBlock new public AMI sharing
allowed_images_settingsenabled · disabled · audit_modeOnly AMIs from approved providers, names, age
instance_metadata_defaultshttp_tokens: required, hop limit, http_tokens_enforcedIMDSv2 by default and enforced on launch
snapshot_block_public_accessblock_all_sharing · block_new_sharing · unblockedStop public EBS snapshots
vpc_encryption_controlunmanaged · attempt_monitor · attempt_enforceAudit or enforce encryption in transit in VPCs
Task 6.1.3 · Declarative policies

Writing and rolling out an EC2 policy

The setting applies even to new APIs that would change it; account admins cannot override it.

{
  "ec2_attributes": {
    "exception_message": {"@@assign": "Blocked by org policy"},
    "instance_metadata_defaults": {
      "http_tokens": {"@@assign": "required"},
      "http_put_response_hop_limit": {"@@assign": "2"},
      "http_tokens_enforced": {"@@assign": "enabled"}
    },
    "snapshot_block_public_access": {
      "state": {"@@assign": "block_all_sharing"}},
    "image_block_public_access": {
      "state": {"@@assign": "block_new_sharing"}}
  }
}

Rollout

  • Generate the account status report to see current settings per account and Region.
  • Start in audit mode where available (audit_mode, attempt_monitor).
  • Attach to a test OU, then widen.
  • exception_message shows users why the call failed.
  • Calls such as DisableSnapshotBlockPublicAccess fail for accounts in scope.
  • Detaching rolls some attributes back to their previous state.
Task 6.1.3 · SCP vs declarative

Why declarative beats an SCP for configuration

An SCP blocks specific API calls; a declarative policy fixes the outcome.

SCP approach

  • Deny ec2:RunInstances unless ec2:MetadataHttpTokens = required.
  • Must list every API that can change the setting.
  • A new API can bypass it until you update the SCP.
  • Does nothing for resources that already exist.

Declarative approach

  • Set http_tokens_enforced = enabled once.
  • Applies to all current and future APIs for that attribute.
  • Account admins cannot change it locally.
  • Status report gives readiness before enforcement.

Gotchas

  • IMDSv2 enforcement breaks launches of IMDSv1-only AMIs.
  • block_new_sharing leaves already-public AMIs or snapshots public.
  • Only EC2/VPC/EBS attributes today; other services still need SCPs.
Exam-style scenarios

Organization policies in practice

Read the requirement, pick the mechanism, and know why the alternatives fail.

ScenarioAnswerWhy
No one in any member account may use Regions outside two approved onesSCP with aws:RequestedRegion deny, NotAction for global servicesCaps identities; exempt global services or IAM breaks
Buckets must never be readable by principals outside the org, even if a bucket policy allows itRCP deny when aws:PrincipalOrgID ≠ org (exempt AWS services)SCPs do not apply to external principals
All new instances must use IMDSv2 and admins must not be able to change the defaultDeclarative EC2 policy: instance_metadata_defaultsEnforces state, covers future APIs
Security team in the management account is not blocked by a new SCPExpected: SCPs never apply to the management accountMove work to member accounts
Stop all EBS snapshots being public, including those already sharedsnapshot_block_public_access = block_all_sharingblock_new_sharing leaves existing public ones
Exam traps · Policies

Common misreadings of organization policies

Watch for options that assume a guardrail can grant access or reach the wrong principal.

SCP myths

  • “Attach an SCP to give access” — SCPs never grant.
  • “SCP restricts a partner account using our bucket” — no, that is an RCP job.
  • “SCP blocks a service-linked role” — it cannot.

RCP myths

  • Allow statements in custom RCPs are not supported.
  • Unsupported services are not protected by RCPs.
  • AWS managed KMS keys are out of RCP scope.

Rollout myths

  • Removing FullAWSAccess without a replacement allow breaks every member account.
  • Attaching straight to the root without testing is the classic outage.
  • A deny at any parent OU cannot be overridden lower down.
Chapter 2 · Part 2.3

Data perimeters

Only trusted identities, accessing trusted resources, from expected networks.

Task 6.1.3 · Data perimeter model

Three perimeters, three questions

Each perimeter is a coarse, org-wide deny that sits underneath fine-grained IAM.

PerimeterQuestionMain policy typeKey condition keys
IdentityOnly trusted identities can access my resources?RCP, resource-based policiesaws:PrincipalOrgID, aws:PrincipalIsAWSService
ResourceMy identities can access only trusted resources?SCP, VPC endpoint policiesaws:ResourceOrgID, aws:ResourceAccount
NetworkAccess only from expected networks?RCP / resource policies (inbound), SCP (outbound)aws:SourceVpc, aws:SourceVpce, aws:SourceIp, aws:ViaAWSService

Threats it addresses

  • Stolen credentials used from the internet.
  • A bucket policy that accidentally trusts "*".
  • Data exfiltration to a personal bucket.

Trusted means

  • Identities: principals in your org, plus AWS services acting for you.
  • Resources: owned by your org, plus AWS-owned ones you need.
  • Networks: your VPCs and corporate IP ranges.

Not a replacement for

  • Least-privilege identity policies.
  • Per-resource policies and encryption.
  • Detective controls (Access Analyzer, GuardDuty).
Task 6.1.3 · Identity perimeter

RCP: only org identities may touch these resources

One policy at the root covers every supported resource in every member account.

{
  "Version": "2012-10-17",
  "Statement": [{
    "Sid": "EnforceOrgIdentities",
    "Effect": "Deny",
    "Principal": "*",
    "Action": ["s3:*", "sqs:*", "kms:*",
               "secretsmanager:*", "sts:AssumeRole"],
    "Resource": "*",
    "Condition": {
      "StringNotEqualsIfExists":
        {"aws:PrincipalOrgID": "o-a1b2c3d4e5"},
      "BoolIfExists":
        {"aws:PrincipalIsAWSService": "false"}
    }
  }, {
    "Sid": "EnforceTLS",
    "Effect": "Deny",
    "Principal": "*",
    "Action": ["s3:*"],
    "Resource": "*",
    "Condition": {"BoolIfExists": {"aws:SecureTransport": "false"}}
  }]
}

Read it carefully

  • IfExists keeps anonymous or service calls from being matched wrongly.
  • aws:PrincipalIsAWSService exempts AWS service principals (e.g. CloudTrail writing logs).
  • Legitimate third parties (a SaaS vendor role) need an explicit exception, e.g. aws:PrincipalAccount.
  • The TLS statement enforces encryption in transit org-wide.
  • Roll out per OU while watching CloudTrail for AccessDenied.
Task 6.1.3 · Resource and network perimeters

SCP: my identities only reach my resources, from my network

These stop exfiltration to outside buckets and use of stolen credentials from the internet.

{"Sid": "EnforceResourcePerimeter",
 "Effect": "Deny",
 "Action": ["s3:*", "sqs:*", "kms:*"],
 "Resource": "*",
 "Condition": {
   "StringNotEqualsIfExists":
     {"aws:ResourceOrgID": "o-a1b2c3d4e5"},
   "ForAllValues:StringNotEquals":
     {"aws:CalledVia": ["cloudformation.amazonaws.com"]}}}
{"Sid": "EnforceNetworkPerimeter",
 "Effect": "Deny",
 "Action": "*",
 "Resource": "*",
 "Condition": {
   "NotIpAddressIfExists":
     {"aws:SourceIp": ["203.0.113.0/24"]},
   "StringNotEqualsIfExists":
     {"aws:SourceVpc": ["vpc-0abc123"]},
   "BoolIfExists": {"aws:ViaAWSService": "false"},
   "ArnNotLikeIfExists": {"aws:PrincipalArn":
     "arn:aws:iam::*:role/aws-service-role/*"}}}

Resource perimeters need exceptions for AWS-owned resources your workloads use (e.g. AWS-managed repositories or service buckets). Network perimeters need aws:ViaAWSService so AWS can call onward on your behalf.

Exam-style scenarios

Data perimeter decisions

Most questions name a leak path; match it to the perimeter that closes it.

ScenarioAnswerWhy
A developer copies data to a personal S3 bucket in another accountSCP with aws:ResourceOrgID (resource perimeter)Stops org identities reaching non-org resources
Leaked access keys used from a home IPNetwork perimeter on aws:SourceIp / aws:SourceVpcCredentials only work from expected networks
Instances in a VPC must only reach org-owned bucketsS3 gateway endpoint policy with aws:ResourceOrgIDEndpoint policy filters every call through it
A bucket policy mistakenly grants Principal: *RCP identity perimeter with aws:PrincipalOrgIDResource-side deny applies to every caller
After an RCP rollout, CloudTrail fails to write to the log bucketAdd aws:PrincipalIsAWSService exemptionService principals are not in your org
Chapter 2 · Part 2.4

AWS Control Tower

An opinionated landing zone, a control catalog, and an account vending machine on top of Organizations.

Task 6.1.2 · Landing zone

What Control Tower sets up for you

Control Tower orchestrates Organizations, CloudTrail, Config, Identity Center, and StackSets into one baseline.

Shared accounts

  • Management account: where Control Tower runs.
  • Log archive (default name “Log Archive”): org CloudTrail and Config logs.
  • Audit (security tooling): cross-account audit and notification roles.
  • Names can be customised at setup but not changed afterwards.

Baselines

  • Org-level CloudTrail trail and centralized Config history.
  • IAM Identity Center as the default access path (optional to self-manage).
  • Each enrolled account gets roles, Config recorder, and notifications.
  • Home Region plus governed Regions you choose.

Landing zone 4.0 changes

  • No required Security OU: bring your own OU structure.
  • Mandatory controls are no longer applied by default.
  • Service integrations are more optional than in 3.x.
  • Check the version before applying 3.x-era advice.
Task 6.1.2 · Controls

Control behavior and guidance

Behavior says how a control works; guidance says how strongly AWS recommends it.

BehaviorImplemented withStatus valuesActs
PreventiveSCPs, RCPs, declarative policiesEnforced · Not enabledBlocks the action before it happens
DetectiveAWS Config rules (incl. Security Hub CSPM controls)Clear · In violation · Not enabledFlags noncompliant resources after the fact
ProactiveCloudFormation hooksPASS · FAIL · SKIPRejects noncompliant resources at CloudFormation deploy time

Guidance categories

  • Mandatory: protect Control Tower’s own resources.
  • Strongly recommended: common multi-account best practices.
  • Elective: lock down actions many enterprises restrict.

Applying controls

  • Enabled per OU from the control catalog (console or EnableControl API).
  • Applies to every enrolled account in that OU.
  • Proactive controls cover only CloudFormation-provisioned resources.
Task 6.1.2 · Account vending

Account Factory, AFT, and customizations

Every new account should arrive already enrolled, baselined, and guarded.

OptionHow it worksUse when
Account Factory (console / Service Catalog)Provisions an enrolled account into a chosen OULow volume, click-ops acceptable
Account Factory for Terraform (AFT)Git repo of account requests → pipeline creates accounts, runs global and per-account Terraform customizationsTerraform shops, GitOps account vending
Customizations for Control Tower (CfCT)CloudFormation templates and SCPs deployed by a pipeline on lifecycle eventsCloudFormation shops
Account Factory Customization (AFC)Blueprints (Service Catalog products) applied when vendingStandard per-account stacks from the console

Existing environments

  • Register an existing OU to extend governance to it.
  • Enroll existing accounts (needs AWSControlTowerExecution role).
  • Resolve conflicting Config recorders or trails first.

Drift

  • Changing CT-managed SCPs, roles, or moving accounts outside CT causes drift.
  • Repair the landing zone or re-register the OU.
  • Protect CT resources with the mandatory controls.
Exam-style scenarios

Control Tower choices

Prefer Control Tower features over hand-rolled automation when the question says “least operational overhead”.

ScenarioAnswerWhy
Block resource creation that violates policy before it exists, for CloudFormation deploymentsProactive control (CloudFormation hook)Evaluates at provisioning time
Alert when an existing bucket allows public readsDetective control (Config rule)Detects state after creation
Prevent any account in an OU from disabling CloudTrailPreventive control (SCP)Blocks the API call
Vend accounts from a Git workflow with Terraform baselinesAccount Factory for TerraformRequest-as-code pipeline
Bring an existing org with 50 accounts under Control TowerSet up landing zone, register OUs, enroll accountsExtends baselines and controls
Chapter 2 · Part 2.5

Root user management

Remove standing root credentials from member accounts and keep a tested break-glass path.

Task 6.1.5 · Root user

What only root can do, and why it is dangerous

Root bypasses IAM inside its own account; only SCPs (member accounts) can limit it.

Tasks that require root credentials

  • Change account settings such as account name, root email, root password.
  • Restore IAM permissions when every admin has been locked out.
  • Change or cancel the AWS Support plan.
  • Configure MFA delete on an S3 bucket.
  • Delete a bucket or SQS policy that denies everyone (or use centralized root access).

Hardening checklist

  • No root access keys, ever.
  • MFA on root: FIDO2 security keys or passkeys; up to 8 MFA devices.
  • Root email is a group mailbox the security team controls.
  • Alert on any root sign-in or API call.

Detect root use

  • EventBridge rule on CloudTrail events where userIdentity.type = Root.
  • Security Hub CSPM / CIS controls flag root keys and missing MFA.
  • IAM credential report shows root key and MFA status.
Task 6.1.5 · Centralized root access

Delete member root credentials and use short-lived root sessions

Enabled in IAM from the management account (tasks can be delegated to an IAM delegated admin); needs trusted access for IAM.

Two capabilities

  • Root credentials management: delete root password, access keys, signing certs, and MFA in member accounts.
  • Privileged root actions: run a few root-only tasks from the central account.
  • New accounts created in the org then have no root credentials.
  • Members cannot sign in as root or recover the password.

Privileged tasks (task policies)

  • IAMAuditRootUserCredentials
  • IAMDeleteRootUserCredentials
  • IAMCreateRootUserPassword (allow recovery)
  • S3UnlockBucketPolicy
  • SQSUnlockQueuePolicy
# From the delegated admin for IAM, as a role with sts:AssumeRoot (never as root)
aws sts assume-root --region us-east-1 \
  --target-principal 111122223333 \
  --task-policy-arn arn=arn:aws:iam::aws:policy/root-task/S3UnlockBucketPolicy \
  --duration-seconds 900
# Regional STS endpoint required; restrict with the sts:TaskPolicyArn condition key
Task 6.1.5 · Break-glass

Designing break-glass access

Break-glass is for when normal federation or IAM is broken; it must work, be rare, and be loud.

What to cover

  • IdP or IAM Identity Center outage.
  • All admin roles locked out by a bad policy.
  • A member account needs a root-only task.
  • Management account root for org-level recovery.

Design

  • Management account root: hardware MFA in a safe, two-person rule.
  • One or two IAM break-glass roles, exempt from guardrails by aws:PrincipalArn.
  • Member root tasks via sts:AssumeRoot, not stored passwords.
  • Credentials in a sealed vault with access logging.

Operate

  • Alarm on every use (EventBridge → SNS / pager).
  • Test quarterly; rotate after every use.
  • Document who may invoke and how to close the incident.
  • Review CloudTrail for every break-glass session.
Exam traps · Root and Control Tower

Answers that look right but are not

These distractors appear often in governance questions.

Root

  • sts:AssumeRoot cannot be called with root credentials.
  • SCPs do restrict a member account’s root user, not the management root.
  • Deleting root credentials is reversible only through “allow password recovery”.

Control Tower

  • Proactive controls do not see resources created outside CloudFormation.
  • Detective controls do not prevent anything.
  • Editing CT-managed SCPs directly causes drift.

Scenario: bucket policy locks everyone out

  • Answer: centralized root access with S3UnlockBucketPolicy.
  • Alternative: member root sign-in (if credentials exist).
  • An admin role cannot fix it: the policy denies everyone.
Chapter 2 · Part 2.6

Secure, consistent deployment

Infrastructure as code, policy checks in the pipeline, tags, central firewall policy, and safe sharing.

Task 6.2.1 · StackSets

CloudFormation StackSets across accounts and Regions

One template, deployed as stack instances into many accounts and Regions from an admin account.

Self-managed permissionsService-managed permissions
RolesYou create AWSCloudFormationStackSetAdministrationRole and ...ExecutionRoleCreated by Organizations trusted access
TargetsExplicit account IDsOUs or the whole org
New accountsAdd manuallyAutomatic deployment when an account joins the target OU
Delegated adminn/aSupported (run from a member account)
Typical useAccounts outside the orgSecurity baselines for every org account

Deployment options

  • Maximum concurrent accounts and failure tolerance.
  • Region order and concurrency.
  • Retain or delete stacks when an account leaves the OU.

Security baselines to deploy

  • IAM roles for security tooling and break-glass.
  • Config rules, EventBridge forwarding rules.
  • Account-level S3 Block Public Access and EBS default encryption.
Task 6.2.1 · Policy as code

Catch insecure infrastructure before it is deployed

Shift checks left into the pipeline, then back them up with proactive and detective controls.

Lint

  • cfn-lint: schema, types, valid properties.
  • Catches errors, not policy.
→

Policy check

  • cfn-guard rules for CloudFormation.
  • Checkov or Trivy for Terraform.
→

Deploy-time gate

  • CloudFormation Hooks (Guard or Lambda).
  • Control Tower proactive controls.
→

Runtime

  • Config rules and Security Hub CSPM.
  • Detect drift and console changes.
# rules/s3.guard
let buckets = Resources.*[ Type == 'AWS::S3::Bucket' ]
rule s3_encrypted_and_versioned when %buckets !empty {
  %buckets.Properties.BucketEncryption exists
  %buckets.Properties.VersioningConfiguration.Status == 'Enabled'
}
cfn-guard validate -d template.yaml -r rules/s3.guard
checkov -d ./terraform --framework terraform
trivy config ./terraform --severity HIGH,CRITICAL

Why layers

  • Pipeline checks are skippable by anyone who deploys from a laptop.
  • Hooks only cover CloudFormation.
  • Detective controls catch everything else, including console changes.
Task 6.2.2 · Tagging

Tags for grouping, cost, and access control

A small mandatory tag set, standardized by tag policies, enforced on create by SCPs.

Mandatory tag set (example)

  • Environment: prod, staging, dev.
  • CostCenter and Owner for chargeback and contact.
  • DataClassification: public, internal, confidential.
  • Project / Application for grouping.

Tag policies

  • Define allowed keys, case, and values.
  • enforced_for blocks noncompliant tagging on listed resource types.
  • Untagged resources are not evaluated.
  • Compliance report in Resource Groups / Tag Editor.

Require tags on create

  • SCP: deny ec2:RunInstances when aws:RequestTag/CostCenter is null.
  • Tag policies alone do not force tags to exist.
  • Tags drive ABAC, so protect tag changes too.
{"tags": {"Environment": {
  "tag_key": {"@@assign": "Environment"},
  "tag_value": {"@@assign": ["prod", "staging", "dev"]},
  "enforced_for": {"@@assign": ["ec2:instance", "s3:bucket"]}}}}
Task 6.2.3 · Firewall Manager

Central firewall policy with AWS Firewall Manager

Define protection once; Firewall Manager applies it to current and future accounts and resources in scope.

Prerequisites

  • Organizations with all features.
  • A Firewall Manager administrator account (delegated).
  • AWS Config enabled in every account and Region in scope.
  • AWS RAM sharing for Network Firewall and DNS Firewall policies.

Policy types

TypeApplies
AWS WAFWeb ACLs on ALB, API Gateway stages, CloudFront
Shield AdvancedProtection and automatic L7 mitigation
Security groupCommon SGs, content audit, usage audit
Network FirewallFirewalls and policies in VPCs
Route 53 Resolver DNS FirewallRule groups associated to VPCs
Network ACLRequired first/last NACL rules
Third-party firewallsPartner NGFW from Marketplace

Scope by account, OU, Region, resource type, and tags. Auto-remediation makes noncompliant resources compliant; without it Firewall Manager only reports.

Task 6.2.4 · Sharing

Share resources safely: AWS RAM and Service Catalog

Share instead of duplicating, and give teams pre-approved products instead of broad permissions.

AWS RAM

  • Share subnets, Transit Gateways, Resolver rules, prefix lists, IPAM pools, Private CA, Network Firewall policies, and more.
  • With org sharing enabled, shares inside the org need no invitation.
  • VPC sharing: participants launch into shared subnets but cannot modify the owner’s VPC, route tables, or each other’s resources.
  • Restrict sharing outside the org with ram:RequestedAllowsExternalPrincipals in an SCP.

AWS Service Catalog

  • Portfolio of products (CloudFormation or Terraform).
  • Launch constraint: an IAM role that provisions, so end users need no service permissions.
  • Template constraint limits parameters; TagOptions enforce tags.
  • Share portfolios with OUs or the org; recipients import them.

Exam signal: “users must deploy approved resources without having permissions to create them” → Service Catalog with a launch constraint.

Exam-style scenarios

Deployment and sharing decisions

Look for the managed, organization-aware option first.

ScenarioAnswerWhy
Every new account must get the same security IAM roles automaticallyService-managed StackSet with automatic deployment to the OUDeploys on account join
Ensure all ALBs in the org have the same WAF web ACL, including future onesFirewall Manager WAF policy with auto-remediationApplies to new resources too
One central network team owns the VPC; app accounts deploy into itVPC sharing via AWS RAMParticipants cannot change network config
Pipeline must fail if a Terraform plan creates an unencrypted bucketCheckov or Trivy scan in CIPolicy as code before deploy
Developers launch approved EMR clusters without EMR permissionsService Catalog product with launch constraintRole provisions on their behalf
Tag values must be standardized and the tag must exist on new instancesTag policy plus SCP with aws:RequestTag conditionTag policies do not require presence
Chapter 2 · Part 2.7

Compliance evaluation

Continuously evaluate resources, remediate drift automatically, and collect audit evidence.

Task 6.3.1 · AWS Config

How AWS Config evaluates compliance

The configuration recorder captures resource state; rules evaluate it; aggregators give the org-wide view.

Recorder

  • Records configuration items for chosen resource types.
  • Continuous or daily recording frequency.
  • Delivers history and snapshots to S3; streams changes to SNS.
  • Must be on in every account and Region you govern.

Rules

  • Managed rules (e.g. s3-bucket-public-read-prohibited).
  • Custom rules: Lambda or Guard (custom policy) rules.
  • Triggers: configuration change or periodic.
  • Evaluation modes: detective, and proactive for supported rules.

At org scale

  • Aggregator: org-wide compliance and inventory in one account.
  • Conformance pack: a set of rules and remediations deployed as one unit.
  • Organization conformance packs / rules from the delegated admin.
  • Sample packs map to CIS, NIST, PCI, and operational best practices.
Task 6.3.1 · Auto-remediation

Detect → notify → remediate

Config remediation runs Systems Manager Automation runbooks; EventBridge covers everything else.

Config rule

  • Resource becomes NON_COMPLIANT.
  • Evaluation recorded in Config.
→

Remediation action

  • SSM Automation document.
  • Manual or automatic, with retries.
→

Automation role

  • Assumed by SSM.
  • Least privilege for the fix.
→

Notify

  • EventBridge rule on compliance change.
  • SNS, chat, ticket.
aws configservice put-remediation-configurations \
 --remediation-configurations '[{
  "ConfigRuleName": "s3-bucket-public-read-prohibited",
  "TargetType": "SSM_DOCUMENT",
  "TargetId": "AWS-DisableS3BucketPublicReadWrite",
  "Automatic": true,
  "MaximumAutomaticAttempts": 3, "RetryAttemptSeconds": 60,
  "Parameters": {
   "AutomationAssumeRole": {"StaticValue": {"Values":
     ["arn:aws:iam::111122223333:role/ConfigFix"]}},
   "S3BucketName": {"ResourceValue": {"Value": "RESOURCE_ID"}}}}]'

Design notes

  • Start with manual remediation, then switch to automatic.
  • Exclude resources that are intentionally public (e.g. via tags in the rule scope).
  • Prevent the drift in the first place with SCPs or declarative policies.
Task 6.3.1 · Security Hub CSPM

Security Hub CSPM standards and controls

CSPM runs automated security checks (backed by Config rules) and aggregates findings across the org.

Standards

  • AWS Foundational Security Best Practices (FSBP).
  • CIS AWS Foundations Benchmark (several versions, incl. v5.0).
  • NIST SP 800-53 Rev. 5 and NIST SP 800-171 Rev. 2.
  • PCI DSS and AWS Resource Tagging Standard.
  • Service-managed standard for Control Tower.

How it works

  • Controls are evaluated by service-linked Config rules: Config recording must be on.
  • Central configuration: configuration policies from the delegated admin set standards and controls per OU.
  • Cross-Region aggregation into a home Region.
  • Consolidated control findings: one finding per control across standards.

Relation to the new Security Hub

  • The original service is now called Security Hub CSPM (ASFF findings).
  • The new Security Hub (GA Dec 2025) correlates CSPM, GuardDuty, Inspector, and Macie into exposures using OCSF.
  • Detail lives in the Detection chapter.
Task 6.3.2–6.3.3 · Audit evidence

Collecting evidence and reviewing architecture

Know which service answers “prove it to the auditor” and which answers “give me AWS’s own reports”.

ServiceWhat it gives youNotes
AWS Audit ManagerContinuous evidence collection mapped to frameworks (CIS, PCI DSS, HIPAA, SOC 2, GDPR, custom)Evidence from Config, Security Hub CSPM, CloudTrail, API calls; delegated admin. Maintenance mode: closed to new customers from 30 Apr 2026
AWS ArtifactAWS’s own compliance reports (SOC, ISO, PCI AoC) and agreements (e.g. BAA)Download on demand; accept agreements for an account or the org
AWS Config conformance packsContinuous compliance against framework-mapped rulesAWS’s recommended alternative to Audit Manager for new customers
AWS Well-Architected ToolWorkload review against the six pillars, incl. SecurityLenses, milestones, improvement plans
AWS Trusted AdvisorAccount checks incl. security (MFA on root, open ports, exposed keys)Full checks need Business Support+ or higher

Audit Manager collects evidence about *your* resources; Artifact provides evidence about *AWS’s* controls. “Download the SOC 2 report” → Artifact.

Exam-style scenarios

Compliance evaluation decisions

Separate “detect”, “fix”, and “prove” in the question.

ScenarioAnswerWhy
See noncompliant resources across all accounts and Regions in one placeConfig aggregator in the delegated admin accountOrg-wide view of rules and inventory
Automatically close public access on noncompliant bucketsConfig rule with automatic SSM Automation remediationNative detect-and-fix loop
Deploy the same 30 rules plus remediations to every accountOrganization conformance packOne unit, deployed org-wide
Enable FSBP in all accounts with different controls for the sandbox OUSecurity Hub CSPM central configuration policiesPer-OU configuration from delegated admin
Auditor asks for AWS’s PCI DSS Attestation of ComplianceAWS ArtifactAWS-provided report
Security Hub CSPM controls show “no data” in a new RegionEnable AWS Config recording thereControls rely on Config rules
Exam traps · Compliance

Why compliance answers fail

Most traps confuse detection with prevention or ignore a dependency.

Dependencies

  • Security Hub CSPM controls need Config recording.
  • Firewall Manager needs Config in every in-scope account.
  • Aggregators need authorization or org integration.

Detect vs prevent

  • A Config rule never blocks a change.
  • Pair detective rules with SCPs or declarative policies.
  • Remediation runs after the resource already existed.

Evidence

  • Artifact = AWS’s compliance; Audit Manager = yours.
  • Well-Architected Tool is a review, not continuous monitoring.
  • Trusted Advisor’s full security checks need a paid support plan.
Self-check

Security foundations and governance

Answer out loud, then check the slide that covers it.

Organizations and policies

  • Why is nothing allowed to run in the management account?
  • An action is allowed at the root but missing from an OU SCP. What happens?
  • When do you choose an RCP over an SCP?
  • Why can’t a custom RCP contain an Allow?
  • What does a declarative policy do that an SCP cannot?

Perimeters and root

  • Which condition keys implement each data perimeter?
  • Why does an identity perimeter need aws:PrincipalIsAWSService?
  • How do you fix a bucket policy that denies everyone?
  • What happens to root credentials of new accounts after centralizing root access?
  • What makes a break-glass design trustworthy?

Deployment and compliance

  • How do the three Control Tower control behaviors differ?
  • What is the difference between self- and service-managed StackSets?
  • Why are tag policies not enough to require tags?
  • What does Firewall Manager need before it works?
  • Audit Manager vs Artifact: who is the evidence about?
Chapter 3

Identity and access management

Who can authenticate, what they may do, and how to prove least privilege at scale. Domain 4 · 20% of the exam.

Chapter 3 · Part 3.1

Human identity and federation

Workforce sign-in with IAM Identity Center, an external IdP, MFA, and AWS Directory Service.

Task 4.1.1 · Identity map

Four kinds of identity, four different answers

Pick the identity mechanism from who is calling, not from habit. Long-term access keys are the last resort.

CallerRecommended mechanismCredential it ends up withAvoid
Workforce humansIAM Identity Center + external IdP (SAML 2.0 + SCIM)Role session via a permission set (1–12 h)IAM users with passwords and keys
Customers of your appAmazon Cognito user pool (+ identity pool for AWS calls)JWTs; optional scoped STS credentialsCreating IAM principals per customer
AWS computeInstance profile, ECS task role, Lambda execution role, EKS Pod Identity / IRSAAuto-rotated STS credentialsKeys baked into AMIs, images or env vars
CI/CD outside AWSOIDC federation (AssumeRoleWithWebIdentity)Short session per jobStatic keys stored as CI secrets
On-premises serversIAM Roles Anywhere (X.509 certificates)STS session from a certificateLong-term IAM user keys
Break-glassRoot (centralized root access) or a vaulted emergency roleShort, audited sessionDaily use of root

Exam heuristic: “temporary credentials”, “no long-term keys”, “centrally managed workforce access across accounts” almost always points to IAM Identity Center or STS federation.

Task 4.1.1 · IAM Identity Center

How Identity Center is built

One organization instance, one identity source, and permission sets pushed into member accounts as IAM roles.

Instances

  • Organization instance: enabled in the management account; can delegate administration to a member account.
  • Account instance: scoped to one account, for application access only; no multi-account permission sets.
  • One organization instance, in one home Region.

Identity source (pick one)

  • Identity Center directory: users and groups stored in Identity Center.
  • Active Directory: AWS Managed Microsoft AD, or self-managed AD through AD Connector.
  • External IdP: Okta, Entra ID, Ping, Google — SAML 2.0 for sign-in, SCIM for provisioning.

What users get

  • The AWS access portal lists accounts and roles they are assigned.
  • Console access or CLI via aws configure sso / aws sso login.
  • Access to Identity Center-enabled apps (SAML apps, Amazon Q, etc.).
  • Trusted identity propagation passes the user identity to some analytics services.

Run Identity Center administration from a delegated admin account so the management account is not used day to day. Permission sets that target the management account can only be managed from the management account itself.

Task 4.1.1 · Permission sets

Permission sets become roles in every assigned account

Assign (group or user) × (permission set) × (account). Identity Center creates and owns the IAM role.

What a permission set holds

  • AWS managed policies and/or customer managed policy references (by name and path).
  • One inline policy.
  • An optional permissions boundary.
  • Session duration: default 1 h, range 1–12 h.
  • Optional relay state (default console page).

What appears in the account

  • IAM role AWSReservedSSO_<PermissionSet>_<hash> under path /aws-reserved/sso.amazonaws.com/.
  • A SAML provider that only Identity Center uses.
  • The role trust policy only allows Identity Center; do not edit it.
  • Changes to the permission set are re-provisioned to every assigned account.

Design tips

  • Map IdP groups to job functions, not to people.
  • Use customer managed policies for per-account resource ARNs.
  • Short session durations for admin sets; longer only when justified.
  • Reference roles in resource policies with aws:PrincipalArn + ArnLike on the AWSReservedSSO_* name, because the hash suffix differs per account.

Trap: a customer managed policy reference only works if a policy with exactly that name and path exists in each target account. Otherwise provisioning to that account fails.

Task 4.1.1 · External IdP

SAML signs users in; SCIM keeps users and groups in sync

Identity Center needs the user and group objects to exist before an assignment can apply. SCIM provides them automatically.

1 · Provision (SCIM)

  • IdP pushes users, groups and memberships to the Identity Center SCIM endpoint.
  • Uses a bearer access token generated in Identity Center; rotate it before expiry.
→

2 · Sign in (SAML 2.0)

  • User opens the access portal; Identity Center redirects to the IdP.
  • IdP authenticates the user (and enforces its own MFA) and posts a SAML assertion.
→

3 · Match

  • Assertion NameID / subject must match the provisioned username.
  • Optional attributes become session tags for ABAC.
→

4 · Access

  • User picks an account and permission set.
  • Identity Center federates into the AWSReservedSSO_* role; CloudTrail shows the user name as the session name.

Without SCIM you must create users and groups in Identity Center manually with matching usernames. Exam answer for “groups in the corporate IdP should automatically control AWS access” is SCIM provisioning plus group-based assignments.

Task 4.1.1 · MFA

Multi-factor authentication everywhere a human signs in

Where MFA is enforced depends on who owns the sign-in.

IAM users and root

  • Up to 8 MFA devices per user or root user.
  • Types: passkeys / FIDO2 security keys, virtual authenticator apps (TOTP), hardware TOTP tokens.
  • AWS enforces MFA for root users of all account types (completed Jun 2025); centralized root access can remove member root credentials entirely.

IAM Identity Center

  • Identity Center directory or AD source: configure MFA in Identity Center (every sign-in or context-aware; FIDO2 or authenticator apps).
  • External IdP: MFA is performed by the IdP; Identity Center trusts the assertion.
  • Option to require users to register a device at sign-in.

Enforce in policy

  • aws:MultiFactorAuthPresent is only present for credentials obtained with MFA.
  • Use BoolIfExists in a Deny so long-term access keys (key absent) are also denied.
  • aws:MultiFactorAuthAge limits how long ago MFA happened.
{ "Sid": "DenyAllExceptMfaSetupWithoutMfa", "Effect": "Deny",
  "NotAction": ["iam:CreateVirtualMFADevice", "iam:EnableMFADevice", "iam:ListMFADevices", "sts:GetSessionToken"],
  "Resource": "*",
  "Condition": { "BoolIfExists": { "aws:MultiFactorAuthPresent": "false" } } }
Task 4.1.1 · AWS Directory Service

Managed Microsoft AD, AD Connector, or Simple AD

The exam tests which one fits connectivity, trust, and feature requirements.

AWS Managed Microsoft ADAD ConnectorSimple AD
What it isReal Microsoft AD domain controllers run by AWS (Standard or Enterprise edition)Proxy that forwards requests to your on-premises AD; stores nothingSamba 4–based AD-compatible directory
Trusts with on-prem ADYes (one-way or two-way forest trusts)N/A — uses on-prem AD directlyNo
Works when on-prem is downYesNo — needs VPN/Direct Connect to on-prem DCsYes
MFARADIUS-based MFARADIUS-based MFANo
Typical useAD-aware workloads in AWS (RDS SQL Server, FSx for Windows), multi-Region replication (Enterprise)Sign in to Identity Center, WorkSpaces, console with existing corporate accountsSmall, basic AD needs at low cost

Scenario cue: “users must sign in with existing on-premises AD credentials and no directory data may be stored in AWS” → AD Connector. “Need AD in AWS that keeps working if the data center link fails” → AWS Managed Microsoft AD with a trust.

Task 4.1.3 · Troubleshooting sign-in

Authentication failures: symptom, cause, where to look

Start with CloudTrail sign-in and STS events, then the identity source.

SymptomLikely causeEvidence
SAML sign-in fails with “invalid assertion”Clock skew, wrong ACS URL / audience, expired IdP certificate, NameID not matching an Identity Center userIdP logs; CloudTrail signin.amazonaws.com / Identity Center events
User signs in but sees no accountsNo assignment for the user or their group, or the group was not provisioned by SCIMIdentity Center assignments; SCIM sync status in the IdP
Assignment shows “provisioning failed”Customer managed policy or boundary missing in the target account; SCP blocks IAM role creationPermission set provisioning status
AssumeRoleWithSAML AccessDeniedRole trust policy does not trust the SAML provider, or SAML:aud condition mismatchCloudTrail AssumeRoleWithSAML event
Cognito NotAuthorizedExceptionWrong app client / secret, disabled user, unconfirmed account, auth flow not enabledCognito user pool logs; CloudTrail
AD users cannot log in through AD ConnectorNetwork path or DNS to on-prem DCs broken; service account password changedDirectory health, VPC routes, security groups
Domain 4 · Exam traps

Human identity: traps that cost points

Read the requirement word by word; most wrong answers are almost right.

Traps

  • Creating IAM users per employee when the question says “centrally manage access to many accounts”.
  • Expecting Identity Center MFA settings to apply when an external IdP is the source — the IdP does MFA.
  • Editing an AWSReservedSSO_* role in an account — Identity Center overwrites or breaks it.
  • Choosing Simple AD when a trust with on-premises AD is required.

Also remember

  • SAML without SCIM means users and groups must exist in Identity Center already.
  • Permission set session duration is 1–12 h; the role it creates allows up to 12 h.
  • AD Connector stores no directory data and depends on connectivity to on-prem.
  • aws:MultiFactorAuthPresent is absent, not false, for long-term keys.
Domain 4 · Exam-style scenarios

Human identity: scenario → answer → why

Practice choosing the least operational overhead option that meets every constraint.

ScenarioAnswerWhy
500 employees in Entra ID need role-based access to 40 accounts; leavers must lose access immediatelyIdentity Center with Entra ID as external IdP, SCIM provisioning, group assignmentsDisabling the user in the IdP removes access; no per-account IAM
Developers need a read-only role in prod and admin in sandboxTwo permission sets assigned to the same group on different accountsAssignments are per account
Auditors may use the console for 2 hours onlyPermission set with 2 h session durationSession duration is set per permission set
Windows workloads on EC2 must join the corporate domain even if the VPN dropsAWS Managed Microsoft AD with a forest trust to on-premDomain controllers run in AWS
IAM users must use MFA for every API call except enrolling a deviceDeny with NotAction + BoolIfExists aws:MultiFactorAuthPresent falseCovers both console and long-term key calls
Chapter 3 · Part 3.2

Customer and application identity

Amazon Cognito for end users and Amazon Verified Permissions for fine-grained app authorization.

Task 4.1.1 · Amazon Cognito

User pools authenticate; identity pools hand out AWS credentials

They are separate services that are often used together.

User poolIdentity pool (federated identities)
PurposeUser directory and OIDC/OAuth 2.0 authorization serverExchange an identity token for temporary AWS credentials
OutputID token, access token, refresh token (JWTs)STS credentials for an IAM role
Sign-in sourcesLocal users, social IdPs, SAML and OIDC IdPs, managed login pagesUser pool, social IdPs, SAML/OIDC IdPs, developer-authenticated, guest
Security featuresMFA (SMS, TOTP, email), passkeys, threat protection (adaptive auth, compromised credentials) in the Plus planAuthenticated vs unauthenticated roles; role mapping by rules or token claims
Consumed byAPI Gateway Cognito authorizer, ALB authenticate-cognito, your backendMobile/web clients calling S3, DynamoDB, IoT directly

Exam cue: “users must upload directly to their own S3 prefix from a mobile app” → user pool sign-in + identity pool credentials + policy using ${cognito-identity.amazonaws.com:sub} in the resource ARN.

Task 4.1.1 · Identity pool roles

Lock the identity pool role trust policy to your pool

Identity pool roles are assumed with web identity. The conditions are what keep other pools out.

{
  "Effect": "Allow",
  "Principal": { "Federated": "cognito-identity.amazonaws.com" },
  "Action": ["sts:AssumeRoleWithWebIdentity", "sts:TagSession"],
  "Condition": {
    "StringEquals": {
      "cognito-identity.amazonaws.com:aud": "us-east-1:1111aaaa-...-pool-id"
    },
    "ForAnyValue:StringLike": {
      "cognito-identity.amazonaws.com:amr": "authenticated"
    }
  }
}

How it works

  • Enhanced (simplified) flow: GetId → GetCredentialsForIdentity; Cognito calls STS for you. Recommended.
  • Basic (classic) flow: client calls GetOpenIdToken and then STS itself; off by default — keep it off.
  • Role choice: default authenticated/unauthenticated role, a role from token claims (cognito:preferred_role from user pool groups), or rules on claims.
  • Map IdP claims to principal tags for ABAC.
  • Keep the unauthenticated (guest) role minimal, or disable guest access.

Trap: a trust policy without the aud condition lets identities from any identity pool assume the role.

Task 4.2.1 · Amazon Verified Permissions

Fine-grained authorization for your own application

IAM authorizes calls to AWS APIs. Verified Permissions authorizes actions inside your app, using the Cedar policy language.

// Cedar: managers may approve expenses under 1000 in their own department
permit (
  principal in Role::"manager",
  action == Action::"ApproveExpense",
  resource
) when {
  resource.amount < 1000 &&
  resource.department == principal.department
};

forbid (principal, action, resource)
when { resource.status == "locked" };

Building blocks

  • Policy store: container of policies, a schema, and identity sources.
  • Schema: entity types, attributes, and actions; validates policies.
  • Identity source: Cognito user pool or OIDC IdP; pass the token to IsAuthorizedWithToken.
  • Policy templates: e.g. “share document X with user Y” per grant.
  • Default deny; forbid always overrides permit — same idea as IAM explicit deny.
  • Decisions are logged in CloudTrail for audit.
Domain 4 · Exam traps and scenarios

Customer identity: traps and scenarios

The distractors usually mix up the two Cognito pools or use IAM for app-level permissions.

Traps

  • User pool alone does not give AWS credentials; an identity pool does.
  • Identity pool alone does not store users or passwords.
  • Do not create IAM users or roles per customer — use one role with policy variables or ABAC.
  • IAM cannot express “user may edit only invoices they own in our app database”; that is Verified Permissions or app code.

Scenarios

ScenarioAnswer
API must accept only signed-in app usersAPI Gateway Cognito user pool authorizer (or JWT authorizer)
Block sign-ins from leaked passwordsUser pool threat protection (Plus plan)
Corporate partners sign in to a customer app with their SAML IdPUser pool SAML federation
Externalize document sharing rules out of codeVerified Permissions with Cedar policy templates
Chapter 3 · Part 3.3

Workload identity and temporary credentials

STS, role sessions, OIDC federation, EKS workloads, on-premises servers, and presigned URLs.

Task 4.1.2 · AWS STS

The STS API family

Every temporary credential in AWS comes from one of these calls.

APIWho calls itDurationTypical use
AssumeRoleIAM user or role session15 min – role max (1–12 h); 1 h max when chainingCross-account access, switching roles
AssumeRoleWithSAMLAnyone with a SAML assertion15 min – role maxWorkforce federation without Identity Center
AssumeRoleWithWebIdentityAnyone with an OIDC token15 min – role maxGitHub Actions, IRSA, Cognito basic flow
GetSessionTokenIAM user (or root)15 min – 36 h (root: max 1 h)MFA-protected API calls with an IAM user
GetFederationTokenIAM user (custom broker)15 min – 36 h (root: max 1 h)Legacy identity broker; session policy required to grant
AssumeRootManagement or delegated admin accountUp to 15 minPrivileged root tasks in member accounts

A role’s maximum session duration (1–12 h) does not apply to EC2 instance profile credentials or to sessions AWS services assume for you. Default DurationSeconds is 1 h.

Task 4.1.2 · Role sessions

What a role session carries — and how to kill one

Session attributes travel with every call and show up in CloudTrail.

Session attributes

  • Session name: shows in the assumed-role ARN; enforce with sts:RoleSessionName.
  • Source identity (sts:SetSourceIdentity): set once, persists through role chaining; use for “who really did it”.
  • Session tags (sts:TagSession): become aws:PrincipalTag/*; can be marked transitive for chaining.
  • Session policies: further restrict the session.

Role chaining

  • A role session assuming another role = chaining.
  • Chained sessions are limited to 1 hour.
  • Trust policy of the second role must trust the first role (or its account).
  • Avoid deep chains; they make attribution hard unless source identity is set.

Revoke active sessions

  • Temporary credentials cannot be deleted; they expire.
  • Console “Revoke active sessions” adds inline policy AWSRevokeOlderSessions.
  • It denies everything when aws:TokenIssueTime is earlier than the revoke time.
  • For instance roles, also stop the instance or remove the role, or new credentials keep flowing.
{ "Effect": "Deny", "Action": "*", "Resource": "*",
  "Condition": { "DateLessThan": { "aws:TokenIssueTime": "2026-10-18T09:30:00Z" } } }
Task 3.2.2 / 4.1.2 · Compute roles

Which role does the compute service use?

Questions often hinge on picking the right role for the right job.

ServiceRoleUsed byCommon mistake
EC2Instance profile (wraps one role)Code on the instance via IMDS (use IMDSv2)Copying credentials off the instance; IMDSv1 SSRF exposure
ECSTask roleYour application containersGranting app permissions to the execution role
ECSTask execution roleECS agent: pull images from ECR, fetch secrets, write logsMissing secretsmanager:GetSecretValue → task fails to start
LambdaExecution roleFunction code and Lambda loggingMissing logs:CreateLogStream / PutLogEvents → no logs
EKSPod Identity association or IRSA rolePods via their service accountUsing the node role for every pod
Any serviceService role / service-linked roleThe service acting on your behalfEditing service-linked roles (they are managed by the service)

iam:PassRole is the permission that lets a human hand a role to a service. Scope it to specific role ARNs and use iam:PassedToService — unrestricted iam:PassRole is a classic privilege-escalation path.

Task 4.1.2 · OIDC federation

GitHub Actions to AWS without stored keys

The job gets an OIDC token from GitHub, then calls AssumeRoleWithWebIdentity.

{
  "Effect": "Allow",
  "Principal": {
    "Federated":
     "arn:aws:iam::111122223333:oidc-provider/token.actions.githubusercontent.com"
  },
  "Action": "sts:AssumeRoleWithWebIdentity",
  "Condition": {
    "StringEquals": {
      "token.actions.githubusercontent.com:aud": "sts.amazonaws.com"
    },
    "StringLike": {
      "token.actions.githubusercontent.com:sub":
        "repo:my-org/payments:ref:refs/heads/main"
    }
  }
}

Checklist

  • Create one IAM OIDC identity provider per account for token.actions.githubusercontent.com.
  • Always pin sub to org/repo and branch, tag or environment (repo:org/repo:environment:prod).
  • Separate roles for plan vs apply, and for prod vs non-prod.
  • Workflow needs permissions: id-token: write.
  • Same pattern works for GitLab, Bitbucket, Terraform Cloud with their issuer and claims.

Trap: a trust policy that checks only aud lets any GitHub repository in the world assume the role.

Task 4.1.2 · EKS workloads

IRSA vs EKS Pod Identity

Both give each Kubernetes service account its own IAM role. Pod Identity is the newer, simpler default.

IRSAEKS Pod Identity
MechanismProjected service account token → AssumeRoleWithWebIdentity by the SDKPod Identity Agent on the node → eks-auth:AssumeRoleForPodIdentity
IAM setupOne IAM OIDC provider per cluster; trust policy names the cluster issuer and system:serviceaccount:ns:saTrust principal pods.eks.amazonaws.com, actions sts:AssumeRole + sts:TagSession; no OIDC provider
BindingAnnotation eks.amazonaws.com/role-arn on the service accountPod Identity association created through the EKS API
Reuse across clustersEdit the trust policy for every new clusterSame role, new association; trust policy unchanged
ABACLimitedSession tags such as eks-cluster-name, kubernetes-namespace, kubernetes-service-account
Where it runsEC2 nodes and FargateLinux EC2 nodes only (not Fargate, not Windows)
Cross-accountTrust the cluster OIDC provider in the other accountRole must be in the cluster account; chain to other accounts

In both cases, block pods from using the node role: enforce IMDSv2 with a hop limit of 1 on nodes so containers cannot reach instance credentials.

Task 4.2.1 · IAM Roles Anywhere

Temporary credentials for servers outside AWS

On-premises or other-cloud workloads present an X.509 certificate instead of storing access keys.

Components

  • Trust anchor: AWS Private CA, or your own CA certificate bundle.
  • Profile: which roles may be assumed, session duration, optional session policies.
  • Role trust: principal rolesanywhere.amazonaws.com, actions sts:AssumeRole, sts:TagSession, sts:SetSourceIdentity.
  • Optional CRL import to revoke certificates.

Least privilege

  • Condition on certificate attributes, e.g. aws:PrincipalTag/x509Subject/CN.
  • Condition on aws:SourceArn = the trust anchor ARN.
  • Keep private keys in a TPM or HSM where possible.
  • Short certificate lifetimes plus automated renewal.
# ~/.aws/config on the server: the signing helper exchanges the certificate for STS credentials
[profile onprem]
credential_process = aws_signing_helper credential-process \
    --certificate /etc/pki/app.pem --private-key /etc/pki/app.key \
    --trust-anchor-arn arn:aws:rolesanywhere:us-east-1:111122223333:trust-anchor/TA_ID \
    --profile-arn arn:aws:rolesanywhere:us-east-1:111122223333:profile/PROFILE_ID \
    --role-arn arn:aws:iam::111122223333:role/onprem-backup
Task 4.1.2 · S3 presigned URLs

Presigned URLs: time-boxed access with the signer’s permissions

Anyone holding the URL can perform that one operation until it expires.

# Download link valid for 15 minutes
aws s3 presign s3://reports-bucket/2026/q3.pdf --expires-in 900

# Upload: presigned PUT (or POST policy) from the SDK
#   generate_presigned_url("put_object", ..., ExpiresIn=300)

Rules

  • The request runs with the signer’s permissions at the time of use.
  • SigV4 maximum expiry is 7 days (with IAM user credentials).
  • Signed with temporary credentials → stops working when those credentials expire, even if expires-in is longer.
  • Revoke early by removing the signer’s permission or deactivating its key.
  • Restrict use with bucket policy conditions such as aws:SourceIp, aws:SourceVpce, or s3:signatureAge.

For many objects or a whole site, prefer CloudFront signed URLs or signed cookies; presigned URLs are per object and per operation.

Domain 4 · Exam traps

Workload identity: traps

These distinctions appear in multiple-response and matching questions.

Credential lifetime

  • Role chaining caps the session at 1 hour, regardless of role max.
  • Presigned URL from a role session dies with the session.
  • GetSessionToken cannot call IAM APIs unless MFA was included.
  • Revoking sessions does not stop an EC2 instance from fetching new credentials.

Trust policies

  • OIDC trust without a sub condition is open to every repo or cluster.
  • Cognito trust without aud is open to every identity pool.
  • Cross-account trust of arn:aws:iam::ACCOUNT:root means “any principal in that account that is allowed by its own policies”.
  • Third-party roles need sts:ExternalId.

Roles

  • ECS: app permissions belong on the task role, not the execution role.
  • Pod Identity does not work on Fargate; IRSA does.
  • Unscoped iam:PassRole = privilege escalation.
  • Instance profile credentials ignore the role max session duration.
Domain 4 · Exam-style scenarios

Workload identity: scenario → answer → why

Look for “no long-term credentials” and “least operational overhead”.

ScenarioAnswerWhy
Jenkins on-prem needs to push to ECR; security bans access keysIAM Roles Anywhere with the corporate CA as trust anchorCertificate-based STS credentials
Leaked keys found in a public repo were used to start EC2Deactivate the keys, revoke sessions of any role assumed, review CloudTrail, then deleteTemporary sessions created from the key survive key deactivation until revoked
Ten EKS clusters share one IAM role for a logging agentEKS Pod Identity associationsNo per-cluster trust policy edits
Partner SaaS needs read access to your accountCross-account role with sts:ExternalId conditionPrevents the confused deputy problem
Users must download a private file for 10 minutes without AWS accountsS3 presigned URL with 600 s expiry from a backend roleTime-boxed, per-object access
Chapter 3 · Part 3.4

Policy evaluation logic

How AWS decides allow or deny across every policy type, in one account and across accounts.

Task 4.2.1 · Policy types

Seven policy types: some grant, some only cap

Knowing which category a policy belongs to answers most “why is this denied” questions.

Policy typeAttached toGrants?Notes
Identity-basedUser, group, roleYesManaged (default 10 per user / 20 per role; quota up to 20 / 25) or inline
Resource-basedBucket, key, queue, topic, secret, role trust, Lambda…YesHas a Principal; enables cross-account access
Permissions boundaryUser or roleNo — caps identity-basedManaged policy; used for delegation
SCPRoot, OU, accountNo — caps principals in member accountsNot the management account; not service-linked roles
RCPRoot, OU, accountNo — caps access to resources in member accountsApplies to external principals too; subset of services
Session policyPassed at AssumeRole* / GetFederationTokenNo — caps the sessionOne inline + up to 10 managed ARNs
VPC endpoint policy / ACLsEndpoint; S3 bucket or objectEndpoint: caps; ACL: grants (legacy)Disable S3 ACLs with Object Ownership “bucket owner enforced”
Task 4.2.1 · Evaluation flow

The decision, step by step

Default is implicit deny. Any explicit deny ends evaluation. Every guardrail that applies must allow.

1 · Explicit deny?

  • Any Deny that matches in any policy type → denied.
→

2 · RCP

  • Resource in a member account: RCPs must allow (the default RCPFullAWSAccess does).
→

3 · SCP

  • Principal in a member account: SCPs at every level from root to account must allow.
→

4 · Resource policy

  • Same account: an allow here can be enough (see next slide).
→

5 · Identity + boundary + session

  • Identity policy must allow, within the boundary and session policy if present.

Cross-account: the request must be allowed by the caller’s side (identity policy, boundary, session policy, caller’s SCPs) and by the resource side (resource policy, resource owner’s RCPs). Neither side alone is enough.

Implicit deny vs explicit deny matters for troubleshooting: an implicit deny is fixed by adding an allow; an explicit deny must be removed or narrowed.

Task 4.2.1 · Same-account nuances

When a resource policy alone is enough

Within one account, identity-based and resource-based permissions are a union — with exceptions that depend on which principal ARN is named.

Resource policy names…Limited by implicit deny in identity policy?Limited by implicit deny in boundary / session policy?
IAM user ARNNoNo (boundary)
IAM role ARNNoYes — boundary or session policy must also allow
Role session ARN (assumed-role/...)NoNo — granted directly to the session
Federated user ARN (GetFederationToken session)NoNo
Account (arn:aws:iam::ACCOUNT:root)Yes — delegates to IAM: identity policy must allowYes

Explicit denies always win, in every row. KMS keys are the main exception to the union rule: the key policy must allow, see the next slides.

Task 4.2.1 · Cross-account access

Two patterns for cross-account access

Resource-based policy (caller keeps its identity) vs role assumption (caller becomes a principal of the other account).

A · Resource-based policy

  • Bucket/queue/key policy in account B names a principal in account A.
  • Principal in A also needs an identity policy allow.
  • Caller stays in A: A’s SCPs apply, plus B’s RCPs on the resource.
  • Objects written by A into B’s bucket are owned by B when ACLs are disabled (bucket owner enforced).

B · Assume a role in account B

  • B’s role trust policy trusts A (account, role, or with conditions).
  • A’s identity policy allows sts:AssumeRole on that role ARN.
  • After assuming, the session is a principal of B: B’s SCPs and the role’s policies apply; A’s policies no longer matter.
  • Simpler to audit, but only one account’s permissions at a time.

Choose

  • Need to read from A and write to B in one call (e.g. copy objects)? Use a resource-based policy.
  • Many services or broad administration in B? Use a role.
  • Restrict to your organization with aws:PrincipalOrgID in resource policies.
  • Services without resource policies only support pattern B.
Task 4.2.1 · Trust and confused deputy

Trust policies and the confused deputy problem

A deputy (a service or a vendor) is tricked into using its access on someone else’s resource.

// Vendor role: require the agreed ExternalId
{ "Effect": "Allow",
  "Principal": { "AWS": "arn:aws:iam::999988887777:root" },
  "Action": "sts:AssumeRole",
  "Condition": { "StringEquals": { "sts:ExternalId": "c0ffee-tenant-42" } } }

// AWS service principal writing to your bucket: pin the source
{ "Effect": "Allow",
  "Principal": { "Service": "cloudtrail.amazonaws.com" },
  "Action": "s3:PutObject",
  "Resource": "arn:aws:s3:::org-trail-logs/AWSLogs/*",
  "Condition": {
    "StringEquals": { "aws:SourceAccount": "111122223333" },
    "ArnLike": { "aws:SourceArn":
      "arn:aws:cloudtrail:*:111122223333:trail/*" } } }

Rules

  • Cross-account (vendor): vendor generates a unique ExternalId per customer; you require it in the trust policy.
  • Cross-service: when a service principal acts on your resource, add aws:SourceArn, aws:SourceAccount or aws:SourceOrgID.
  • aws:SourceArn is for service principals; aws:PrincipalArn is for IAM principals.
  • Trust policies are resource-based policies on the role; the caller still needs its own allow (cross-account).
Task 4.2.1 / 5.3.5 · KMS authorization

KMS keys: the key policy is the root of trust

Unlike other resources, an IAM policy alone never grants access to a KMS key.

// Default key policy statement: lets IAM policies in this account work
{ "Sid": "EnableIAMUserPermissions", "Effect": "Allow",
  "Principal": { "AWS": "arn:aws:iam::111122223333:root" },
  "Action": "kms:*", "Resource": "*" }

// Allow use only through S3 in this Region
{ "Sid": "AllowViaS3", "Effect": "Allow",
  "Principal": { "AWS": "arn:aws:iam::111122223333:role/app" },
  "Action": ["kms:Decrypt", "kms:GenerateDataKey"], "Resource": "*",
  "Condition": { "StringEquals": {
    "kms:ViaService": "s3.us-east-1.amazonaws.com" } } }

How KMS decides

  • Every key has exactly one key policy.
  • IAM policies count only if the key policy delegates to the account (the root statement).
  • Grants give temporary, narrow permissions (used by EBS, RDS, etc.).
  • Cross-account: key policy allows the other account and that account’s IAM policy allows the principal.
  • Lose the key policy admins → key is unmanageable until AWS Support helps restore access.
Task 4.2.3 · Conditions

Condition operators and the keys that matter

Most least-privilege controls are conditions, not actions.

Operators

OperatorUse
StringEquals / StringLikeExact or wildcard match
ArnLike / ArnEqualsCompare ARNs (aws:PrincipalArn, aws:SourceArn)
IpAddress / NotIpAddressCIDR checks on aws:SourceIp
Bool, NullTrue/false keys; test key presence
Date*, Numeric*Times, ages, counts
...IfExistsMatch also when the key is absent
ForAnyValue: / ForAllValues:Multi-valued keys such as aws:TagKeys

Global keys

KeyTypical control
aws:PrincipalOrgID / aws:ResourceOrgIDData perimeter: only my org
aws:SourceVpce / aws:SourceVpcOnly through my VPC endpoints
aws:SourceIpPublic IP only — not seen via VPC endpoints
aws:PrincipalTag / aws:ResourceTag / aws:RequestTagABAC
aws:CalledVia, aws:ViaAWSServiceAllow only when a service calls on your behalf
aws:RequestedRegionRegion restriction
aws:SecureTransportRequire TLS
Task 4.2.3 · Pitfalls

Negation and multi-value pitfalls

These four patterns behave differently from how they read.

NotAction with Allow

  • Allows every action except those listed — including new services added later.
  • Use NotAction mostly in Deny statements (e.g. region guardrails that exempt global services).

NotPrincipal with Deny

  • Hard to get right: you must list the account, the role and the session.
  • Always denies principals that have a permissions boundary attached.
  • AWS recommends ArnNotEquals / ArnNotLike on aws:PrincipalArn instead.

ForAllValues on an empty set

  • Evaluates to true when the request has no such key (e.g. no tags).
  • Pair it with a Null check, or use ForAnyValue for “must include”.

Missing keys

  • A condition on a key that is absent fails (no match) unless you use IfExists.
  • aws:SourceIp is absent for calls through VPC endpoints and from AWS services.
  • Test with the Policy Simulator and CloudTrail before enforcing.
Domain 4 · Exam-style scenarios

Policy evaluation: scenario → answer → why

Walk the flow: explicit deny → RCP → SCP → resource → identity/boundary/session.

ScenarioAnswerWhy
Admin role in a member account cannot launch EC2 in eu-west-3An SCP region denySCPs cap even full admins in member accounts
Role in account A gets AccessDenied reading B’s bucket; bucket policy allows A’s roleAdd s3:GetObject to the role’s identity policy in ACross-account needs both sides
Same as above, but the objects are SSE-KMS with B’s keyAlso allow the role in the key policy and its IAM policy for kms:DecryptKMS needs its own authorization
Role assumed with a session policy allowing s3:* cannot write to DynamoDBSession policy caps the session to S3Effective = identity ∩ session
Bucket policy must allow only principals of our orgaws:PrincipalOrgID conditionOne condition covers every current and future account
Chapter 3 · Part 3.5

Least privilege at scale

Boundaries, session policies, ABAC, IAM Access Analyzer, and a method for every AccessDenied.

Task 4.2.3 · Permissions boundaries

Delegate IAM safely with permissions boundaries

Let teams create their own roles, but only roles that carry your boundary — so they can never exceed it.

{ "Sid": "CreateRolesOnlyWithBoundary", "Effect": "Allow",
  "Action": ["iam:CreateRole", "iam:PutRolePermissionsBoundary",
             "iam:AttachRolePolicy", "iam:PutRolePolicy"],
  "Resource": "arn:aws:iam::111122223333:role/app/*",
  "Condition": { "StringEquals": {
    "iam:PermissionsBoundary":
      "arn:aws:iam::111122223333:policy/AppBoundary" } } },
{ "Sid": "NoBoundaryTampering", "Effect": "Deny",
  "Action": ["iam:DeleteRolePermissionsBoundary",
             "iam:CreatePolicyVersion", "iam:SetDefaultPolicyVersion"],
  "Resource": ["arn:aws:iam::111122223333:role/*",
               "arn:aws:iam::111122223333:policy/AppBoundary"] },
{ "Sid": "PassOnlyAppRoles", "Effect": "Allow", "Action": "iam:PassRole",
  "Resource": "arn:aws:iam::111122223333:role/app/*" }

Why each statement matters

  • Creation is allowed only if the new role gets AppBoundary.
  • Developers cannot remove the boundary or edit the boundary policy.
  • The path /app/ scopes what they can create and pass.
  • Also give the developer role itself a boundary, so it cannot grant itself more.
  • Boundaries do not limit resource-based policies that name a user or session directly.
Task 4.2.3 · Session policies

Session policies: one role, many narrow sessions

Pass a policy when assuming a role to get a session that can do less than the role.

# Broker issues tenant-scoped credentials from one shared role
aws sts assume-role \
  --role-arn arn:aws:iam::111122223333:role/tenant-data \
  --role-session-name tenant-42 \
  --policy '{"Version":"2012-10-17","Statement":[{"Effect":"Allow",
     "Action":["s3:GetObject","s3:PutObject"],
     "Resource":"arn:aws:s3:::tenant-data/tenant-42/*"}]}' \
  --duration-seconds 900

Facts

  • Effective permissions = role identity policies ∩ session policy (∩ boundary).
  • One inline JSON (--policy) and up to 10 managed policy ARNs (--policy-arns).
  • Inline policy, ARNs and session tags share a packed size limit; the call fails if it is exceeded.
  • Cannot grant more than the role has.
  • Alternative for multi-tenant: one role + session tags + ABAC conditions.
Task 4.2.2 · ABAC vs RBAC

Attribute-based vs role-based access control

RBAC grows one policy per job per resource set. ABAC writes one policy that compares tags.

RBACABAC
Grant based onRole or group membershipMatching attributes (tags) on principal and resource
New projectNew roles and policiesTag new resources and users; no policy change
Policy countGrows with teams × resourcesSmall and stable
RiskOver-broad roles over timeWhoever can change tags can change access
Best forFew, stable job functionsMany fast-changing projects or tenants
{ "Effect": "Allow",
  "Action": ["ec2:StartInstances", "ec2:StopInstances"],
  "Resource": "arn:aws:ec2:*:*:instance/*",
  "Condition": { "StringEquals": {
    "aws:ResourceTag/project":
      "${aws:PrincipalTag/project}" } } }

Principal tags come from IAM user/role tags, session tags (SAML/OIDC attributes, sts:TagSession), or IAM Identity Center “attributes for access control” mapped from the IdP.

Task 4.2.2 · ABAC hygiene

ABAC only works if tags are trustworthy

Control who can set tags, require tags at creation, and block tag changes on existing resources.

// Create only with my project tag, and only allowed tag keys
{ "Effect": "Allow", "Action": "ec2:RunInstances",
  "Resource": "arn:aws:ec2:*:*:instance/*",
  "Condition": {
    "StringEquals": {
      "aws:RequestTag/project": "${aws:PrincipalTag/project}" },
    "ForAllValues:StringEquals": {
      "aws:TagKeys": ["project", "env", "owner"] } } },

// Nobody but the platform role may change the project tag
{ "Effect": "Deny", "Action": ["ec2:CreateTags", "ec2:DeleteTags"],
  "Resource": "*",
  "Condition": {
    "ForAnyValue:StringEquals": {
      "aws:TagKeys": ["project"] },
    "ArnNotLike": {
      "aws:PrincipalArn": "arn:aws:iam::*:role/platform-admin" } } }

Checklist

  • Require tags on create (aws:RequestTag) and allow the tag action only in the create call.
  • Deny tag modification for the access-controlling keys, ideally as an SCP.
  • Use tag policies to standardize keys and values across the org.
  • Protect principal tags: users must not be able to iam:TagRole themselves.
  • Check each service’s support for aws:ResourceTag in the Service Authorization Reference.
Task 4.2.1 · IAM paths

IAM paths: cheap structure for policies

A path is part of the ARN, so you can scope permissions to a family of roles or policies.

How paths work

  • Example ARN: arn:aws:iam::111122223333:role/team-a/ci/deployer.
  • Set at creation (--path /team-a/ci/); cannot be changed for roles later.
  • Not shown in the friendly name, only in the ARN.
  • Identity Center roles use /aws-reserved/sso.amazonaws.com/.

Uses

  • Delegation: allow iam:CreateRole only on role/team-a/*.
  • iam:PassRole limited to a path.
  • SCP or resource policy exemptions with ArnLike aws:PrincipalArn on role/security/*.
  • Reporting: list roles per path (aws iam list-roles --path-prefix /team-a/).

Limits to know

  • Path + name can be up to 512 + 64 characters.
  • For console “Switch Role”, path + role name must be ≤ 64 characters.
  • Paths are not a security boundary on their own — they only help policies target ARNs.
Task 4.2.4 / 4.2.5 · IAM Access Analyzer

IAM Access Analyzer: three analyzers

Logic-based reasoning (automated reasoning) over policies, not sampling of traffic.

AnalyzerQuestion it answersScopeNotes
External accessWhich resources are shared outside my zone of trust (account or org)?Per Region; create one in every Region you useNo charge. S3, IAM roles, KMS keys, Lambda, SQS, Secrets Manager, SNS, EBS/RDS snapshots, ECR, EFS, DynamoDB
Internal accessWhich principals inside my org/account can reach these critical resources?Selected resources (S3, DynamoDB, RDS snapshots…)Paid per monitored resource
Unused accessWhich roles, keys, passwords, services and actions are unused?Account or org; not Region-specificPaid per IAM role/user analyzed; tracking period is configurable

Findings can be archived automatically with archive rules (e.g. a trusted partner account), sent to EventBridge and Security Hub, and re-checked on demand with StartResourceScan.

Use the organization as the zone of trust with a delegated administrator account, so cross-account access inside the org is not reported as external.

Task 4.2.3 / 4.2.4 · Policy checks

Catch bad policies before they deploy

Validation, custom checks, and policy generation turn least privilege into a pipeline gate.

# 1. Grammar + best practices (no charge)
aws accessanalyzer validate-policy --policy-type IDENTITY_POLICY \
  --policy-document file://policy.json

# 2. Custom checks (charged per call)
aws accessanalyzer check-no-new-access --policy-type IDENTITY_POLICY \
  --existing-policy-document file://old.json --new-policy-document file://new.json
aws accessanalyzer check-access-not-granted --policy-type IDENTITY_POLICY \
  --policy-document file://new.json \
  --access '[{"actions":["iam:PassRole","s3:DeleteBucket"]}]'
aws accessanalyzer check-no-public-access --resource-type AWS::S3::Bucket \
  --policy-document file://bucket-policy.json

# 3. Generate a policy from CloudTrail activity
aws accessanalyzer start-policy-generation \
  --policy-generation-details principalArn=arn:aws:iam::111122223333:role/app \
  --cloud-trail-details file://trail.json

Where to use them

  • Pre-commit / CI: validate every IAM JSON in Terraform or CloudFormation plans.
  • check-no-new-access blocks PRs that widen access.
  • check-access-not-granted blocks sensitive actions or resources.
  • Start broad in dev, generate a policy from real activity, then ship that.
  • Combine with last-accessed data to remove unused services.
Task 4.2.4 · Debugging AccessDenied

A repeatable method for AccessDenied

Read the error message first: most services now say which policy type denied the request.

1 · Read the message

  • ...with an explicit deny in a service control policy → find the SCP.
  • ...because no identity-based policy allows... → add an allow.
  • Also: resource-based, RCP, permissions boundary, session policy, VPC endpoint policy, role trust policy.
  • The policy ARN is included in some cases.

2 · Gather context

  • CloudTrail event: errorCode, principal ARN, source IP, VPC endpoint, sessionContext.
  • EC2 encoded messages: aws sts decode-authorization-message (needs sts:DecodeAuthorizationMessage).
  • aws sts get-caller-identity: are you who you think you are?

3 · Test the fix

  • IAM Policy Simulator: test actions, resources and context keys against identity policies, boundaries and resource policies.
  • Check SCPs/RCPs in the org and KMS key policies separately.
  • Re-run the real call; simulators can miss service-specific behavior.
User: arn:aws:sts::123456789012:assumed-role/app/i-0abc is not authorized to perform:
  secretsmanager:GetSecretValue on resource: arn:aws:secretsmanager:us-east-1:123456789012:secret:db
  with an explicit deny in a resource control policy
Domain 4 · Exam traps

Least privilege: traps

These appear as “which change is MOST secure with LEAST effort” questions.

Boundaries and sessions

  • A boundary never grants; something else must allow.
  • Forgetting to deny boundary removal makes the boundary pointless.
  • Session policies cannot add permissions.
  • Boundaries do not restrict resource policies that name the user or session directly.

ABAC

  • If users can retag resources or themselves, ABAC can be bypassed.
  • ForAllValues on aws:TagKeys passes when no tags are sent.
  • Not every action supports aws:ResourceTag; check the Service Authorization Reference.

Access Analyzer

  • External access analyzers are Regional — one per Region.
  • Zone of trust = account by default; choose organization to avoid noise.
  • Unused access analysis is paid; external access is free.
  • Generation from CloudTrail covers only actions logged in CloudTrail.
Domain 4 · Exam-style scenarios

Least privilege: scenario → answer → why

Prefer managed, scalable controls over hand-maintained lists.

ScenarioAnswerWhy
Developers must create Lambda roles without being able to escalate privilegesPermissions boundary condition iam:PermissionsBoundary + deny boundary removal + scoped iam:PassRoleDelegation pattern
100 projects; each team may manage only its own EC2 and RDSABAC on project tag with tags from the IdP via Identity CenterOne policy scales to all projects
Find all S3 buckets and KMS keys shared outside the organizationIAM Access Analyzer external access analyzer, org zone of trust, every RegionContinuous, reasoning-based findings
Remove permissions a role has not used in 90 daysUnused access analyzer findings or last-accessed data, then policy generationEvidence-based right-sizing
Block any policy change that grants iam:* in the CI pipelinecheck-access-not-granted in CIAutomated gate before deployment
Self-check

Identity and access management: can you explain these?

Answer out loud, then verify in the docs or a sandbox account.

Authentication

  • Why do you need SCIM in addition to SAML for Identity Center?
  • When does Identity Center not enforce its own MFA settings?
  • AD Connector or AWS Managed Microsoft AD — what decides?
  • What do a Cognito user pool and an identity pool each produce?

Temporary credentials

  • Why is a chained role session capped at 1 hour?
  • How do you invalidate credentials already issued for a role?
  • What condition makes a GitHub OIDC trust policy safe?
  • When does a presigned URL stop working before its expiry?

Authorization

  • Walk the evaluation flow for a cross-account S3 read with SSE-KMS.
  • Which principal ARN in a bucket policy is limited by a boundary?
  • Why is NotPrincipal with Deny discouraged?
  • What stops ABAC from being bypassed by retagging?
Chapter 4

Detection

Collect the right logs, detect threats across the organization, alert on what matters, and fix monitoring when it goes quiet. Domain 1 · 16%.

Chapter 4 · Part 4.1

Logging sources

What each AWS log records, where it can go, and what it cannot tell you.

Task 1.2.1 · Choosing sources

Which log answers which question?

Start from the question an investigator will ask, then pick the source that records it.

QuestionSourceDestinations
Who called which AWS API, from where?CloudTrail management eventsS3, CloudWatch Logs, EventBridge
Who read or deleted this S3 object / invoked this Lambda?CloudTrail data eventsS3, CloudWatch Logs
Which calls went through my VPC endpoint (incl. denied)?CloudTrail network activity eventsS3, CloudWatch Logs
Which IPs and ports talked, accepted or rejected?VPC / Transit Gateway flow logsCloudWatch Logs, S3, Firehose
Which domains did workloads resolve?Route 53 Resolver query logsCloudWatch Logs, S3, Firehose
Which HTTP requests hit the edge or the app?CloudFront, ALB, API Gateway, WAF logsPer service (next slides)
What did the OS or application do?CloudWatch agent / app logsCloudWatch Logs

No single log is enough. API activity (CloudTrail), network activity (flow and DNS logs), and request activity (edge and app logs) together let you reconstruct an incident.

Task 1.2.2 · CloudTrail

CloudTrail event types

Management events are on by default in Event history; everything else must be selected on a trail or event data store.

TypeRecordsDefaultNotes
Management eventsControl-plane calls: CreateUser, RunInstances, PutBucketPolicy, console sign-inEvent history: 90 days, freeCreate a trail to keep them longer; first copy of management events per Region is free
Data eventsData-plane calls: S3 GetObject/PutObject, Lambda Invoke, DynamoDB items, and moreOffHigh volume and charged; scope with advanced event selectors
Network activity eventsAPI calls made through a VPC endpoint, including calls denied by the endpoint policyOff (opt-in)Shows who tried to use your endpoint; supports a growing list of services such as EC2, KMS, S3, Secrets Manager
Insights eventsUnusual API call rate or error rate compared with a learned baselineOffManagement events and, since Nov 2025, data events; extra charge

A read-only Describe* storm is a management event. An attacker downloading a bucket is a data event — invisible unless data events are on.

Task 1.2.2 · CloudTrail

Organization trail

One trail, created centrally, logs every account in the organization — and member accounts cannot turn it off.

How it works

  • Created in the management account or a CloudTrail delegated administrator account.
  • Applies to all current and future member accounts.
  • Members can see the trail but cannot modify or delete it.
  • Objects land under AWSLogs/o-xxxx/<account-id>/ in the bucket.

Configure it well

  • Multi-Region trail (the default for new trails).
  • Bucket lives in the Log Archive account, not the management account.
  • SSE-KMS with a customer managed key; enable log file validation.
  • Optionally also send to a CloudWatch Logs group for alarms.
aws cloudtrail create-trail \
  --name org-trail \
  --s3-bucket-name org-trail-logs \
  --is-organization-trail \
  --is-multi-region-trail \
  --enable-log-file-validation \
  --kms-key-id alias/org-trail

aws cloudtrail start-logging \
  --name org-trail

Protect the trail with an SCP that denies cloudtrail:StopLogging, DeleteTrail and UpdateTrail for everyone except a break-glass role.

Task 1.2.2 · CloudTrail

Selecting data events precisely

Advanced event selectors filter by event category, resource type, ARN prefix, read/write and event name.

[
  {
    "Name": "Write data events on the payments bucket",
    "FieldSelectors": [
      { "Field": "eventCategory", "Equals": ["Data"] },
      { "Field": "resources.type", "Equals": ["AWS::S3::Object"] },
      { "Field": "readOnly", "Equals": ["false"] },
      { "Field": "resources.ARN",
        "StartsWith": ["arn:aws:s3:::payments-prod/"] }
    ]
  },
  {
    "Name": "All management events",
    "FieldSelectors": [
      { "Field": "eventCategory", "Equals": ["Management"] }
    ]
  }
]

Why it matters

  • Data events are billed per event: logging every object read in a busy data lake is expensive.
  • Select the sensitive buckets, tables or functions, or only write events.
  • Exclude noisy principals, e.g. userIdentity.arn NotStartsWith a backup role.
  • Apply with aws cloudtrail put-event-selectors --advanced-event-selectors file://sel.json.
Task 1.2.2 · CloudTrail

Integrity, delivery and CloudTrail Lake

Know how CloudTrail proves its logs were not changed, how fast it delivers, and where Lake stands today.

Log file integrity validation

  • CloudTrail writes an hourly digest file containing SHA-256 hashes of each log file.
  • Each digest is signed (SHA-256 with RSA) and chained to the previous digest.
  • aws cloudtrail validate-logs --trail-arn ... --start-time ... detects modified, deleted or missing files.
  • It proves tampering; it does not prevent it — add Object Lock and tight bucket policies.

Delivery behavior

  • Log files usually arrive in S3 within about 5 minutes of the call; not guaranteed.
  • Events go to EventBridge in near real time.
  • Event history keeps 90 days of management events per Region without a trail.
  • Global service events (IAM, STS, CloudFront) are logged in us-east-1 by a multi-Region trail.

CloudTrail Lake

  • Managed event data stores queried with SQL; can ingest CloudTrail, Config items and external events.
  • Closed to new customers from 31 May 2026; existing customers keep using it.
  • AWS recommends CloudWatch for new log analytics designs.
  • Exam questions may still describe Lake as "query CloudTrail with SQL, no ETL".
Task 1.2.2 · CloudWatch Logs

Getting OS and application logs into CloudWatch

The unified CloudWatch agent ships files and metrics; configuration usually lives in Parameter Store.

{
  "logs": {
    "logs_collected": {
      "files": {
        "collect_list": [
          { "file_path": "/var/log/secure",
            "log_group_name": "/ec2/linux/secure",
            "log_stream_name": "{instance_id}",
            "retention_in_days": 365 },
          { "file_path": "/var/log/nginx/access.log",
            "log_group_name": "/app/nginx/access",
            "log_stream_name": "{instance_id}" }
        ]
      }
    }
  }
}

Make it work

  • Instance role needs CloudWatchAgentServerPolicy (and SSM access to read the config).
  • Install and update the agent fleet-wide with Systems Manager (State Manager / Distributor).
  • Load config: amazon-cloudwatch-agent-ctl -a fetch-config -m ec2 -c ssm:AmazonCloudWatch-linux -s.
  • Private subnets need a route to the logs endpoint: NAT or an interface VPC endpoint.
  • Set log group retention and KMS encryption; the default is never expire.
Task 1.2.2 · CloudWatch Logs

Three ways to centralize logs across accounts

Copying logs, streaming logs and viewing logs are different features with different trade-offs.

OptionHow it worksUse whenWatch out
Subscription filter → destinationLog group streams matching events to a cross-account destination (Kinesis Data Streams, Firehose or Lambda)Real-time feed into a SIEM or a central S3 bucketMax 2 subscription filters per log group; destination policy must allow source accounts
Log centralization rules (Sep 2025)Organizations-aware rules copy log groups from many accounts and Regions into one accountA central copy for search and retentionOnly new events after the rule is created; adds @aws.account and @aws.region
Cross-account observability (OAM)Monitoring account links to source accounts with a sink and linksOne console to search logs, metrics and tracesData is viewed, not copied; within one Region
Export to S3CreateExportTask batch copyOccasional archiveNot real time; one active export task per account
Task 1.2.6 · Network logs

VPC Flow Logs

Metadata about IP traffic on ENIs, subnets or VPCs — not packet contents.

# version account-id interface-id srcaddr dstaddr srcport dstport protocol packets bytes start end action log-status
2 111122223333 eni-0a1b2c 203.0.113.12 10.0.1.25 51544 22 6 10 840 1728000000 1728000060 REJECT OK
2 111122223333 eni-0a1b2c 10.0.1.25 198.51.100.7 44321 443 6 220 182400 1728000000 1728000060 ACCEPT OK

Custom format fields worth adding

  • vpc-id, subnet-id, instance-id — context without joins.
  • pkt-srcaddr / pkt-dstaddr — real IPs behind NAT gateways and load balancers.
  • tcp-flags, flow-direction, traffic-path — direction and egress path.

Behavior to remember

  • Captured per ENI; can be created at VPC, subnet or ENI level.
  • Aggregation interval 10 minutes (default) or 1 minute.
  • Not captured: traffic to the Amazon DNS server, instance metadata (169.254.169.254), Time Sync, DHCP, the reserved VPC router IP.
  • Because security groups are stateful, an allowed request and its response both show ACCEPT; a REJECT comes from a SG or NACL.
  • To S3: bucket policy for delivery.logs.amazonaws.com. To CloudWatch Logs: an IAM role.
Task 1.2.6 · Network logs

Transit Gateway flow logs and DNS logs

Choose network log sources from the design: hub-and-spoke traffic and DNS are blind spots for ENI flow logs alone.

Transit Gateway flow logs

  • Record traffic crossing a transit gateway, per attachment.
  • Show inter-VPC and hybrid (VPN/Direct Connect) flows centrally.
  • Useful when spokes are owned by other teams and their VPC flow logs are off.
  • Destinations: S3, CloudWatch Logs or Firehose.

Route 53 Resolver query logs

  • Log DNS queries from VPCs: name, type, response code, answers, source instance.
  • Detect C2 beacons, DNS tunnelling, crypto-mining pools.
  • Share one query logging configuration to many accounts with AWS RAM.
  • Destinations: CloudWatch Logs, S3, Firehose.

Route 53 Resolver DNS Firewall

  • Blocks or alerts on domains from AWS managed or custom lists.
  • Matches appear in Resolver query logs with the firewall action.
  • Pair with GuardDuty DNS findings, which use DNS logs independently.
  • Central rollout with Firewall Manager.

Threat → source: data exfiltration over HTTPS → flow logs + pkt-dstaddr; DNS tunnelling → Resolver query logs; lateral movement between VPCs → Transit Gateway flow logs.

Task 1.2.2 · Service logs

Edge and application request logs

Each service has its own logging switch, destination and permission model.

ServiceLogDestinationGotcha
ALBAccess logs, connection logs (mTLS)S3Bucket must use SSE-S3, not SSE-KMS; bucket policy grants ELB log delivery
NLBAccess logs for TLS listeners onlyS3Plain TCP/UDP listeners produce no access logs
CloudFrontStandard logs (v2), real-time logsStandard: S3, CloudWatch Logs, Firehose · real-time: Kinesis Data StreamsLegacy S3 logging needs ACLs enabled on the bucket
API GatewayExecution logs (REST), access logsCloudWatch Logs (access logs can also go to Firehose)REST needs an account-level CloudWatch role per Region; HTTP APIs have access logs only
AWS WAFFull request logs with matched rulesCloudWatch Logs, S3, FirehoseDestination name must start with aws-waf-logs-; redact fields if needed
S3Server access logsS3 (another bucket)Best effort, delayed; use CloudTrail data events when completeness matters
LambdaFunction logsCloudWatch LogsExecution role needs logs:CreateLogStream and logs:PutLogEvents
Domain 1 · Logging sources

Exam traps: logging sources

These distinctions decide many Detection questions.

Completeness

  • S3 server access logs are best effort; CloudTrail data events are the reliable record of object access.
  • Event history is 90 days of management events only — no data events.
  • A single-Region trail misses activity in other Regions.

Content

  • Flow logs never contain payloads, URLs or DNS names.
  • Flow logs skip DNS to the Amazon resolver — use Resolver query logs.
  • GuardDuty reads flow logs and DNS logs from its own feed; you do not need to enable them for GuardDuty.

Destinations

  • ALB access logs cannot use SSE-KMS buckets.
  • WAF log destinations need the aws-waf-logs- prefix.
  • Org trail bucket path includes the organization ID.
Domain 1 · Logging sources

Exam-style scenarios: logging sources

Read the requirement words, then map them to the feature.

ScenarioAnswerWhy
Prove nobody edited CloudTrail logs after deliveryLog file integrity validation + validate-logsSigned, chained digest files detect changes
Find who deleted objects from a bucket last nightCloudTrail data events for S3 (write)Management events do not include DeleteObject
Detect an EC2 instance resolving known mining-pool domainsRoute 53 Resolver query logs / DNS Firewall, GuardDutyFlow logs do not see DNS names
See requests denied by a VPC endpoint policyCloudTrail network activity eventsRecords calls through the endpoint, including denials
Every new account must be logged with no member opt-outOrganization trailApplies to new accounts; members cannot modify it
Find the real client IP behind a NAT gateway in flow logsCustom format with pkt-srcaddr / pkt-dstaddrDefault srcaddr shows the NAT ENI
Chapter 4 · Part 4.2

Log architecture and analysis

Store logs where attackers cannot reach them, normalize them, and query them fast.

Task 1.2.3 · Architecture

A multi-account logging architecture

Workload accounts produce logs; a Log Archive account keeps them; a security tooling account analyzes them.

Workload accounts

  • Org trail, flow logs, DNS logs, ALB/WAF logs, CloudWatch agent.
  • No ability to delete central copies.
→

Log Archive account

  • S3 buckets with SSE-KMS, versioning, Object Lock.
  • Bucket policies allow only log delivery principals to write.
  • Lifecycle to Glacier for long retention.
→

Security tooling (Audit) account

  • Delegated admin for GuardDuty, Security Hub, Detective, Security Lake.
  • Read-only query access to the archive.
→

Analysis and SIEM

  • Athena, OpenSearch, CloudWatch Logs Insights.
  • Third-party SIEM via Security Lake subscribers or Firehose.

Control Tower creates the Log Archive and Audit accounts for you. Deny s3:DeleteObject, s3:PutBucketPolicy and s3:PutLifecycleConfiguration on log buckets with an SCP or RCP except for a break-glass role.

Task 1.2.3 · Security Lake

Amazon Security Lake

A security data lake in your own account that normalizes AWS and third-party logs to OCSF.

What it does

  • Collects logs into S3 in your account as Apache Parquet in OCSF schema.
  • Built on S3, AWS Glue Data Catalog and Lake Formation permissions.
  • Organization-wide through a delegated administrator.
  • Rollup Regions consolidate data from contributing Regions.

Native AWS sources

  • CloudTrail management events and data events (S3, Lambda).
  • VPC Flow Logs, Route 53 Resolver query logs.
  • Security Hub findings, EKS audit logs, AWS WAF logs.
  • Custom sources: any partner or app data written in OCSF.

Subscribers

  • Data access: subscriber gets S3 objects plus SQS/HTTPS notifications of new data.
  • Query access: subscriber queries tables through Lake Formation (Athena, etc.).
  • Typical subscribers: Splunk, OpenSearch, a SOC team account.
  • Retention and storage class are set per Region with lifecycle rules.

Why OCSF matters: one schema for all sources means one detection query works across CloudTrail, flow logs and a partner firewall. The new Security Hub also uses OCSF.

Task 1.2.4 · Athena

Querying CloudTrail in S3 with Athena

Serverless SQL over the archive; partition projection avoids loading partitions by hand.

-- Table created from the CloudTrail console ("Create Athena table")
-- or with partition projection on account, region and date.
SELECT eventtime, useridentity.arn, eventname,
       sourceipaddress, errorcode
FROM   cloudtrail_logs
WHERE  eventsource = 'iam.amazonaws.com'
  AND  eventname IN ('CreateAccessKey', 'CreateUser',
                     'AttachUserPolicy', 'PutUserPolicy')
  AND  timestamp >= '2026/10/01'
ORDER  BY eventtime DESC
LIMIT  50;

Make Athena fast and cheap

  • Partition by account, Region and date; filter on the partition column.
  • Athena bills per data scanned: Parquet (Security Lake) scans far less than JSON.
  • Query results go to an S3 location; encrypt it.
  • Readers need kms:Decrypt on the trail key and S3 read on the bucket.
  • Save common hunts as named queries; schedule with EventBridge + Lambda.
Task 1.2.4 · Logs Insights

CloudWatch Logs Insights for live investigation

Purpose-built query language over log groups, including across accounts with cross-account observability.

fields @timestamp, eventName, userIdentity.arn, sourceIPAddress
| filter errorCode like /AccessDenied|UnauthorizedOperation/
| stats count(*) as denied by userIdentity.arn, eventName
| sort denied desc
| limit 20
fields @timestamp, srcAddr, dstAddr, dstPort, action
| filter action = "REJECT" and dstPort in [22, 3389]
| stats count(*) as attempts by srcAddr
| sort attempts desc
| limit 20

Left: CloudTrail log group — who is hitting AccessDenied. Right: VPC flow logs — SSH/RDP scanners. Queries are billed per GB scanned, so narrow the time range; save queries and add results to dashboards.

Task 1.2.5 · Normalize and correlate

Choosing an analysis tool

Match the tool to latency, volume and who needs the answer.

ToolBest forNotes
CloudWatch Logs InsightsInteractive search of recent logs in log groupsNo setup; pay per GB scanned
Amazon AthenaSQL over S3 archives (CloudTrail, flow logs, Security Lake)Long retention at low cost; pay per data scanned
Amazon OpenSearch ServiceFull-text search, correlation dashboards, SIEM-style alertingIngest via Firehose or OpenSearch Ingestion; Security Analytics plugin
Amazon Managed GrafanaDashboards across CloudWatch, Athena, OpenSearch, PrometheusUsers via IAM Identity Center; no data store of its own
AWS LambdaParse, enrich, normalize or route eventsTriggered by subscription filters, S3 events, Firehose transforms
Security Lake + subscribersNormalized OCSF data for many toolsThird-party SIEMs read it directly
Domain 1 · Architecture

Exam traps and scenarios: log architecture

The best answer usually centralizes, protects, and minimizes operational overhead.

Traps

  • Storing the org trail in the management account: violates separation; use Log Archive.
  • Building custom ETL to normalize logs when Security Lake (OCSF) is asked for.
  • Using Logs Insights for multi-year history: logs must still be in CloudWatch; Athena on S3 is cheaper.
  • Forgetting KMS permissions for readers of encrypted logs.

Scenarios

RequirementAnswer
Normalize AWS and partner logs, least effortSecurity Lake (OCSF)
Ad hoc SQL over 2 years of CloudTrail in S3Athena with partition projection
Stream all app logs to a SIEM account in real timeSubscription filter → cross-account Firehose
Logs must be immutable for 7 yearsS3 Object Lock (compliance mode) in Log Archive
Correlate findings on dashboards for the SOCOpenSearch or Managed Grafana
Chapter 4 · Part 4.3

Threat detection services

GuardDuty, Inspector, Macie and Detective: what each one finds and how it finds it.

Task 1.1.4 · GuardDuty

How GuardDuty works

A managed threat detection service: threat intelligence, anomaly detection and ML over AWS-native data.

Foundational sources

  • CloudTrail management events, VPC Flow Logs (EC2), DNS logs.
  • Read from independent duplicate streams: nothing to enable, no impact on your logs.
  • Your own flow logs or Resolver logs may be off — GuardDuty still sees them.

Finding format

  • ThreatPurpose:ResourceType/ThreatFamily.Mechanism!Artifact
  • UnauthorizedAccess:IAMUser/InstanceCredentialExfiltration.OutsideAWS
  • CryptoCurrency:EC2/BitcoinTool.B!DNS
  • Recon:EC2/PortProbeUnprotectedPort

Severity

  • Low 1.0–3.9, Medium 4.0–6.9, High 7.0–8.9.
  • Critical 9.0–10.0 is used by attack sequence findings.
  • Filter EventBridge rules on the numeric severity field.
  • Generate sample findings to test the pipeline.

GuardDuty is Regional. Enable it in every Region, including ones you do not use — attackers like unused Regions.

Task 1.1.4 · GuardDuty

GuardDuty protection plans

Optional plans extend detection to more data. New accounts get all except Runtime Monitoring in the 30-day trial.

PlanData analyzedDetects
S3 ProtectionCloudTrail S3 data eventsExfiltration, destruction, suspicious access patterns
EKS ProtectionEKS audit logsAnonymous access, privileged pods, suspicious API calls
Runtime MonitoringOS-level events via a security agent on EKS, EC2, ECS (incl. Fargate)Reverse shells, crypto miners, privilege escalation, file tampering
Malware Protection for EC2 / S3 / AWS BackupEBS volume scans · new S3 objects · EBS snapshots, AMIs, recovery pointsMalware; EC2 scans triggered by findings or on demand
RDS ProtectionRDS / Aurora login activityBrute force and anomalous logins
Lambda ProtectionLambda network activity logsCrypto mining, contact with malicious hosts
AI ProtectionCloudTrail data events for Bedrock, Bedrock AgentCore, SageMaker AIAnomalous model invocations, cost harvesting
Task 1.1.4 · GuardDuty

Extended Threat Detection

Correlates many weak signals across sources, resources and time into one critical attack sequence finding.

Attack sequence findings

  • AttackSequence:IAM/CompromisedCredentials
  • AttackSequence:S3/CompromisedData
  • AttackSequence:EKS/CompromisedCluster
  • AttackSequence:EC2/CompromisedInstanceGroup (Dec 2025)
  • AttackSequence:ECS/CompromisedCluster (Dec 2025)

How to get full coverage

  • On automatically when GuardDuty is enabled, at no extra cost.
  • S3 Protection improves S3 sequences.
  • EKS Protection (and Runtime Monitoring) for EKS sequences.
  • Runtime Monitoring for EC2 and ECS sequences.

Why it helps the SOC

  • One finding shows the timeline, signals, resources and MITRE ATT&CK tactics.
  • Reduces alert fatigue from many low-severity findings.
  • Use it as the trigger for high-priority IR runbooks.
Task 1.1.3 · GuardDuty

Operating GuardDuty in an organization

Delegate administration, auto-enable everywhere, tune noise, and export findings for retention.

Multi-account

  • Management account designates a delegated administrator (security tooling account).
  • Auto-enable GuardDuty and chosen plans for all new members.
  • Repeat per Region: delegation and enablement are Regional.
  • Members cannot disable GuardDuty or change plans themselves.

Tuning

  • Trusted IP lists: no findings for these sources.
  • Threat lists: your own known-bad IPs.
  • Suppression rules auto-archive expected findings (e.g. a vulnerability scanner).
  • Suppressed findings are still generated and kept; they just skip notifications.

Export and route

  • Findings retained 90 days in GuardDuty.
  • Export to S3 (KMS key required); updates every 15 min, 1 h or 6 h (default).
  • New findings go to EventBridge immediately.
  • Findings also flow to Security Hub and Detective.
Task 3.2.3 · Inspector

Amazon Inspector: vulnerability management

Continuous scanning for software vulnerabilities and unintended network exposure.

Scan typeWhat it scansHow
EC2 scanningOS and application packages on instancesSSM agent-based, or agentless via EBS snapshots (hybrid mode)
ECR scanningContainer imagesEnhanced scanning on push and continuously when new CVEs appear
Lambda standard scanningFunction and layer dependenciesAutomatic when functions are created or updated
Lambda code scanningCustom function codeInjection flaws, hard-coded secrets, weak crypto
Code securitySource repositories and IaCSAST, SCA and IaC scanning integrated with GitHub and GitLab Self Managed
Network reachabilityPaths from the internet to EC2 portsAnalyzes VPC config without sending traffic
CIS scansEC2 OS configurationCIS benchmark assessments on demand or scheduled

Inspector risk score adjusts CVSS with network reachability and exploitability. Export SBOMs to S3 for supply-chain evidence.

Task 1.1.4 · Macie

Amazon Macie: sensitive data in S3

Discovers and classifies sensitive data, and flags risky bucket configurations.

Discovery modes

  • Automated sensitive data discovery: daily sampling across the S3 estate, sensitivity score per bucket.
  • Sensitive data discovery jobs: targeted one-time or scheduled full scans.
  • Managed data identifiers (PII, financial, credentials) plus custom regex identifiers.
  • Allow lists suppress known non-sensitive patterns.

Finding types

  • Policy findings: bucket made public, encryption disabled, shared externally, e.g. Policy:IAMUser/S3BlockPublicAccessDisabled.
  • Sensitive data findings, e.g. SensitiveData:S3Object/Personal.
  • Both go to EventBridge and Security Hub.

Operational details

  • Delegated administrator for the whole organization.
  • Discovery results must be stored in an S3 bucket encrypted with a KMS key.
  • Macie needs kms:Decrypt to read objects encrypted with customer managed keys.
  • Cost scales with data inspected: sample, do not scan everything.
Task 2.2.5 · Detective

Amazon Detective: investigation graph

Builds a behavior graph so you can answer "what else did this principal or IP do?" quickly.

Data

  • CloudTrail management events, VPC Flow Logs, GuardDuty findings.
  • Optional: EKS audit logs, Security Hub findings.
  • Up to one year of aggregated history.

Use it to

  • Pivot from a finding to the IAM role, IP, instance or cluster involved.
  • Compare activity with the entity’s normal baseline.
  • Review finding groups that cluster related findings.
  • Run investigations on IAM users and roles for indicators of compromise.

Know the boundaries

  • Detective investigates; it does not detect new threats or remediate.
  • Enable GuardDuty first; organization-wide through a delegated administrator.
  • Root cause questions on the exam often point to Detective.
Domain 1 · Services

Which service finds what?

Many exam distractors swap these services. Learn the one-line job of each.

NeedServiceNot this
Active threats: compromised credentials, crypto mining, C2GuardDutyInspector (vulnerabilities only)
CVEs in instances, images, LambdaInspectorGuardDuty
PII or credentials stored in S3MacieGuardDuty S3 Protection (behavior, not content)
Root cause and blast radius of a findingDetectiveSecurity Hub (aggregates, does not graph)
Resource configuration compliance over timeAWS Config (+ Security Hub CSPM controls)CloudTrail (who changed it, not current state)
Resources shared outside the org / unused accessIAM Access AnalyzerMacie
Prioritized exposures across all the aboveSecurity HubAny single detector
Domain 1 · Services

Exam traps and scenarios: detection services

Watch for the word that reveals the data source.

Traps

  • "Enable VPC Flow Logs so GuardDuty can analyze traffic" — not required.
  • GuardDuty Malware Protection for EC2 scans EBS snapshots; no agent is installed.
  • Macie only covers S3; RDS or EFS PII needs another approach.
  • Detective does not stop anything — pair with automation.

Scenarios

RequirementAnswer
Alert when an EC2 role’s credentials are used from outside AWSGuardDuty (InstanceCredentialExfiltration)
Block deploys of images with critical CVEsInspector ECR scanning + pipeline gate
Find buckets with credit card numbersMacie discovery job / automated discovery
Scan uploaded files for malware before processingGuardDuty Malware Protection for S3
Show everything an IP did across accounts last monthDetective
Chapter 4 · Part 4.4

Aggregation and alerting

Turn findings and metrics into prioritized, routed, actionable alerts.

Task 1.1.3 · Security Hub

Security Hub vs Security Hub CSPM

In 2025 AWS split the product: the original service became Security Hub CSPM, and a new Security Hub sits on top.

Security Hub (GA 2 Dec 2025)Security Hub CSPM
JobCorrelate threats, vulnerabilities, misconfigurations and sensitive data into prioritized exposuresRun security controls and standards; aggregate findings
InputsGuardDuty, Inspector, Macie, Security Hub CSPM, partnersAWS service and partner findings; AWS Config-based controls
FormatOCSFAWS Security Finding Format (ASFF)
HighlightsExposure findings, potential attack path graph, trends, Jira/ServiceNow ticketsStandards (FSBP, CIS, PCI DSS, NIST 800-53), security score, automation rules
Multi-accountDelegated administrator, cross-Region aggregationDelegated administrator, central configuration, cross-Region aggregation

Exposure example: "EC2 instance is reachable from the internet and has software vulnerabilities" — Inspector + network reachability + CSPM signals combined into one prioritized item.

Task 1.1.5 · Security Hub CSPM

Running Security Hub CSPM across an organization

Central configuration makes the delegated administrator the single place that decides standards and controls.

Setup

  • Delegated administrator in the security tooling account.
  • Central configuration policies: enable standards and controls per OU or account.
  • Cross-Region aggregation into a home Region.
  • Needs AWS Config recording in each account and Region for most controls.

Automation

  • Automation rules: update or suppress findings on ingest (e.g. raise severity for prod accounts).
  • Custom actions send selected findings to EventBridge for runbooks.
  • EventBridge event Security Hub Findings - Imported for every new or updated finding.
  • BatchImportFindings (custom sources) and BatchUpdateFindings (workflow status).

Standards to know

  • AWS Foundational Security Best Practices (FSBP).
  • CIS AWS Foundations Benchmark.
  • PCI DSS, NIST SP 800-53 Rev. 5, NIST SP 800-171.
  • AWS Resource Tagging Standard.
Task 1.1.4 · EventBridge

Routing findings and API calls with EventBridge

Event patterns match on any field; targets run notification and remediation.

{
  "source": ["aws.guardduty"],
  "detail-type": ["GuardDuty Finding"],
  "detail": {
    "severity": [{ "numeric": [">=", 7] }]
  }
}
{
  "source": ["aws.signin"],
  "detail-type": ["AWS Console Sign In via CloudTrail"],
  "detail": {
    "userIdentity": { "type": ["Root"] }
  }
}

Patterns of use

  • Targets: SNS, Lambda, Step Functions, SSM Automation, another account’s event bus.
  • Forward member-account events to a central bus in the security account.
  • CloudTrail events arrive as AWS API Call via CloudTrail.
  • Read-only management events need rule state ENABLED_WITH_ALL_CLOUDTRAIL_MANAGEMENT_EVENTS.
  • Rules are Regional: deploy them in every Region (StackSets).
Task 1.1.4 · CloudWatch

Metric filters, alarms and dashboards

Turn log patterns into metrics, alarm on them, and show them on shared dashboards.

# Root account usage (CIS-style filter on the CloudTrail log group)
{ $.userIdentity.type = "Root"
  && $.userIdentity.invokedBy NOT EXISTS
  && $.eventType != "AwsServiceEvent" }

# Unauthorized API calls
{ ($.errorCode = "*UnauthorizedOperation") ||
  ($.errorCode = "AccessDenied*") }

# Console sign-in without MFA
{ ($.eventName = "ConsoleLogin")
  && ($.additionalEventData.MFAUsed != "Yes") }

aws logs put-metric-filter --log-group-name org-trail \
  --filter-name RootUsage --filter-pattern file://root.txt \
  --metric-transformations \
    metricName=RootUsage,metricNamespace=Security,metricValue=1

Alarm design

  • Static threshold alarms for "should never happen" events (root use).
  • Anomaly detection alarms learn a band for metrics with seasonality, e.g. API error counts.
  • Composite alarms combine signals to cut noise.
  • Alarm action → SNS → email, chat or incident tooling.
  • Cross-account dashboards in the monitoring account give one SOC view.
Task 1.1.2 · Workload monitoring

Health checks and notifications

Security monitoring includes availability: a DDoS or a broken control often shows first as failing health.

Health checks

  • Route 53 health checks: endpoint, calculated, or CloudWatch alarm-based; metric HealthCheckStatus in us-east-1.
  • ELB target health: unhealthy targets removed from rotation.
  • CloudWatch Synthetics canaries: scripted checks of APIs, pages and broken links.
  • Shield Advanced uses Route 53 health checks for health-based detection.

Notification channels

  • Amazon SNS topics (encrypt with KMS; key policy must allow the publishing service).
  • AWS User Notifications: central, org-wide notification configurations for events.
  • Amazon Q Developer in chat applications (formerly AWS Chatbot) for Slack/Teams.
  • Ticketing from Security Hub automation rules.

Decide what to monitor (1.1.1)

  • Classify the workload: data sensitivity, exposure, compliance scope.
  • Map likely threats to sources and detectors.
  • Define who is paged, for what severity, within what time.
  • Test the path with sample findings.
Task 1.1.5 · Continuous assessment

AWS Config, conformance packs and State Manager

Detect drift from the desired configuration continuously, and fix it automatically.

AWS Config rules

  • Managed rules, or custom rules in Lambda or Guard (custom policy).
  • Triggers: configuration change or periodic; proactive mode evaluates before deploy.
  • Remediation: SSM Automation document, manual or automatic with retries.
  • Multi-account aggregator gives an org-wide compliance view.

Conformance packs

  • A YAML bundle of rules and remediation actions deployed as one unit.
  • Organization conformance packs from the management or delegated admin account.
  • AWS sample packs map to frameworks (CIS, PCI DSS, NIST).
  • Compliance score per pack.

Systems Manager State Manager

  • Associations keep instances in a defined state on a schedule.
  • Examples: keep the CloudWatch agent installed, enforce SSH config, run Inspector-related checks.
  • Compliance results visible in Systems Manager and Security Hub CSPM.
  • Trusted Advisor adds account-level security checks.
Domain 1 · Alerting

Exam traps and scenarios: aggregation and alerting

Most "least operational overhead" answers are a managed rule + EventBridge + a managed target.

Traps

  • EventBridge rules and Security Hub enablement are Regional — missing Regions means missing alerts.
  • An SNS topic encrypted with an AWS managed key cannot receive events from EventBridge or CloudWatch; use a customer managed key with a key policy for the service.
  • ASFF belongs to Security Hub CSPM; the new Security Hub uses OCSF.
  • Config must be recording for Security Hub CSPM controls to evaluate.

Scenarios

RequirementAnswer
Page on-call within minutes of any root sign-inEventBridge rule on aws.signin → SNS
One compliance view for 300 accountsConfig aggregator / Security Hub CSPM delegated admin
Auto-fix S3 buckets that lose encryptionConfig rule + SSM Automation auto-remediation
Rank which issues to fix first across servicesSecurity Hub exposure findings
Alert on unusual spikes in API errorsCloudWatch anomaly detection alarm or CloudTrail Insights
Chapter 4 · Part 4.5

Troubleshooting monitoring

When logs or findings go missing: permissions, keys, scope and Regions.

Task 1.3.2 · CloudTrail

Missing CloudTrail logs: the checklist

Most delivery failures are a bucket policy, a key policy, or a trail that is not logging what you think.

{
  "Sid": "AWSCloudTrailWrite",
  "Effect": "Allow",
  "Principal": { "Service": "cloudtrail.amazonaws.com" },
  "Action": "s3:PutObject",
  "Resource": "arn:aws:s3:::org-trail-logs/AWSLogs/*",
  "Condition": {
    "StringEquals": {
      "s3:x-amz-acl": "bucket-owner-full-control",
      "aws:SourceArn": "arn:aws:cloudtrail:us-east-1:<acct>:trail/org"
    }
  }
}

Check in order

  • aws cloudtrail get-trail-status: IsLogging, LatestDeliveryError.
  • Bucket policy allows s3:GetBucketAcl and s3:PutObject for cloudtrail.amazonaws.com (and the org path).
  • KMS key policy allows CloudTrail kms:GenerateDataKey* with the trail encryption context.
  • Trail scope: multi-Region? data events selected? management events excluded?
  • CloudWatch Logs delivery needs a role CloudTrail can assume with logs:PutLogEvents.
  • An SCP or a later bucket policy change may have broken delivery.
Task 1.3.2 · Encryption

KMS key policies for log delivery

When logs are encrypted with a customer managed key, the delivering service must be allowed in the key policy.

Log destinationPrincipal that needs the keyTypical permissions
CloudTrail → S3 (SSE-KMS)cloudtrail.amazonaws.comkms:GenerateDataKey*, kms:DescribeKey; readers need kms:Decrypt
CloudWatch Logs group with KMSlogs.<region>.amazonaws.comkms:Encrypt*, kms:Decrypt*, kms:GenerateDataKey* with log group ARN context
VPC Flow Logs → S3 (SSE-KMS)delivery.logs.amazonaws.comkms:GenerateDataKey*, kms:Encrypt, kms:Decrypt
SNS topic with KMS (EventBridge / CloudWatch publisher)events.amazonaws.com / cloudwatch.amazonaws.comkms:GenerateDataKey*, kms:Decrypt
GuardDuty findings exportguardduty.amazonaws.comkms:GenerateDataKey (scoped with aws:SourceArn to the detector)
ALB access logs— not supportedUse SSE-S3 on the bucket
Task 1.3.1 · Service logging

Missing agent, Lambda, API Gateway and edge logs

Analyze the functionality, permissions and configuration of the resource that should be logging.

SymptomLikely causeFix
CloudWatch agent running, no logsWrong file_path, unreadable file, missing IAM permissions, no route to logs endpointCheck agent log /opt/aws/amazon-cloudwatch-agent/logs/amazon-cloudwatch-agent.log
Lambda logs missingExecution role lacks CloudWatch Logs permissionsAttach AWSLambdaBasicExecutionRole or equivalent
API Gateway REST execution logs missingNo account-level CloudWatch role ARN set for the Region, or stage logging offSet the role in API Gateway settings; enable stage logging
ALB access logs failBucket uses SSE-KMS or policy lacks ELB log deliverySSE-S3 bucket + correct bucket policy
CloudFront logs missing in S3 (legacy)Bucket has ACLs disabled (BucketOwnerEnforced)Enable ACLs or use standard logging v2
Health check always failingSG/NACL blocks checker IPs, wrong path or portAllow Route 53 health checker ranges; verify target
Task 1.3.2 · Multi-account

Gaps in organization-wide coverage

A monitoring design is only as strong as the account and Region it forgot.

Common gaps

  • Service not enabled in a new Region or opt-in Region.
  • Auto-enable off, so new accounts are not members.
  • Account joined before auto-enable and was never added.
  • Config recorder stopped, so CSPM controls show no data.
  • A protection plan enabled in the admin account only.

How to find them

  • Delegated admin console: member account status per Region.
  • Security Hub CSPM control "GuardDuty should be enabled" across accounts.
  • Config aggregator for recorder status.
  • Organizations account list vs member list diff.

Prevent them

  • Deploy detectors and rules with StackSets or Control Tower to all Regions.
  • SCP denying guardduty:DeleteDetector, config:StopConfigurationRecorder, securityhub:DisableSecurityHub.
  • Region deny SCP for Regions you truly never use.
  • Alarm when a member disassociates.
Domain 1 · Troubleshooting

Exam-style scenarios: troubleshooting monitoring

Read the error first: most answers are a policy statement.

ScenarioAnswerWhy
New org trail delivers nothing after switching to SSE-KMSAdd CloudTrail to the KMS key policyService cannot generate data keys
Analysts get AccessDenied querying CloudTrail in AthenaGrant kms:Decrypt on the trail keyS3 read is not enough for SSE-KMS objects
No GuardDuty findings from a member account in eu-west-2Enable / auto-enable GuardDuty in that RegionGuardDuty is Regional
EventBridge rule never triggers SNS emailSNS topic key policy or topic policy missing events.amazonaws.comEncrypted topics need the publisher in the key policy
Agent logs stop after moving instances to a private subnetAdd a logs interface VPC endpoint or NATAgent cannot reach CloudWatch Logs
Self-check

Detection: can you explain these?

Answer without notes, then verify against the slides.

Logging

  • When do you need CloudTrail data events rather than management events?
  • What does log file integrity validation prove, and what does it not prevent?
  • Which traffic is never captured by VPC Flow Logs?
  • Three ways to centralize CloudWatch Logs — how do they differ?

Detection services

  • Why does GuardDuty not need your flow logs to be enabled?
  • Which plans feed Extended Threat Detection for EC2 and ECS?
  • Inspector vs GuardDuty vs Macie: one sentence each.
  • When is Detective the right answer?

Alerting and troubleshooting

  • How do Security Hub and Security Hub CSPM differ in role and format?
  • Write an EventBridge pattern for High+ GuardDuty findings.
  • Which principals must be in a KMS key policy for CloudTrail and SNS?
  • List four reasons an org member might send no findings.
Chapter 5

Incident response

Prepare before anything happens, automate the first minutes, follow tested playbooks, and recover with evidence intact. Domain 2 · 14%.

Chapter 5 · Part 5.1

Prepare and test

Plans, people, access and tooling that must exist before the first alert.

Task 2.1 · Lifecycle

The incident response lifecycle on AWS

The classic NIST SP 800-61 Rev. 2 phases map directly to AWS services (Rev. 3, 2025, reframes IR around CSF 2.0). Preparation is the phase you control most.

Preparation

  • IR plan, runbooks, IR roles in every account.
  • Forensic account, tooling, logging, backups.
  • Game days and FIS experiments.
→

Detection and analysis

  • GuardDuty, Security Hub, Macie, Inspector, Config.
  • Validate the finding; scope and impact.
  • Detective, Athena, Logs Insights.
→

Containment, eradication, recovery

  • Isolate, revoke, block; preserve evidence first.
  • Remove persistence; patch the cause.
  • Restore from backups or known-good images.
→

Post-incident

  • Blameless review and timeline.
  • Fix the control gap (SCP, Config rule, alert).
  • Update runbooks and retest.

Cloud changes the response: you can snapshot disks and isolate hosts by API in seconds, but credentials and APIs are now the main attack surface — most cloud incidents start with an identity.

Task 2.1.1 · IR plan

What a cloud IR plan must define

A plan is useless if responders discover at 3 a.m. that they have no access or no one to call.

ElementContentAWS-specific detail
RolesIncident commander, responders, communications, legalWho may assume the IR roles; break-glass owners
Severity matrixImpact × urgency → response time and pagingMap GuardDuty / Security Hub severities to your levels
ContactsInternal escalation, AWS Support, external partiesKeep account security contacts current; support plan level
AccessHow responders get in, read-only vs containmentPre-provisioned IR roles / Identity Center permission sets in every account
RunbooksStep-by-step per scenarioSSM Automation documents, Step Functions workflows
EvidenceWhat to collect, where to store, who may accessForensic account, Object Lock bucket, KMS keys
CommunicationsStatus updates, regulators, customersOut-of-band channel in case the main identity provider is compromised
Task 2.1.1 · Runbooks

Runbooks as code: Systems Manager Automation and OpsCenter

Codify repeatable steps so they run the same way every time, with approvals where judgment is needed.

description: Isolate a suspicious EC2 instance
schemaVersion: '0.3'
assumeRole: '{{ AutomationAssumeRole }}'
parameters:
  InstanceId: { type: String }
  IsolationSgId: { type: String }
  AutomationAssumeRole: { type: String }
mainSteps:
  - name: approve
    action: aws:approve
    inputs: { Approvers: ['arn:aws:iam::111122223333:role/IR-Lead'] }
  - name: isolate
    action: aws:executeAwsApi
    inputs:
      Service: ec2
      Api: ModifyInstanceAttribute
      InstanceId: '{{ InstanceId }}'
      Groups: ['{{ IsolationSgId }}']

Where each tool fits

  • SSM Automation: runbooks with AWS API calls, scripts, approvals; multi-account and multi-Region execution.
  • AWS-owned runbooks exist, e.g. AWS-DisableS3BucketPublicReadWrite.
  • OpsCenter: OpsItems aggregate issues (including Security Hub findings) with related resources and runbooks.
  • SageMaker AI notebooks: Jupyter playbooks that query Athena or Security Lake during investigation.
  • Version runbooks in Git and test them in game days.
Task 2.1.2 · Access

Responder access and the forensic account

Provision access and tooling before an incident, and keep evidence away from the compromised environment.

IR roles in every account

  • Deploy with StackSets (service-managed) so new accounts get them.
  • Read-only investigation role + a separate containment role.
  • Trust only the security tooling account; require MFA.
  • Exempt them from restrictive SCPs only as far as needed.
  • Alarm whenever they are assumed.

Forensic account

  • Isolated account in a Security OU; no workload trust.
  • Forensic VPC with no internet egress; analysis instances from a forensic AMI (Image Builder).
  • Evidence S3 bucket with versioning and Object Lock.
  • KMS key that can decrypt shared snapshots.

Snapshot sharing detail

  • Snapshots encrypted with the AWS managed key aws/ebs cannot be shared.
  • Copy and re-encrypt with a customer managed key, then share the key and snapshot.
  • Make customer managed keys the default EBS key ahead of time.
  • Same idea for RDS snapshots.
Task 2.1.2 · Blast radius

Reduce blast radius and prepare for DDoS

Preparation includes architecture choices that limit what one compromise can reach.

Minimize blast radius

  • Separate accounts per workload and environment.
  • SCPs and RCPs for guardrails; permission boundaries for delegated admins.
  • Short-lived credentials only; no long-term access keys.
  • Bind instance credentials to the instance with aws:EC2InstanceSourceVPC / aws:EC2InstanceSourcePrivateIPv4.
  • Immutable, versioned backups in another account.

Shield Advanced readiness

  • Protect CloudFront, Route 53, Global Accelerator, ALB, EIPs.
  • Shield Response Team (SRT) access requires a Business or Enterprise Support plan.
  • Grant the SRT a role (AWSShieldDRTAccessPolicy) and access to WAF log buckets in advance.
  • Proactive engagement needs Route 53 health checks on protected resources.
  • Automatic application-layer DDoS mitigation writes WAF rules for you.

Pre-deployed tooling

  • GuardDuty, Security Hub, Config, Detective enabled org-wide.
  • SSM Agent on all instances (memory capture, commands).
  • Isolation security group pre-created in every VPC.
  • Logging verified (see Detection chapter).
Task 2.1.3 · Testing

Test the plan: game days, FIS and Resilience Hub

An untested plan fails at the worst moment. Test people, process and automation.

Tabletop and game days

  • Tabletop: walk through a scenario on paper with all roles.
  • Game day: run a simulated attack in a sandbox account.
  • Generate GuardDuty sample findings or use the GuardDuty tester script.
  • Measure time to detect, time to contain.

AWS Fault Injection Service

  • Experiment templates: actions, targets, stop conditions.
  • Actions such as aws:ec2:stop-instances, aws:network:disrupt-connectivity, aws:ssm:send-command.
  • Stop conditions are CloudWatch alarms that halt the experiment.
  • Validates alarms, failover and runbooks under real faults.

AWS Resilience Hub

  • Define an application (CloudFormation, Terraform state, EKS, resource groups).
  • Resiliency policy sets RTO/RPO targets per disruption type.
  • Assessments report whether targets are met and recommend alarms, SOPs and FIS tests.
  • Re-assess after every architecture change.
Domain 2 · Prepare

Exam traps and scenarios: preparation

Preparation answers are usually "set it up before the incident, centrally, with least privilege".

Traps

  • Creating IR access during the incident — it should already exist.
  • Sharing an aws/ebs-encrypted snapshot with the forensic account — not possible.
  • Expecting SRT help without Business-level support and pre-authorized access.
  • Running FIS without stop conditions.

Scenarios

RequirementAnswer
Responders need consistent access to 200 accountsStackSets-deployed IR roles / Identity Center permission set
Validate that failover works within RTOResilience Hub assessment + FIS experiment
Repeatable, approved containment stepsSSM Automation runbook with aws:approve
DDoS help from AWS experts during an attackShield Advanced + SRT access + support plan
Investigate with reusable queriesSageMaker AI notebook over Athena / Security Lake
Chapter 5 · Part 5.2

Automated response

Event-driven containment and remediation in seconds, with humans in the loop where it matters.

Task 2.1.4 · Architecture

Event-driven remediation pattern

Detectors publish findings; EventBridge routes them; workflows contain and notify.

Detect

  • GuardDuty, Security Hub, Config, Macie, CloudTrail events.
→

Route

  • EventBridge rule in the security account.
  • Member events forwarded to a central bus.
→

Orchestrate

  • Step Functions workflow.
  • Branch on severity, tags, environment.
  • Wait for human approval when risky.
→

Act

  • Lambda or SSM Automation in the target account via an IR role.
  • Isolate, revoke, snapshot, block.
→

Record

  • Update finding workflow status.
  • Notify via SNS / chat; open a ticket.

Automate the reversible, high-confidence steps (snapshot, tag, revoke sessions). Keep destructive or business-impacting steps (terminate, delete) behind approval.

Task 2.1.4 · Tooling

Choosing an automation mechanism

Each service fits a different shape of response.

MechanismBest forExample
Security Hub CSPM automation rulesChange finding fields on ingest (no code)Raise severity for prod; suppress known scanner findings
AWS Config remediationFix a non-compliant resource configurationRe-enable bucket encryption with an SSM document
EventBridge → LambdaShort, single-purpose actionsDisable an access key; add an IP to a WAF IP set
EventBridge → SSM AutomationMulti-step AWS actions with approvals, no custom codeIsolate instance, snapshot volumes
EventBridge → Step FunctionsLong, branching workflows with retries and waitsFull forensic acquisition across accounts
GuardDuty / Shield built-insService-native responseShield automatic L7 mitigation; Malware Protection scan on finding
Task 2.1.4 · Forensics

Automated Forensics Orchestrator for Amazon EC2

An AWS Solution that turns a finding into isolation plus memory and disk acquisition, analyzed in a forensic account.

Trigger

  • GuardDuty, Config or partner finding lands in Security Hub.
  • EventBridge starts the Step Functions workflow with the instance ID.
→

Triage

  • Decide isolation and acquisition from the Security Hub action and instance tags.
  • State tracked in DynamoDB.
→

Acquire

  • Memory captured through SSM to the S3 evidence bucket.
  • EBS snapshots taken in parallel.
→

Isolate

  • After memory capture, the instance is isolated with security groups.
→

Investigate

  • Forensic instance launched from a forensic AMI in the forensic account.
  • Memory and disk loaded for analysis; report produced.

Order matters: memory first (volatile), then isolate, then disk. Isolating or stopping first can destroy the evidence you need.

Task 2.1.4 · Recovery automation

Amazon Application Recovery Controller (ARC)

Recovery is part of response: move traffic away from an impaired or compromised location quickly and safely.

Single Region

  • Zonal shift: manually move traffic for supported resources (e.g. ALB, NLB, EKS) away from one AZ, with an expiry of up to three days (extendable).
  • Zonal autoshift: AWS shifts traffic away from an impaired AZ on your behalf.
  • Zonal shift and autoshift are free; ALB zonal shift must be enabled per load balancer.

Multi-Region

  • Routing controls: highly available on/off switches that flip DNS-based traffic between Regions.
  • Readiness checks closed to new customers from 30 Apr 2026; Region switch plan evaluation is the replacement.
  • Region switch: orchestrated, observable full-stack failover plans.
  • Billed separately from zonal features.

Security use

  • Fail over away from a Region where a workload is compromised while you investigate.
  • Practice failovers in game days.
  • Combine with backups in an isolated account for ransomware recovery.
Domain 2 · Automate

Exam traps and scenarios: automated response

Look for "automatically", "least operational overhead" and "without custom code".

Traps

  • Lambda for a long multi-step workflow with waits — Step Functions is the fit.
  • Terminating a compromised instance automatically — destroys evidence.
  • One EventBridge rule in one Region for a multi-Region estate.
  • Auto-remediation roles with * permissions — scope them.

Scenarios

RequirementAnswer
Disable an IAM key within a minute of a GuardDuty findingEventBridge → Lambda UpdateAccessKey
Isolate + snapshot + notify, with manager approvalSSM Automation with aws:approve or Step Functions
Automatic memory and disk acquisition for EC2 findingsAutomated Forensics Orchestrator for EC2
Fix public buckets as soon as Config detects themConfig rule + automatic SSM remediation
Shift traffic away from an impaired AZ quicklyARC zonal shift / autoshift
Chapter 5 · Part 5.3

Response playbooks

Contain and eradicate the common cloud incidents without destroying evidence.

Task 2.2.4 · Compromised EC2

Playbook: compromised EC2 instance

Preserve volatile evidence, contain without terminating, then analyze copies elsewhere.

StepActionHow
1 RecordCapture instance metadata, tags, ENIs, roles, SGs; tag the instance as under investigationdescribe-instances; tag ir:status=quarantine
2 ProtectEnable termination protection; set shutdown behavior to stopmodify-instance-attribute
3 Remove from serviceDetach from Auto Scaling group (or set Standby), deregister from target groupsPrevents replacement and traffic
4 MemoryAcquire memory and volatile data before anything else changesSSM Run Command with a memory capture tool → S3
5 IsolateReplace security groups with an isolation group; consider a NACLSee connection tracking next slide
6 DiskSnapshot all EBS volumes; share to the forensic accountCustomer managed KMS key
7 CredentialsRevoke instance-role sessions; check CloudTrail for role use elsewhereAWSRevokeOlderSessions; GuardDuty exfiltration findings

Do not stop or terminate first: stopping loses memory and terminating can delete volumes. Do not log in interactively and "look around" — every command changes the evidence.

Task 2.2.4 · Isolation

Isolation and security group connection tracking

Changing a security group does not always cut an attacker’s existing session.

Tracked connections

  • Security groups are stateful: they track connections.
  • When you remove the rule that allowed a tracked flow, the existing connection is not interrupted immediately.
  • An attacker’s open reverse shell can keep working after you swap the SG.

Untracked flows

  • TCP/UDP flows are untracked when a rule allows them from 0.0.0.0/0 / ::/0 and the opposite direction allows all responses to 0.0.0.0/0 / ::/0 on all ports. ICMP and connections through NAT gateways, NLBs or interface endpoints are always tracked.
  • Untracked flows stop as soon as the allowing rule is removed.
  • This is why responders reason about which flows are tracked before swapping groups.

Network ACLs

  • NACLs are stateless; a deny rule drops traffic for existing connections immediately.
  • But a NACL applies to the whole subnet — every instance in it is affected.
  • Option: move the ENI’s workload context to a quarantine subnet, or accept the subnet-wide impact briefly.

Exam pattern: "The SG was changed but the attacker is still connected" → existing tracked connection; use a NACL deny to cut it.

Task 2.2.4 · Leaked credentials

Playbook: leaked IAM access key

Deactivating the key is not enough — temporary credentials minted from it can still be valid.

Contain

  • Deactivate the key (update-access-key --status Inactive), do not delete it yet — you need it to search logs.
  • Deny old sessions: temporary credentials from GetSessionToken / AssumeRole live on until they expire.
  • For roles: "Revoke active sessions" adds the inline policy AWSRevokeOlderSessions.
  • If AWS detects a public leak it attaches AWSCompromisedKeyQuarantineV3 and opens a Support case — follow the case.
{
 "Version": "2012-10-17",
 "Statement": [{
  "Effect": "Deny",
  "Action": "*",
  "Resource": "*",
  "Condition": {
   "DateLessThan": {
    "aws:TokenIssueTime":
      "2026-10-18T09:30:00Z"
   }
  }
 }]
}

Investigate and eradicate

  • Search CloudTrail across all Regions by userIdentity.accessKeyId.
  • Look for persistence: new users, keys, roles, trust policy edits, Lambda functions, EC2 in unused Regions.
  • Delete what the attacker created; rotate other secrets they could read.
  • Replace long-term keys with roles; add a Config rule for key age.
Task 2.2.4 · Data exposure

Playbook: public S3 bucket

Stop further exposure, then work out exactly what was read and by whom.

Contain

  • Turn on S3 Block Public Access for the bucket — and the account, if possible.
  • Remove public statements from the bucket policy; disable ACLs (Object Ownership: bucket owner enforced).
  • Check access points and cross-account grants with IAM Access Analyzer.
  • Org-wide prevention: SCP / declarative and RCP guardrails.

Assess impact

  • CloudTrail S3 data events (if enabled) or server access logs: GetObject by anonymous or external principals.
  • Macie job on the bucket to classify what was exposed.
  • Timeline: when did the policy change (PutBucketPolicy in CloudTrail) and by whom?

Eradicate and recover

  • Rotate any credentials or keys stored in the bucket.
  • Restore tampered objects from versions or AWS Backup.
  • Legal / privacy notification decisions from the Macie findings.
  • Add a Config rule + auto-remediation to stop recurrence.
Task 2.2.4 · Containers

Playbook: compromised EKS pod

Contain the pod and node without deleting the evidence that Kubernetes would otherwise replace.

Contain

  • Identify the pod, node and service account from the GuardDuty EKS or Runtime finding.
  • Isolate the pod with a deny-all NetworkPolicy matching a quarantine label.
  • Revoke the pod’s AWS credentials: IRSA / Pod Identity role sessions.
  • Remove or restrict RBAC bindings the service account holds.
  • Cordon the node; enable termination protection on the instance.
# label the pod, then apply a deny-all policy for that label
kubectl label pod web-7d9f -n shop ir/quarantine=true
kubectl apply -f - <<'EOF'
apiVersion: networking.k8s.io/v1
kind: NetworkPolicy
metadata: { name: quarantine, namespace: shop }
spec:
  podSelector: { matchLabels: { ir/quarantine: "true" } }
  policyTypes: [Ingress, Egress]
EOF
kubectl cordon ip-10-0-1-25.ec2.internal

Then collect and eradicate: capture pod logs, kubectl describe and node memory and disk (as for EC2); review EKS audit logs for the attacker’s API calls; rebuild from a patched image and replace the node. Isolation needs a NetworkPolicy engine, e.g. VPC CNI network policy.

Task 2.2.4 · Serverless

Playbook: compromised Lambda function

No host to image: the evidence is the code, configuration, role and logs.

Contain

  • Stop invocations: set reserved concurrency to 0 (put-function-concurrency --reserved-concurrent-executions 0).
  • Revoke execution role sessions (AWSRevokeOlderSessions) and reduce its permissions.
  • Remove or restrict the function URL and resource-based policy if abused.

Preserve and investigate

  • Download the current code and layers; record versions and aliases.
  • CloudTrail: UpdateFunctionCode, UpdateFunctionConfiguration, AddPermission — who changed what.
  • CloudWatch Logs and GuardDuty Lambda Protection findings for outbound connections.
  • Check environment variables for exposed secrets.

Eradicate and recover

  • Redeploy a known-good version from the pipeline.
  • Rotate secrets the function could access.
  • Enable code signing for Lambda so only signed code can deploy.
  • Scan with Inspector Lambda code scanning.
Domain 2 · Playbooks

Exam traps and scenarios: playbooks

The order of actions is a favourite exam question — and an ordering question type exists.

Traps

  • Deleting the leaked key first — you lose the easiest search key; deactivate instead.
  • Assuming deactivating a key ends attacker access — sessions remain.
  • Stopping the instance before memory capture.
  • Deleting the compromised pod — the Deployment recreates a clean one and the evidence is gone.

Scenarios

RequirementAnswer
Invalidate all sessions of a compromised role nowRevoke active sessions (aws:TokenIssueTime deny)
Attacker still connected after SG swapNACL deny on the subnet (tracked connection)
Halt a malicious Lambda without deleting itReserved concurrency = 0
Know what data left a public bucketS3 data events / access logs + Macie classification
Correct order for EC2 compromiseRecord → protect → remove from service → memory → isolate → snapshot
Chapter 5 · Part 5.4

Investigate and recover

Validate, scope, find the root cause, keep evidence defensible, and come back clean.

Task 2.2.3 · Validate findings

Validate scope and impact before escalating

A finding is a hypothesis. Answer these questions, each from a specific source.

QuestionWhere to look
Is it real or expected activity (scanner, pentest, new deployment)?Change records, tags, suppression rules, the resource owner
Which principal, and how did it get credentials?CloudTrail userIdentity, AssumeRole chain, Identity Center sign-in
Which accounts and Regions are involved?Org-wide Athena / Security Lake query on the principal or access key
What resources did it touch, and what data?CloudTrail data events, S3 access logs, Macie classification
Did it talk to the internet or move laterally?Flow logs, Resolver query logs, Transit Gateway flow logs
Is it still happening?Live GuardDuty findings, Detective timeline, recent API calls
What is the business impact?Data sensitivity, customer exposure, availability, cost
Task 2.2.2 · Correlate

Search and correlate logs across the organization

Pivot on stable identifiers: access key ID, role session name, source IP, instance ID.

-- Everything a leaked key did, all accounts and Regions
SELECT eventtime, recipientaccountid, awsregion,
       eventsource, eventname, sourceipaddress, errorcode
FROM   cloudtrail_logs
WHERE  useridentity.accesskeyid = 'AKIAEXAMPLE1234567'
   OR  useridentity.sessioncontext.sessionissuer.arn
         LIKE '%role/compromised-app%'
ORDER  BY eventtime;

Correlation techniques

  • Follow the session: AssumeRole events link a source identity to the role session it created.
  • sourceIdentity (if set) persists through role chains.
  • Join CloudTrail source IPs with flow logs and WAF logs.
  • Detective pivots between IPs, roles, instances and findings automatically.
  • Security Lake gives the same OCSF fields across sources, so one query spans them.
Task 2.2.1 · Evidence

Capture and store forensic artifacts

Collect in order of volatility and keep a defensible chain of custody.

Order of volatility

  • 1 Memory and running processes, network connections.
  • 2 Instance metadata, attached roles, temporary files.
  • 3 EBS volume snapshots (disk).
  • 4 Logs: CloudTrail, flow logs, app logs (already central).
  • 5 Configuration history (AWS Config timeline).

Store it safely

  • Evidence bucket in the forensic account: versioning + Object Lock in compliance mode with a retention period.
  • SSE-KMS with a key only investigators can use.
  • Deny delete and policy changes with a bucket policy; block public access.
  • Copy snapshots into the forensic account; keep originals untouched.

Chain of custody

  • Record SHA-256 hashes of every artifact at acquisition.
  • Log who collected what, when, from where, and every access since.
  • CloudTrail data events on the evidence bucket provide the access trail.
  • Analyze copies, never the originals.
Task 2.2.5 · Root cause

Root cause analysis

Containment stops the bleeding; root cause analysis stops the next incident.

Build the timeline

  • Earliest suspicious event → initial access vector.
  • Detective timeline and finding groups for the entities involved.
  • AWS Config history: when did the misconfiguration appear?
  • CloudTrail: who made that change, from which session?

Common cloud root causes

  • Long-term access key leaked in code or CI logs.
  • Over-permissive role or trust policy.
  • Public resource (bucket, snapshot, AMI, security group).
  • Unpatched, internet-reachable workload (Inspector finding ignored).
  • SSRF to IMDSv1 on an instance.

Ask "why" until it is a control

  • Why was the key in code? No secret scanning in the pipeline.
  • Why did it work from the internet? No data perimeter conditions.
  • Why did nobody notice? No alert on that finding type.
  • Each "why" becomes a preventive or detective control.
Task 2.2.4 · Recover

Recover cleanly

Restore to a known-good state and prove the attacker is gone before declaring recovery.

Restore data

  • AWS Backup: restore recovery points; vaults with Vault Lock resist deletion.
  • Logically air-gapped vault for ransomware recovery across accounts.
  • Restore testing in AWS Backup proves backups actually restore.
  • S3 versioning / Object Lock to roll objects back.
  • GuardDuty Malware Protection for AWS Backup can scan recovery points.

Rebuild compute

  • Redeploy from IaC and a known-good, patched AMI or image — not from the compromised host.
  • Rotate every credential and secret in scope.
  • Re-scan with Inspector; watch GuardDuty for recurrence.
  • Shift traffic back with ARC once healthy.

Post-incident activity

  • Blameless review within days, with the full timeline.
  • Track action items to closure: SCPs, Config rules, alerts, runbook edits.
  • Measure mean time to detect, contain and recover.
  • Feed the scenario back into the next game day.
Domain 2 · Investigate and recover

Exam-style scenarios: investigation and recovery

Forensic integrity and clean recovery are the recurring themes.

ScenarioAnswerWhy
Evidence must be provably unmodified for legal proceedingsObject Lock compliance mode + hashes + CloudTrail data events on the bucketImmutable storage and an access trail
Find which other resources a compromised role touchedAmazon DetectiveBehavior graph across CloudTrail, flow logs, findings
Determine when a security group was openedAWS Config resource timeline + CloudTrailConfig shows the change; CloudTrail shows who
Recover from ransomware that deleted backups in the accountCross-account backup copies / logically air-gapped vaultBackups outside the compromised account survive
Assess whether a finding affects other accountsOrg-wide Athena or Security Lake query on the identifierScope before deciding severity
Self-check

Incident response: can you explain these?

Answer without notes, then verify against the slides.

Prepare and automate

  • What must exist in every account before an incident?
  • Why can’t you share an aws/ebs-encrypted snapshot, and what do you do instead?
  • When do you choose Step Functions over Lambda for remediation?
  • What do FIS stop conditions protect against?

Playbooks

  • Put the EC2 compromise steps in order, and justify memory before isolation.
  • Why might an attacker stay connected after a security group change?
  • Why is deactivating a leaked key not enough?
  • How do you stop a malicious Lambda without deleting it?

Investigate and recover

  • Which questions validate the scope and impact of a finding?
  • How do you prove evidence was not altered?
  • What does Detective add that CloudTrail alone does not?
  • What makes a recovery "clean"?
Chapter 6

Infrastructure security

Domain 3 · 18% — protect the edge, the network, the compute, and the GenAI apps that run on them.

Chapter 6 · Part 6.1

Edge protection

Stop bad traffic before it reaches your VPC: CloudFront, origin lock-down, CORS, and IoT policies.

Task 3.1.1 · Edge strategy

Start from the threat, then pick the control

The exam describes an attack; your job is to name the cheapest control that stops it at the right layer.

ThreatLayerFirst-choice controlAdd when needed
Volumetric / SYN / UDP floodL3–L4Shield Standard (automatic, free) + CloudFront / Global AcceleratorShield Advanced for SRT, cost protection
HTTP request floodL7WAF rate-based rule, Anti-DDoS managed rule groupShield Advanced (SRT, cost protection, Anti-DDoS rule group included)
SQLi, XSS, LFI (OWASP Top 10)L7WAF Core rule set + SQL database rule groupCustom rules, labels
Scrapers, scalpers, bad botsL7WAF Bot Control, CAPTCHA / ChallengeJA3/JA4 fingerprint rules
Credential stuffing / fake sign-upsL7WAF ATP (login) / ACFP (registration)Cognito advanced security
Direct-to-origin bypassOriginCloudFront OAC, VPC origins, origin-facing prefix listSecret custom header
Content theft / paywall bypassAppCloudFront signed URLs or signed cookiesGeo restriction

Push controls as far out as possible: CloudFront and WAF at the edge absorb traffic in AWS’s global network, so the origin never sees it.

Task 3.1.2 · CloudFront origin

Lock the origin so only CloudFront can reach it

A WAF on CloudFront is useless if attackers can hit the origin directly.

S3 origin: OAC

  • Origin access control signs requests with SigV4 as the CloudFront service principal.
  • Supports SSE-KMS objects, all Regions, and PUT/DELETE.
  • OAI is the legacy option: no SSE-KMS, fewer Regions. Migrate to OAC.
  • Bucket policy: allow cloudfront.amazonaws.com with AWS:SourceArn = the distribution ARN.
  • Keep S3 Block Public Access on.

ALB / EC2 origin

  • VPC origins: CloudFront reaches an internal ALB, NLB or EC2 in a private subnet. No public IP at all.
  • Public ALB: allow only the managed prefix list com.amazonaws.global.cloudfront.origin-facing in its SG.
  • Add a secret custom header in CloudFront; an ALB listener rule rejects requests without it.
  • Rotate the header value (store it in Secrets Manager).

Viewer side

  • Viewer protocol policy: redirect HTTP → HTTPS.
  • Minimum TLS security policy such as TLSv1.2_2021.
  • Custom domain cert from ACM in us-east-1.
  • Origin protocol policy: HTTPS only to the origin.
Task 3.1.2 · OAC bucket policy

The OAC pattern in policy form

The condition on the distribution ARN prevents other CloudFront distributions (other accounts) from reading your bucket.

{
  "Version": "2012-10-17",
  "Statement": [{
    "Sid": "AllowCloudFrontServicePrincipalReadOnly",
    "Effect": "Allow",
    "Principal": { "Service": "cloudfront.amazonaws.com" },
    "Action": "s3:GetObject",
    "Resource": "arn:aws:s3:::media-bucket/*",
    "Condition": {
      "StringEquals": { "AWS:SourceArn":
        "arn:aws:cloudfront::111122223333:distribution/EDFDV" }
    }
  }]
}

Checklist

  • For SSE-KMS objects, the KMS key policy must also allow cloudfront.amazonaws.com to kms:Decrypt with the same AWS:SourceArn condition.
  • Missing the key policy statement → 403 from CloudFront, even though the bucket policy is right.
  • Without the AWS:SourceArn condition you have a confused deputy: any distribution could read the bucket.
  • OAC does not apply to S3 website endpoints; those are custom origins.
Task 3.1.2 · CloudFront controls

Signed URLs, signed cookies, geo, field-level encryption, headers

CloudFront has several access controls; the exam tests which one fits the scenario.

FeatureWhat it doesPick it when
Signed URLTime-limited access to one object; policy can restrict IP range and start/end timeOne file per link, or clients that do not support cookies
Signed cookiesSame policy, carried in cookies across many objectsMany files (HLS segments, a members area) without changing URLs
Trusted key groupsPublic keys you upload to CloudFront; managed with IAMAlways; root-account CloudFront key pairs are legacy
Geo restrictionAllow list or block list of countries for the whole distributionLicensing/sanctions; use WAF geo match for per-path rules
Field-level encryptionEncrypts specific POST form fields at the edge with your public keyOnly one back-end service may read card numbers or PII
Response headers policyAdds HSTS, CSP, X-Frame-Options, X-Content-Type-Options, CORS headersBrowser-side hardening without changing the origin
Task 3.1.2 · CORS and IoT

Browser CORS on S3, and least-privilege IoT device policies

CORS is a browser relaxation, not an authorization control. IoT policies are authorization for devices.

S3 CORS

  • The browser blocks cross-origin reads unless S3 returns Access-Control-Allow-Origin.
  • Configure AllowedOrigins, AllowedMethods, AllowedHeaders, MaxAgeSeconds.
  • CORS never grants access: the bucket policy / presigned URL still decides.
  • Never use * origins with credentials; list exact origins.
  • Symptom of missing CORS: works in curl, fails in the browser.

AWS IoT Core

  • Devices authenticate with X.509 client certificates (mutual TLS).
  • An IoT policy is attached to the certificate and authorizes iot:Connect, Publish, Subscribe, Receive.
  • Use policy variables to scope each device to its own topics.
  • Device Defender audits overly permissive policies and shared certificates.

IoT policy variable

  • "Resource": "arn:aws:iot:…:topic/devices/${iot:Connection.Thing.ThingName}/*"
  • iot:Connect restricted to client/${iot:Connection.Thing.ThingName}.
  • One compromised device can then only publish to its own topic.
Chapter 6 · Part 6.2

AWS WAF and AWS Shield

Layer 7 filtering, bot and fraud controls, and DDoS protection with response support.

Task 3.1.2 · WAF model

How a web ACL evaluates a request

Rules run in priority order; the first terminating action wins; otherwise the default action applies.

Request arrives

  • At CloudFront, ALB, API Gateway REST, AppSync, Cognito, App Runner, Verified Access, Amplify.
  • CloudFront web ACLs are global (created in us-east-1).
→

Rules by priority

  • Lowest number first.
  • Rule = statement + action.
  • Rule groups are evaluated in place.
→

Action

  • Terminating: Allow, Block, CAPTCHA, Challenge.
  • Count: record + add labels, keep going.
  • Block can return a custom response.
→

Default action

  • Allow or Block when nothing matched.
  • Allow-list designs use default Block.

Labels let one rule tag a request (e.g. awswaf:managed:aws:bot-control:bot:category:…) and a later rule act on that label. This is how you tune managed rules without disabling them: set a rule to Count, then block on its label with a scope-down.

Task 3.1.2 · Capacity and limits

WCUs, body inspection, and logging

Numbers that show up in design questions.

Web ACL capacity units

  • Max 5,000 WCUs per web ACL and per rule group.
  • Base price includes up to 1,500 WCUs; above that, tiered extra fees.
  • Regex and JSON-body rules cost more WCUs than simple matches.
  • A rule group’s capacity is fixed at creation: size it for growth.

Body inspection

  • ALB and AppSync: fixed 8 KB.
  • CloudFront, API Gateway, Cognito, App Runner, Verified Access: 16 KB default, raise to 32/48/64 KB (extra cost).
  • Oversize handling: Continue, Match, or No match — choose Match to block what you cannot inspect.

Logging

  • Destinations: CloudWatch Logs, S3, or Data Firehose.
  • Log group / bucket / stream name must start with aws-waf-logs-.
  • Redact fields (e.g. Authorization header) and filter which requests to log.
  • Security Lake can collect WAF logs natively in OCSF.
Task 3.1.2 · Managed rules

AWS Managed Rules: what each group covers

Start with baseline groups, add use-case groups, and pay for intelligent threat mitigation only where needed.

Rule groupCoversNotes
Core rule set (CRS)Broad OWASP Top 10 coverage: XSS, LFI/RFI, size limits, bad user agentsBaseline for almost every web ACL
Known bad inputsExploit patterns such as Log4j (${jndi:), Java deserializationBaseline
SQL database / Linux / POSIX / Windows / PHP / WordPressPlatform-specific injection and exploit patternsAdd only what matches your stack
Amazon IP reputation / Anonymous IP listKnown malicious IPs, botnets; VPNs, Tor, hosting providersAnonymous IP can block legitimate users behind VPNs
Bot Control (Common / Targeted)Self-identifying bots; targeted adds browser interrogation, fingerprinting, MLExtra fee; scope down to sensitive paths
ATP / ACFPAccount takeover on login; account creation fraud on sign-upExtra fee; inspects credentials, compares against stolen-credential DB
Anti-DDoS (AWSManagedRulesAntiDDoSRuleSet)Baselines traffic, labels suspected DDoS requests, Challenge or BlockExtra fee; 50 WCU; default for Shield Advanced L7 flood protection since 26 Mar 2026
Task 3.1.3 · Custom rules

Geo, IP sets, rate limiting, and client fingerprints

Requirements-driven rules: "only Vietnam and Japan", "max 100 logins per IP per 5 minutes", "block this TLS client".

Geo match and IP sets

  • Geo match uses country (and Region/subdivision labels) from the source IP.
  • Behind a proxy or CDN, use forwarded IP config (X-Forwarded-For).
  • IP sets: up to 10,000 CIDRs; update via API for threat-intel feeds.
  • Regex pattern sets for URIs and headers.

Rate-based rules

  • Evaluation window: 60, 120, 300 (default) or 600 seconds.
  • Minimum limit: 10 requests per window.
  • Aggregate by IP, forwarded IP, or custom keys: header, cookie, query arg, URI path, label namespace, JA3/JA4.
  • Scope-down statement: e.g. only POST /login.
  • Action: anything except Allow. Limits are approximate, not exact.

Client fingerprinting

  • JA3 and JA4 are hashes of the TLS Client Hello.
  • Match exactly (string match) on CloudFront and ALB.
  • Stops botnets that rotate IPs but reuse the same TLS stack.
  • Find candidate fingerprints in WAF logs first; JA4 is more stable than JA3.
Task 3.1.3 · Rate-based rule

A login rate limit in JSON

Count first, read the logs, then switch to Block.

{
  "Name": "login-rate-limit",
  "Priority": 10,
  "Action": { "Block": {} },
  "Statement": {
    "RateBasedStatement": {
      "Limit": 100,
      "EvaluationWindowSec": 300,
      "AggregateKeyType": "IP",
      "ScopeDownStatement": {
        "ByteMatchStatement": {
          "FieldToMatch": { "UriPath": {} },
          "PositionalConstraint": "STARTS_WITH",
          "SearchString": "/login",
          "TextTransformations": [{ "Priority": 0, "Type": "LOWERCASE" }]
        }
      }
    }
  },
  "VisibilityConfig": { "SampledRequestsEnabled": true,
    "CloudWatchMetricsEnabled": true, "MetricName": "loginRate" }
}

Design notes

  • CAPTCHA or Challenge instead of Block keeps humans moving during an attack.
  • Challenge = silent browser proof-of-work; CAPTCHA = a visible puzzle.
  • Both issue a token with an immunity time; SPAs use the WAF JavaScript SDK.
  • Behind CloudFront + ALB, put the web ACL on CloudFront: the ALB only sees CloudFront IPs.
  • Third-party rule groups (AWS Marketplace) plug in like any managed group.
Task 2.1.2 / 3.1.2 · DDoS

Shield Standard vs Shield Advanced

Standard is on for everyone. Advanced is a paid service with people and money behind it.

Shield StandardShield Advanced
CostFree, automaticUS$3,000/month per payer account (covers the org), 1-year commitment, plus data transfer out
ProtectsL3/L4 for all AWS customersEC2 EIPs, ELB, CloudFront, Global Accelerator, Route 53 hosted zones
DetectionGeneric signaturesPer-resource baselines; health-based detection using Route 53 health checks
L7—WAF included at no extra fee for protected resources; Anti-DDoS managed rule group included (supersedes legacy automatic L7 mitigation)
People—Shield Response Team (SRT) 24/7 (requires Business or Enterprise Support); proactive engagement
Money—Cost protection: credits for scaling charges caused by a DDoS
VisibilityBasicAttack diagnostics, CloudWatch metrics, Firewall Manager to apply org-wide

Prepare before the attack (Task 2.1.2): associate a web ACL, configure health checks, grant SRT access through an IAM role (AWSShieldDRTAccessPolicy) and the WAF log bucket, and set up proactive engagement contacts.

Task 3.1.4 · Integrations

Edge telemetry into your security tooling

C03 adds OCSF and third-party integration to the edge domain.

Into Security Lake

  • Native sources include WAF logs, Route 53 Resolver logs, VPC Flow Logs, CloudTrail, Security Hub findings.
  • Data is normalized to OCSF and stored as Parquet in S3 in a delegated admin account.
  • Subscribers (Splunk, a SIEM, Athena) get query or data access.
  • Custom sources must write OCSF themselves.

Third-party WAF rules

  • Marketplace managed rule groups from security vendors.
  • Subscribed per account; billed through Marketplace.
  • Deploy across the org with Firewall Manager policies.

Automate response

  • Shield / WAF metrics → CloudWatch alarm → SNS / Lambda.
  • Threat-intel feed → Lambda → update an IP set.
  • Firewall Manager auto-remediates accounts that drop the required web ACL.
Exam traps

Edge, WAF and Shield traps

Wrong answers that look right.

Origin bypass

  • A WAF on CloudFront does not protect an ALB that is still reachable from the internet.
  • OAI cannot read SSE-KMS objects; OAC can.

Wrong Region / scope

  • A CloudFront web ACL must be created with scope CLOUDFRONT in us-east-1.
  • ACM certificates for CloudFront must also be in us-east-1.

Wrong IP

  • Rate limiting by IP on an ALB behind CloudFront counts CloudFront edge IPs.
  • Use forwarded IP or move the web ACL to CloudFront.

CORS is not auth

  • Opening CORS does not make objects public, and closing it does not protect them from curl.

Shield Advanced scope

  • It is not "turn on to block SQLi". It is DDoS response, cost protection and SRT.
  • SRT requires Business or Enterprise Support.

Allow action

  • Rate-based rules cannot use Allow.
  • A managed rule in Count mode does not block — check overrides after testing.
Exam-style scenarios

Edge and WAF scenarios

Scenario → answer → why.

ScenarioAnswerWhy
Login page hit by credential stuffing from thousands of rotating IPsWAF ATP managed group on the login path; optionally JA4 rulesIP rate limits fail when IPs rotate; ATP checks stolen-credential patterns
Private S3 media must be served via CloudFront only; objects use SSE-KMSOAC + bucket policy with AWS:SourceArn + KMS key policy grantOAI cannot use KMS; both policies are required
Paid videos with many segment files per streamSigned cookies with a trusted key groupOne authorization covers many objects
Company wants DDoS cost credits and a 24/7 response teamShield Advanced + Business/Enterprise SupportOnly Advanced has SRT and cost protection
Block traffic from two countries on /admin onlyWAF geo match with a URI scope-downCloudFront geo restriction is all-or-nothing per distribution
Apply the same web ACL to every ALB in 40 accounts, including new onesFirewall Manager WAF policyCentral, auto-remediating, covers new resources
Chapter 6 · Part 6.3

Network security controls

Security groups, NACLs, Network Firewall, DNS Firewall, and segmentation.

Task 3.3.1 · SG vs NACL

Security groups and network ACLs in depth

Know the mechanics, not just "stateful vs stateless".

Security groupNetwork ACL
Attached toENI (instance, Lambda in VPC, RDS, endpoint, ALB…)Subnet (every ENI in it)
StateStateful: return traffic allowed automatically (connection tracking)Stateless: allow return traffic explicitly (ephemeral ports 1024–65535)
RulesAllow only; all rules evaluated togetherAllow and deny; numbered, lowest first, first match wins
DefaultNew SG: no inbound, all outboundDefault NACL allows all; a new custom NACL denies all
ReferencesOther SGs (same VPC, peered VPC, or across Transit Gateway when enabled), prefix listsCIDRs only
Quotas (default)60 inbound + 60 outbound rules per SG; 5 SGs per ENI (adjustable)20 rules per direction (adjustable to 40)
Use forPrimary micro-segmentationCoarse subnet guardrails, explicit deny of an IP range
Task 3.3.1 / 2.2.4 · Connection tracking

Why changing a security group may not cut an attacker off

Removing a rule does not interrupt an existing tracked flow. This matters during containment.

Tracked vs untracked

  • Most flows are tracked: once allowed, they continue until idle timeout, even after you remove the rule.
  • TCP/UDP flows are untracked only when one direction allows that traffic from/to 0.0.0.0/0 (or ::/0) and the other direction allows all response traffic to/from 0.0.0.0/0 on all ports. ICMP is always tracked.
  • Always tracked regardless of rules: flows via NLB, NAT gateway, Network Firewall endpoints, PrivateLink, Lambda Hyperplane ENIs.
  • Untracked flows stop immediately when the allowing rule is removed.

Containment options

  • Swap to an isolation SG with no rules: blocks new connections, existing tracked ones may persist.
  • Add NACL deny rules on the subnet: stateless, cuts existing flows immediately — but affects every ENI in the subnet.
  • Better: move the instance to a dedicated quarantine subnet with a deny-all NACL.
  • Shorten idle timeouts with the ENI connection tracking configuration.

Exam rule of thumb

  • "Immediately stop all traffic, including existing sessions" → NACL (or quarantine subnet).
  • "Isolate one instance without affecting neighbours" → isolation SG (accept tracked flows).
  • Always snapshot and capture memory before you stop or terminate.
Task 3.3.1 · Network Firewall

AWS Network Firewall: architecture

A managed stateful firewall and IPS that you insert into the routing path.

Building blocks

  • Firewall = endpoints (one per AZ) in dedicated firewall subnets.
  • Firewall policy = stateless + stateful rule groups + default actions.
  • Traffic only goes through it if route tables send it there.
  • TLS inspection configuration (decrypt, inspect, re-encrypt) with ACM certificates.
  • Logs: alert and flow logs to S3, CloudWatch Logs or Firehose.

Distributed

  • A firewall in each VPC: IGW → firewall subnet → workload subnet.
  • IGW ingress route table (edge association) sends inbound traffic to the endpoint.
  • Simple, but many firewalls to manage (use Firewall Manager).

Centralized (TGW)

  • A shared inspection VPC attached to Transit Gateway.
  • Spoke VPC route tables send 0.0.0.0/0 to the TGW; TGW sends it to the inspection VPC.
  • Enable appliance mode on the inspection VPC attachment for symmetric routing across AZs.
  • Inspects east/west (VPC↔VPC) and north/south (egress via a central NAT/IGW).
  • Since Jul 2025: native TGW attachment for Network Firewall — no inspection VPC subnets to manage; appliance mode always on.
Task 3.3.1 · Network Firewall rules

Stateless, stateful, and Suricata rules

Rule order is the most common source of confusion.

Stateless rule groups

  • Evaluated first, in priority order, on 5-tuple only.
  • Actions: pass, drop, or forward to stateful engine (the usual default).
  • Use for fast drops; no protocol awareness.

Stateful rule groups

  • Domain list: allow/deny by SNI and HTTP Host (egress allow-listing).
  • 5-tuple standard rules.
  • Suricata-compatible IPS rules for protocol and payload signatures.
  • AWS managed threat signature groups (malware, botnet, etc.).

Rule evaluation order

  • Strict order (recommended): rules run by priority you set; set a default drop.
  • Action order (legacy default): pass → drop → reject → alert, regardless of rule position.
  • Strict order makes "allow these domains, drop everything else" easy.
# Suricata rule: drop outbound TLS to a domain not on the allow list is handled by a domain list;
# this example alerts on any TLS SNI ending in .xyz
alert tls $HOME_NET any -> $EXTERNAL_NET 443 (tls.sni; content:".xyz"; endswith; msg:"TLS to .xyz"; sid:1000001; rev:1;)
Task 3.3.1 · DNS controls

Route 53 Resolver DNS Firewall

Block exfiltration and malware callbacks at the DNS layer, for every VPC that uses the Resolver.

How it works

  • Rule groups associated with VPCs; rules match domain lists.
  • Actions: ALLOW, ALERT, or BLOCK (respond NODATA, NXDOMAIN, or OVERRIDE to a CNAME).
  • AWS managed domain lists: malware, botnet C2, aggregate threat list.
  • DNS Firewall Advanced detects DGA domains and DNS tunneling.
  • Share rule groups with RAM; deploy org-wide with Firewall Manager.

Design decisions

  • Fail mode: open (availability) vs closed (security) when the firewall cannot respond.
  • Walled garden: ALLOW your domains, BLOCK * with lower priority.
  • Log with Resolver query logs to see who asked for what.
  • Limitation: only covers queries to the VPC Resolver; a host using 8.8.8.8 bypasses it — block outbound 53 elsewhere.

Network Firewall vs DNS Firewall

  • DNS Firewall: blocks the lookup, cheap, no routing changes.
  • Network Firewall domain list: blocks the connection by TLS SNI / HTTP Host, so it still works if the client used another resolver.
  • Connections to a raw IP with no SNI/Host need IP-based rules.
  • Use both for defense in depth.
Task 3.3.4 · Segmentation

Segmentation patterns: north/south and east/west

Design so that one compromised workload cannot reach everything.

North/south (internet ↔ VPC)

  • Ingress through CloudFront/ALB in public subnets only.
  • Egress through NAT + Network Firewall domain allow-list.
  • VPC Block Public Access: bidirectional or ingress-only, at account/Region level, with VPC/subnet exclusions.
  • Enforce it org-wide with a declarative policy.

East/west (VPC ↔ VPC, tier ↔ tier)

  • Account and VPC per environment; no prod↔dev routes.
  • Transit Gateway route tables as segments (prod, non-prod, shared).
  • SG references between tiers instead of CIDRs.
  • Centralized inspection for inter-VPC traffic.

Isolated subnets

  • No route to IGW or NAT at all.
  • Reach AWS services only via VPC endpoints.
  • For databases, HSMs, data processing.
  • Combine with endpoint policies and aws:SourceVpce for a data perimeter.
Chapter 6 · Part 6.4

Private and hybrid connectivity

VPC endpoints, PrivateLink, zero-trust access, VPN, Direct Connect, and finding unwanted paths.

Task 5.1.2 · VPC endpoints

Gateway vs interface endpoints

Both keep traffic off the internet; they work very differently.

Gateway endpointInterface endpoint (PrivateLink)
ServicesS3 and DynamoDB onlyMost AWS services, your own services, SaaS
MechanismPrefix-list route in the route tableENI with private IPs in your subnets; private DNS
Access from on-prem / peered VPCNoYes (via VPN, DX, TGW, peering)
Security controlsEndpoint policy; bucket policy aws:SourceVpceEndpoint policy + security group on the ENI
CostFreePer hour per AZ + per GB
Cross-RegionSame Region onlySame Region (cross-Region PrivateLink for some services)

With endpoints, the request source is a private IP, so aws:SourceIp no longer matches. Use aws:SourceVpce, aws:SourceVpc or aws:VpcSourceIp in resource policies.

Task 5.1.2 · Endpoint policies

Endpoint policy + bucket policy = a data perimeter

The endpoint policy limits what can pass through the endpoint; the bucket policy limits where requests can come from.

{
  "Statement": [{
    "Effect": "Allow",
    "Principal": "*",
    "Action": "s3:*",
    "Resource": "*",
    "Condition": {
      "StringEquals": {
        "aws:PrincipalOrgID": "o-a1b2c3d4e5",
        "aws:ResourceOrgID": "o-a1b2c3d4e5"
      }
    }
  }]
}
{
  "Statement": [{
    "Effect": "Deny",
    "Principal": "*",
    "Action": "s3:*",
    "Resource": ["arn:aws:s3:::pii-bucket",
                 "arn:aws:s3:::pii-bucket/*"],
    "Condition": {
      "StringNotEquals": {
        "aws:SourceVpce": "vpce-0a1b2c3d4e5f67890"
      }
    }
  }]
}

Left: endpoint policy (only org principals, only org buckets). Right: bucket policy (deny unless via our endpoint). Endpoint policies never grant: IAM and resource policies must still allow (default endpoint policy = full access). Together they block exfiltration to an attacker’s bucket. The bucket deny also locks out the console and AWS services, so add exceptions such as aws:PrincipalIsAWSService with care.

Task 3.3.3 · Zero trust and remote access

Verified Access vs Client VPN vs PrivateLink

Three ways to give someone or something private access — with different trust models.

AWS Verified Access

  • Zero trust: every request (HTTP) or connection (TCP, SSH, RDP — GA Feb 2025) is evaluated.
  • Trust providers: identity (IAM Identity Center, OIDC) and device (e.g. Jamf, CrowdStrike, JumpCloud).
  • Policies written in Cedar on user and device claims.
  • No VPN client for web apps; access logs in OCSF.
  • Can be protected by WAF.

AWS Client VPN

  • Managed OpenVPN endpoint into a VPC.
  • Auth: mutual certificate, Active Directory, or SAML federation; MFA via AD/IdP.
  • Authorization rules per network/group; SGs on the endpoint.
  • Split tunnel to send only VPC traffic.
  • Network-level access: once connected, reach what the rules allow.

PrivateLink service

  • Expose one service (NLB/GWLB) to other VPCs/accounts without routing.
  • Consumers see only an endpoint, not your network.
  • Overlapping CIDRs are fine.
  • Allow-list consumer principals; require acceptance.
Task 3.3.2 · Hybrid connectivity

Site-to-Site VPN, Direct Connect, and MACsec

Direct Connect is private, not encrypted. Decide how to encrypt it.

Site-to-Site VPN

  • IPsec, two tunnels per connection (different AZ endpoints) for HA.
  • Terminates on a virtual private gateway or Transit Gateway.
  • IKEv1/IKEv2; restrict to strong ciphers and IKEv2 in tunnel options.
  • Accelerated VPN (Global Accelerator) on TGW.
  • Tunnel logs to CloudWatch Logs.

Direct Connect encryption

  • MACsec: Layer 2 encryption on the cross-connect between your router and the DX device.
  • Dedicated 10, 100, 400 Gbps connections at selected locations (not hosted).
  • AES-256 (GCM-AES-256 / XPN); static CKN/CAK keys you rotate.
  • Mode should_encrypt (default) vs must_encrypt.
  • Alternative: IPsec VPN over DX (public VIF, or private IP VPN over a transit VIF).

Choosing

  • Need encryption quickly and cheaply → Site-to-Site VPN.
  • Consistent bandwidth + encryption at line rate → DX + MACsec.
  • Hosted connection that needs encryption → IPsec over DX.
  • MACsec is point-to-point, not end-to-end: still use TLS in the app.
Task 3.3.5 · Find unnecessary access

Network Access Analyzer, Reachability Analyzer, Inspector

Prove what can reach what — without sending a packet.

ToolQuestion it answersExample
Network Access AnalyzerWhich paths match a scope I define as unwanted?"Any path from an IGW to a resource tagged tier=db" → findings
VPC Reachability AnalyzerCan source A reach destination B, and which component blocks it?Debug: why can the ECS task not reach RDS on 5432?
Inspector network reachabilityWhich EC2 ports are reachable from the internet / outside the VPC?Finding: port 22 open via IGW → SG → ENI
IAM Access Analyzer (external access)Which resource policies grant access outside my zone of trust?S3 bucket shared to an unknown account
Verified Access logsWho accessed which internal app, with which device posture?Audit contractor access

Network Access Analyzer is the tool for continuous compliance ("no database is ever internet-reachable"); Reachability Analyzer is the tool for one-off troubleshooting.

Exam traps

Network and connectivity traps

Wrong answers that look right.

NACL return traffic

  • Forgetting outbound ephemeral ports on a NACL breaks responses.
  • A deny for one IP must have a lower rule number than the allow.

Firewall not in path

  • Network Firewall only inspects traffic routed to its endpoints.
  • Missing appliance mode on the TGW attachment → asymmetric drops.

DX is not encrypted

  • "Private" ≠ "encrypted". Use MACsec or IPsec over DX.
  • MACsec is not available on hosted connections.

Gateway endpoint reach

  • On-prem clients cannot use an S3 gateway endpoint; use an S3 interface endpoint.

SourceIp via endpoint

  • aws:SourceIp does not match private IPs through endpoints.

DNS bypass

  • DNS Firewall only sees queries to the Route 53 Resolver; block outbound port 53/853 to other resolvers.
Exam-style scenarios

Network scenarios

Scenario → answer → why.

ScenarioAnswerWhy
Allow egress only to a list of SaaS domains from 30 VPCsCentral inspection VPC + Network Firewall stateful domain list (strict order, default drop)Domain-aware egress filtering, managed once
Instances must never resolve known malware domainsRoute 53 Resolver DNS Firewall with AWS managed domain listsBlocks at lookup, no routing change
Contractors need SSH to 5 private hosts, with device posture checks, no VPNVerified Access (TCP/SSH) with identity + device trust providersPer-connection zero-trust evaluation
DX must be encrypted at 100 Gbps line rateDedicated 100 Gbps DX with MACsecIPsec VPN tunnels cannot reach that throughput
Continuously prove no RDS instance is reachable from an IGWNetwork Access Analyzer scopePath analysis against a defined scope
Stop an active attacker session on one EC2 instance right nowQuarantine subnet / NACL deny (then SG isolation)SG changes do not cut tracked connections
Chapter 6 · Part 6.5

Compute security

Hardened images, roles for workloads, vulnerability management, patching, and access without SSH keys.

Task 3.2.1 · Golden images

Hardened AMIs and container images

Build security in once, then deploy only approved images.

EC2 Image Builder

  • Recipe = parent image + components (build and test).
  • Amazon-managed hardening components (e.g. STIG); CIS-hardened images via Marketplace.
  • Image scanning with Inspector during the pipeline.
  • Distribution settings: share AMIs to OUs/accounts, copy to Regions, encrypt with KMS.
  • Schedule rebuilds when the parent image or a component changes.

Systems Manager in the image

  • SSM Agent preinstalled; instance joins Fleet Manager.
  • State Manager associations re-apply baseline config (drift).
  • Run Command / Automation for CIS remediation.
  • Remove SSH keys and password logins from the image.

Container images

  • Minimal or distroless base, run as non-root, read-only root filesystem.
  • ECR: immutable tags, enhanced scanning (Inspector) on push and continuously.
  • Sign images (AWS Signer / Notation) and verify at deploy.
  • No secrets in layers; pin base image digests.

Enforce "only approved AMIs" with the EC2 Allowed AMIs setting (also available as a declarative policy) and with IAM conditions on ec2:RunInstances.

Task 3.2.1 · IMDSv2

Instance metadata: require IMDSv2

IMDSv1 can be abused through SSRF to steal role credentials. IMDSv2 requires a session token obtained with PUT.

# IMDSv2: get a token, then use it
TOKEN=$(curl -sX PUT http://169.254.169.254/latest/api/token \
  -H "X-aws-ec2-metadata-token-ttl-seconds: 21600")
curl -s -H "X-aws-ec2-metadata-token: $TOKEN" \
  http://169.254.169.254/latest/meta-data/iam/security-credentials/

# Enforce on an existing instance
aws ec2 modify-instance-metadata-options --instance-id i-0abc \
  --http-tokens required --http-put-response-hop-limit 1

# Account default for new instances in a Region
aws ec2 modify-instance-metadata-defaults --http-tokens required

Enforcement layers

  • Per instance: HttpTokens=required.
  • Per AMI: ImdsSupport=v2.0 so launches default to v2.
  • Account/Region default; org-wide via declarative policy.
  • SCP: deny ec2:RunInstances unless ec2:MetadataHttpTokens = required.
  • Hop limit 1 blocks containers on the host from IMDS; use 2 only when they must reach it.
  • Find v1 usage with the CloudWatch metric MetadataNoToken.
Task 3.2.2 · Workload identity

Instance profiles, service roles, and execution roles

Every compute type gets credentials from a role; know which role is which.

Role typeWho assumes itExampleWatch out for
Instance profile roleEC2 (credentials via IMDS)App on EC2 reads an S3 bucketOne role per instance; all processes share it
Lambda execution roleLambda service for your functionFunction writes to DynamoDB and CloudWatch LogsMissing logs:* → no logs at all
ECS task execution roleECS agentPull from ECR, send logs, fetch secrets for env varsNot used by your application code
ECS task roleYour containerApp calls SQSThe role your code should use
EKS Pod Identity / IRSAA Kubernetes service accountPod reads Secrets ManagerBlock IMDS so pods cannot use the node role
Service roleAn AWS service acting for youCodeBuild, Config, Step FunctionsTrust policy + aws:SourceArn against confused deputy
Service-linked roleA service, with AWS-defined permissionsAWSServiceRoleForECSNot restricted by SCPs; you cannot edit permissions
Task 3.2.3 · Vulnerability scanning

Amazon Inspector and GuardDuty Runtime Monitoring

Inspector finds what is vulnerable; GuardDuty finds what is being attacked or misbehaving at runtime.

Amazon Inspector

  • EC2: agent-based (SSM Agent) or agentless (EBS snapshot) package scanning; CIS benchmark assessments.
  • ECR: enhanced scanning on push and continuously as new CVEs appear.
  • Lambda: standard (packages) and code scanning.
  • Code security: SAST, SCA and IaC scanning of source repositories.
  • Network reachability findings for EC2.
  • Inspector score adjusts CVSS with your environment; EPSS shows exploit likelihood.

GuardDuty Runtime Monitoring

  • Security agent on EKS, ECS (Fargate and EC2) and EC2; GuardDuty can manage the agent.
  • Detects reverse shells, crypto miners, privilege escalation, suspicious file and process activity.
  • Feeds Extended Threat Detection attack sequences for EC2, ECS and EKS.
  • Malware Protection for EC2 scans EBS volumes when a finding fires.

Operating it

  • Delegated admin enables both org-wide; auto-enable for new accounts.
  • Findings flow to Security Hub and EventBridge.
  • Suppression rules for accepted risk, with expiry.
  • Block deploys on critical findings in CI (ECR scan gate).
Task 3.2.4 · Patching

Systems Manager Patch Manager

Automate patching and prove compliance continuously.

Patch baselines

  • Predefined (AWS) or custom per OS.
  • Auto-approve after N days by classification and severity.
  • Explicit approved / rejected patch lists.
  • Compliance severity level for reporting.

Targeting and scheduling

  • Patch policies (Quick Setup) across the org and Regions — the recommended approach.
  • Legacy: patch groups via the Patch Group tag + maintenance windows.
  • Run AWS-RunPatchBaseline with operation Scan or Install.
  • Rate control and error thresholds for safe rollout.

Continuous validation

  • Patch compliance in Systems Manager Compliance and AWS Config.
  • Inspector re-scans after patching, closing findings.
  • Immutable alternative: rebuild the AMI with Image Builder and replace instances.
  • Containers and Lambda: rebuild and redeploy; nothing to patch in place.
Task 3.2.5 · Admin access

Session Manager and EC2 Instance Connect

No bastions, no long-lived SSH keys, every session logged.

Session Manager

  • No inbound ports; the SSM Agent makes outbound HTTPS connections.
  • Needs: SSM Agent, an instance role (e.g. AmazonSSMManagedInstanceCore) or Default Host Management Configuration, and reach to SSM endpoints (VPC endpoints for private subnets).
  • Access controlled with IAM (ssm:StartSession, tag conditions).
  • Logs session data to S3 / CloudWatch Logs, encrypted with KMS; CloudTrail records who started it.
  • Port forwarding and SSH tunnelling through Session Manager.

EC2 Instance Connect

  • Pushes a one-time SSH public key valid for 60 seconds, authorized by IAM.
  • EC2 Instance Connect Endpoint: SSH/RDP to instances in private subnets without a bastion or public IP.
  • Controlled by IAM and the endpoint’s security group.
  • Every key push is a CloudTrail event.

Exam choice

  • "No inbound ports, audit full session output" → Session Manager.
  • "Must use native SSH clients, private subnet, no bastion" → Instance Connect Endpoint.
  • "Restrict who can connect to prod" → IAM condition on resource tags.
Task 3.2.6 · Pipeline security

Find vulnerabilities before they deploy

Shift left: scan code, dependencies, IaC and images in the pipeline.

Code and dependencies

  • Amazon Q Developer: code reviews and security scanning in the IDE and on pull requests.
  • Amazon Inspector code security: SAST, SCA and IaC scanning of GitHub/GitLab repositories.
  • Secrets detection before commit.
  • Amazon CodeGuru Security ended support on 20 Nov 2025 but is still named in skill 3.2.6.

Images and infrastructure

  • ECR enhanced scanning gate: fail the build on critical CVEs.
  • IaC checks: CloudFormation Guard, cfn-lint, Checkov, Trivy.
  • Sign artifacts; verify signatures at deploy.
  • Generate SBOMs (Inspector can export them).

Pipeline itself

  • CI assumes AWS roles with OIDC, not long-lived keys.
  • Least-privilege deploy roles per environment.
  • Protect the pipeline config as production code.
  • Log and alert on pipeline role use in CloudTrail.
Chapter 6 · Part 6.6

GenAI application security

OWASP Top 10 for LLM Applications and the AWS guardrails that address them.

Task 3.2.7 · OWASP LLM Top 10

OWASP Top 10 for LLM Applications (2025)

C03 adds GenAI guardrails. Map each risk to a control.

IDRiskAWS-side controls
LLM01Prompt injection (direct and indirect)Bedrock Guardrails prompt-attack filter; treat retrieved content as untrusted
LLM02Sensitive information disclosureGuardrails sensitive information filters (mask/block PII); Macie on training data
LLM03 / LLM04Supply chain; data and model poisoningTrusted model sources, signed artifacts, versioned and access-controlled training data
LLM05Improper output handlingValidate and encode model output before using it in SQL, shell, HTML
LLM06Excessive agencyLeast-privilege IAM for agent tools; human confirmation for actions
LLM07 / LLM08System prompt leakage; vector and embedding weaknessesNo secrets in prompts; per-tenant access control on knowledge bases
LLM09 / LLM10Misinformation; unbounded consumptionContextual grounding checks; quotas, WAF rate limits, token limits
Task 3.2.7 · Bedrock Guardrails

Amazon Bedrock Guardrails and GenAI data protection

Guardrails evaluate both the user input and the model output.

Guardrail policies

  • Content filters: hate, insults, sexual, violence, misconduct, and prompt attacks, with strength levels.
  • Denied topics described in natural language.
  • Word filters (custom list, profanity).
  • Sensitive information filters: PII types and regex, Block or Mask.
  • Contextual grounding check (hallucination vs source) and Automated Reasoning checks.

Using them

  • Attach to model invocations, agents and knowledge bases.
  • ApplyGuardrail API checks text for any model, even outside Bedrock.
  • Versioned; enforce a specific guardrail with the IAM condition bedrock:GuardrailIdentifier.
  • Trace output shows which policy intervened.

Data and access

  • Bedrock does not use your prompts or outputs to train base models.
  • Private access via VPC interface endpoints; encrypt custom models and knowledge bases with KMS.
  • Invocation logging to S3 / CloudWatch (enable deliberately; may contain PII).
  • Agent action groups call Lambda with least-privilege roles.
  • GuardDuty AI Protection watches for suspicious Bedrock and SageMaker AI activity.
Exam traps and scenarios

Compute and GenAI

Scenario → answer → why, plus the traps.

ScenarioAnswerWhy
SSRF in a web app stole EC2 role credentialsRequire IMDSv2 (hop limit 1), enforce with SCP/declarative policyIMDSv2 needs a PUT token that SSRF usually cannot obtain
Admins need shell access, no inbound ports, full session logsSession Manager with S3/CloudWatch logging + KMSOutbound-only agent, IAM-controlled, logged
Know immediately when a new CVE affects running containersInspector ECR enhanced (continuous) scanningRe-evaluates images when new CVEs are published
Detect a reverse shell inside an ECS Fargate taskGuardDuty Runtime Monitoring for ECS FargateInspector does not watch runtime behavior
ECS app gets AccessDenied calling SQS though the execution role allows itGrant SQS on the task roleExecution role is for the agent, not app code
Chatbot must never reveal customer phone numbersBedrock Guardrails sensitive information filter (Mask) on outputApplied to responses regardless of the prompt
Self-check

Infrastructure security: can you answer these?

Explain the answer and name the exact control.

Edge

  • Why does OAI fail with SSE-KMS objects, and what replaces it?
  • When do you choose signed cookies over signed URLs?
  • How would you rate-limit by client when the ALB sits behind CloudFront?
  • What do you get from Shield Advanced that Standard lacks?
  • How do labels help tune a managed rule group?

Network

  • Why might an isolation SG not stop an attacker’s session?
  • What does appliance mode fix in a TGW inspection design?
  • Strict order vs action order in Network Firewall?
  • How do endpoint and bucket policies combine into a perimeter?
  • How do you encrypt Direct Connect, and at what layer?

Compute and GenAI

  • Name four ways to enforce IMDSv2.
  • Task role vs task execution role?
  • Inspector vs GuardDuty Runtime Monitoring?
  • Patch policies vs patch groups?
  • Which OWASP LLM risk does least-privilege agent IAM address?
Chapter 7

Data protection

Keys, encryption at rest and in transit, integrity, backups, and secrets — Domain 5, 18% of the exam.

Chapter 7 · Part 7.1

AWS KMS fundamentals

Key types, envelope encryption, encryption context, quotas, and the key lifecycle.

Task 5.2.1 · Key types

Three owners, three levels of control

Who owns the key decides who can see it, audit it, share it, and delete it.

AWS owned keyAWS managed keyCustomer managed key
ExampleDynamoDB default table encryptionaws/s3, aws/ebs, aws/rdsAny key you create
Visible in your accountNoYesYes
Key policyAWS controlsFixed by AWS; read onlyYou write it
CloudTrail usage eventsNoYesYes
RotationAWS decidesEvery year, automaticOptional automatic + on-demand
Cross-account useNoNoYes, via key policy + IAM
CostFreeNo monthly fee; pay per requestMonthly fee + per request

Exam rule of thumb: “share encrypted snapshots/secrets with another account”, “control the key policy”, “disable or delete the key” or “audit who used the key” all mean a customer managed key.

Task 5.2.1 · Key specs

Symmetric, asymmetric, and HMAC keys

Most AWS integrations need a symmetric encryption key; the others solve specific problems.

Symmetric (SYMMETRIC_DEFAULT)

  • AES-256-GCM; the key material never leaves KMS unencrypted.
  • The only type AWS services use for server-side encryption.
  • Supports GenerateDataKey, encryption context, rotation.
  • Ciphertext is bound to this exact key.

Asymmetric (RSA, ECC, ML-DSA, SM2)

  • Key pair: the public key can be downloaded.
  • RSA: encrypt/decrypt or sign/verify; ECC: sign/verify or key agreement; ML-DSA: sign/verify.
  • Use when callers outside AWS must encrypt or verify.
  • No automatic rotation; lower request quotas (1,000 rps).

HMAC

  • GenerateMac / VerifyMac with a secret symmetric key.
  • Tokens, message authentication, integrity checks.
  • Key never leaves KMS; no automatic rotation.
  • Counts against the symmetric request quota.

Code signing for Lambda uses AWS Signer, not a raw KMS asymmetric key; container images are signed with AWS Signer (Notation) or with cosign and a KMS key.

Task 5.2.1 · Envelope encryption

Why KMS encrypts keys, not your data

KMS Encrypt accepts at most 4 KB. Real data is encrypted locally with a data key.

1 · GenerateDataKey

  • App calls KMS with the key ID.
  • KMS returns a plaintext data key and the same key encrypted under the KMS key.
→

2 · Encrypt locally

  • App encrypts data with the plaintext data key (AES-GCM).
  • Then wipes the plaintext key from memory.
→

3 · Store together

  • Store ciphertext + encrypted data key side by side.
  • Only the encrypted data key is persisted.
→

4 · Decrypt later

  • Send the encrypted data key to KMS Decrypt.
  • KMS checks the key policy, returns the plaintext data key.

Why it matters

  • KMS never sees your data; only small keys travel to KMS.
  • Revoking access to the KMS key makes every data key undecryptable.
  • The AWS Encryption SDK implements this pattern, including data key caching.

Variants

  • GenerateDataKeyWithoutPlaintext: create now, decrypt later (e.g. a pipeline stage).
  • GenerateDataKeyPair: asymmetric data keys for client-side signing or encryption.
  • ReEncrypt: move ciphertext to another KMS key without exposing plaintext.
Task 5.2.1 · Encryption context

Additional authenticated data you can authorize on

Non-secret key–value pairs bound to the ciphertext: decrypt must supply the same context.

aws kms encrypt --key-id alias/app \
  --plaintext fileb://token.bin \
  --encryption-context tenant=acme,purpose=invoice

# Decrypt fails with InvalidCiphertextException
# unless the same context is supplied.

Properties

  • Not secret: it is logged in plaintext in CloudTrail.
  • Gives integrity: a ciphertext cannot be moved to another “tenant”.
  • AWS services set it for you, e.g. S3 uses the object or bucket ARN, Secrets Manager the secret ARN.
{
  "Effect": "Allow",
  "Principal": {"AWS": "arn:aws:iam::111122223333:role/acme-app"},
  "Action": "kms:Decrypt",
  "Resource": "*",
  "Condition": {
    "StringEquals": {"kms:EncryptionContext:tenant": "acme"}
  }
}

Exam use

  • Multi-tenant isolation with one key: condition on kms:EncryptionContext:<key>.
  • kms:EncryptionContextKeys requires that a context key is present.
  • Audit: filter CloudTrail by context to see which object was decrypted.
Task 5.2.1 · Quotas and throttling

KMS is a shared, rate-limited dependency

Every SSE-KMS read and write is a KMS call counted against the caller account.

Default request quotas (per account, per Region)

QuotaDefault
Symmetric crypto ops (shared: Encrypt, Decrypt, GenerateDataKey, ReEncrypt, GenerateMac…)10,000 rps; 20,000 in some Regions; 100,000 in us-east-1, us-west-2, eu-west-1
RSA crypto ops1,000 rps
ECC / SM2 crypto ops1,000 rps
Each CloudHSM or external key store1,800 rps (not adjustable)
CreateGrant50 rps

Handling ThrottlingException

  • Cross-account calls count against the *calling* account, not the key owner.
  • S3 Bucket Keys cut S3→KMS calls dramatically.
  • Data key caching in the AWS Encryption SDK reuses keys.
  • Exponential backoff with jitter; quotas (except key stores) are adjustable.
  • Monitor usage in Service Quotas with CloudWatch alarms.
Task 5.2.1 · Key lifecycle

Key states, disabling, and deletion

Deletion is irreversible for symmetric keys, so KMS forces a waiting period.

Key states

  • Enabled → usable.
  • Disabled → crypto calls fail; reversible with EnableKey.
  • PendingDeletion → unusable, rotation stops, cancellable.
  • PendingImport → imported key with no material yet.
  • Unavailable → custom key store disconnected.

Scheduling deletion

  • Only customer managed keys can be deleted.
  • Waiting period 7–30 days; default 30.
  • CancelKeyDeletion returns the key to Disabled.
  • Multi-Region primary: delete all replicas first.
  • Ciphertexts under a deleted symmetric key are lost forever.

Detect misuse during the wait

  • CloudTrail logs ScheduleKeyDeletion and the final DeleteKey.
  • Use a metric filter / EventBridge rule on calls that fail with “pending deletion”.
  • Prefer disabling when unsure.
  • Guardrail: SCP denying kms:ScheduleKeyDeletion except for a key admin role.

Data keys already decrypted in memory (EBS volumes attached, RDS running) keep working until the resource needs KMS again, e.g. on reboot or reattach.

Chapter 7 · Part 7.2

KMS access control

Key policies, IAM delegation, grants, and condition keys for least-privilege key use.

Task 5.3.5 · Key policy

The key policy is the root of all access

Unlike most resources, IAM alone cannot grant access to a KMS key; the key policy must allow it first.

{
  "Sid": "Enable IAM User Permissions",
  "Effect": "Allow",
  "Principal": {"AWS": "arn:aws:iam::111122223333:root"},
  "Action": "kms:*",
  "Resource": "*"
},
{
  "Sid": "Allow key administrators",
  "Effect": "Allow",
  "Principal": {"AWS": "arn:aws:iam::111122223333:role/KeyAdmin"},
  "Action": ["kms:Create*","kms:Describe*","kms:Enable*","kms:List*",
             "kms:Put*","kms:Update*","kms:Revoke*","kms:Disable*",
             "kms:Get*","kms:Delete*","kms:ScheduleKeyDeletion",
             "kms:CancelKeyDeletion","kms:TagResource","kms:UntagResource"],
  "Resource": "*"
}

How to read it

  • The :root principal means *the account*, not the root user.
  • That statement delegates to IAM: IAM policies in the account may now grant key use.
  • Remove it and only principals named in the key policy can use the key.
  • Separate key administrators (manage) from key users (encrypt/decrypt).
  • Key administrators do not get kms:Decrypt by default.
  • Lock-out: a policy that names no admin can only be fixed via AWS Support.
Task 5.3.5 · Grants

Grants: temporary, programmatic delegation

AWS services such as EBS, RDS and Secrets Manager create grants so they can use your key on your behalf.

What a grant is

  • A key + grantee principal + allowed operations + optional constraints.
  • Created with CreateGrant; removed with RetireGrant or RevokeGrant.
  • Eventual consistency: use the grant token to use it immediately.
  • Constraints can require an encryption context.

When services use it

  • Attaching an encrypted EBS volume: EC2 creates a grant for the volume.
  • RDS, Aurora, Redshift keep grants while the resource exists.
  • Condition kms:GrantIsForAWSResource: true lets users let services create grants, but not create grants for themselves.

Audit and clean up

  • aws kms list-grants --key-id …
  • Revoke orphaned grants after incidents.
  • Grants do not appear in the key policy, so reviewing the policy alone misses them.
aws kms create-grant --key-id alias/app --grantee-principal arn:aws:iam::111122223333:role/batch \
  --operations Decrypt GenerateDataKey --constraints EncryptionContextSubset={tenant=acme}
Task 5.3.5 · Condition keys

Narrowing who, how, and from where

Condition keys turn a broad key policy into least privilege.

Condition keyUse
kms:ViaServiceAllow use only through a service in a Region, e.g. s3.us-east-1.amazonaws.com
kms:CallerAccountAllow every principal of an account, typically combined with kms:ViaService (this is how AWS managed keys work)
kms:EncryptionContext:<k>Bind decrypt rights to a tenant, object ARN or purpose
kms:GrantIsForAWSResourceGrants only for AWS services acting on resources
kms:KeySpec, kms:KeyOriginIn IAM policies: who may create which kind of key
aws:PrincipalOrgIDAllow any principal in your organization
aws:SourceVpce / aws:SourceVpcOnly via a VPC endpoint (com.amazonaws.<region>.kms)

A key used only by EBS: allow kms:CreateGrant, Decrypt, GenerateDataKey* with kms:ViaService = ec2.<region>.amazonaws.com and kms:CallerAccount.

Task 4.2.1 · Cross-account keys

Using a key from another account

Two policies must both allow: the key policy in the owner account and IAM in the caller account.

// Account A (key owner): key policy statement
{
  "Sid": "AllowAccountB",
  "Effect": "Allow",
  "Principal": {"AWS": "arn:aws:iam::444455556666:root"},
  "Action": ["kms:Decrypt", "kms:DescribeKey"],
  "Resource": "*"
}
// Account B: IAM policy on the app role
{
  "Effect": "Allow",
  "Action": ["kms:Decrypt", "kms:DescribeKey"],
  "Resource": "arn:aws:kms:us-east-1:111122223333:key/1234abcd-..."
}

Rules

  • Must be a customer managed key; AWS managed keys cannot be shared.
  • Caller must use the full key ARN; aliases do not resolve across accounts.
  • Throttling counts against account B (the caller).
  • Account B cannot manage the key or see its policy unless granted.
  • Shared encrypted EBS/RDS snapshots: share the snapshot and allow the key; the target usually re-encrypts with its own key on copy.
  • An RCP can cap KMS key access to principals in your org.
Exam traps

KMS access-control traps

Each of these appears in scenario questions.

“IAM policy allows it, still AccessDenied”

  • The key policy does not delegate to IAM (no :root statement).
  • Or an explicit deny with a condition (kms:ViaService, context).
  • Or an SCP/RCP/VPC endpoint policy blocks it.

“Share an encrypted snapshot”

  • Fails with aws/ebs or aws/rds.
  • Re-encrypt with a customer managed key, share key + snapshot.
  • The recipient copies it under its own key.

“Key admin can read all data”

  • Not by default — admins need kms:Decrypt explicitly.
  • Separation of duties: admins manage, users use.
  • Use a deny on kms:Decrypt for admin roles to prove it.

“Nobody can manage the key anymore”

  • Key policy lost all admin principals.
  • Only AWS Support can help; prevent with the default statement.

“Delete the key now”

  • Not possible: minimum waiting period is 7 days.
  • For immediate effect, disable the key.

“Grant revoked but access continues”

  • Grants are eventually consistent.
  • Services may hold decrypted data keys in memory.
Chapter 7 · Part 7.3

Key material, rotation, and key stores

Where the key material comes from, how it rotates, and when you need CloudHSM or an external key store.

Task 5.3.2 · Rotation

Rotation rules differ by key type

Rotation adds new key material behind the same key ID; old material stays to decrypt old ciphertexts.

KeyAutomatic rotationOn-demand rotationNotes
AWS managed keyAlways, every yearNoCannot be changed
Customer managed, symmetric, AWS-generatedOptional; period 90–2,560 days (default 365 when enabled)Yes (RotateKeyOnDemand)No re-encryption of data needed
Customer managed, imported material (EXTERNAL)NoYes, since Jun 2025 (symmetric)You import the new material first
Asymmetric or HMACNoNoManual: new key, update alias
CloudHSM or external key storeNoNoManual rotation
Multi-Region keySet on the primary; replicas share materialYes, on the primaryReplicas cannot rotate independently

Manual rotation

  • Create a new key, point the alias to it with UpdateAlias.
  • Keep the old key enabled until old ciphertexts are re-encrypted.
  • Apps must reference the alias, not the key ID.

Inspect

  • aws kms get-key-rotation-status --key-id …
  • aws kms list-key-rotations --key-id …
  • Rotation is logged in CloudTrail (RotateKey).
Task 5.3.3 · Key origin

AWS-generated vs imported key material

Importing (BYOK) gives you control over the material — and responsibility for it.

AWS-generated (AWS_KMS)Imported (EXTERNAL)
Who creates the materialKMS HSMsYou, in your own HSM or tooling
DurabilityManaged by AWSYou must keep a copy; KMS can lose it if expired or deleted
ExpirationNeverOptional expiration date; KMS deletes the material at expiry
Delete the material immediatelyNo (only schedule key deletion)Yes: DeleteImportedKeyMaterial; reversible by reimporting
RotationAutomatic and on-demandOn-demand only (import new material first)
Import process—GetParametersForImport → wrap with public key → ImportKeyMaterial
Use caseDefault choiceRegulatory proof of origin, instant revocation, keys generated outside AWS

A symmetric key cannot be “recreated” from the same material: a new KMS key with identical material cannot decrypt the old ciphertexts. Asymmetric and HMAC material can be reimported into a new key.

Task 5.3.2 · Custom key stores

CloudHSM key store and external key store (XKS)

Both keep the KMS API and integrations, but the root key lives in hardware you control.

AWS CloudHSM key store

  • Key material generated and stored in your CloudHSM cluster.
  • Cluster needs at least two active HSMs in different AZs.
  • KMS uses a kmsuser crypto user in the cluster.
  • You pay for the HSMs and manage cluster availability.
  • Quota: 1,800 rps per key store; symmetric keys only.

External key store (XKS)

  • Key material stays in an HSM *outside* AWS.
  • KMS talks to your XKS proxy (public endpoint or VPC endpoint service).
  • Every crypto call goes to your proxy: latency and availability are yours.
  • Double encryption: KMS also applies its own layer.
  • For sovereignty / “hold your own key” mandates only.

Choosing

  • Default: AWS-generated keys in KMS.
  • Must prove keys are in single-tenant HSMs you control → CloudHSM key store.
  • Keys must never be in AWS → XKS.
  • Need PKCS#11, JCE or CNG directly in the app → CloudHSM itself.
  • Neither supports automatic rotation.
Task 5.3.5 · Multi-Region keys

One key, several Regions

Related keys with the same key ID and key material, so ciphertext moves between Regions without re-encryption.

How they work

  • Key ID starts with mrk-; same ID in every Region, different ARN.
  • One primary and replicas; created with ReplicateKey.
  • Shared: key material, key spec, rotation.
  • Independent: key policy, grants, aliases, tags, enabled state.
  • Not a global resource: each replica is a separate KMS key.

Use cases

  • Client-side encryption with DynamoDB global tables.
  • Disaster recovery: decrypt replicated data in the DR Region.
  • Digital signatures verified in several Regions.
  • Active-active apps that must decrypt locally.

Cautions

  • Exception to “keys never leave a Region” — governance teams may restrict it.
  • Restrict creation with condition kms:MultiRegion.
  • AWS services that encrypt server-side still treat each replica as a separate key.
  • UpdatePrimaryRegion moves the primary role.
Task 5.2.1 · CloudHSM vs KMS

When to choose AWS CloudHSM

Both are FIPS 140-3 Level 3; the difference is tenancy, control, and interfaces.

AWS KMSAWS CloudHSM
TenancyMulti-tenant, AWS-managed HSM fleetSingle-tenant HSMs in your VPC
Who controls keysYou via key policy; AWS operates the serviceOnly your crypto users; AWS cannot access keys
InterfacesKMS API; integrates with 100+ servicesPKCS#11, JCE, OpenSSL dynamic engine, KSP/CNG
Typical useServer-side encryption for AWS servicesTLS offload, Oracle/SQL Server TDE, PKI root CA, custom apps
High availabilityBuilt inYou deploy ≥2 HSMs across AZs; backups to S3 are automatic
CostPer key + per requestPer HSM-hour (significant)

Exam keywords: “single-tenant”, “customer has exclusive control”, “PKCS#11”, “SSL/TLS offload” → CloudHSM. “Integrates with S3/EBS/RDS, least operational overhead” → KMS.

Exam-style scenarios

KMS and key material

Read the requirement words; they point to one answer.

ScenarioAnswerWhy
Must be able to make data unreadable immediately, and prove the key came from the on-prem HSMImported key material; DeleteImportedKeyMaterialInstant, reversible removal; BYOK origin
Regulator requires keys never stored in AWSExternal key store (XKS)Material stays outside AWS
S3 uploads throttled by KMS at peakEnable S3 Bucket KeysFar fewer GenerateDataKey calls
Annual rotation without app changesEnable automatic rotation on the customer managed keySame key ID; old material kept
One key, many tenants, no cross-tenant decryptEncryption context + kms:EncryptionContext:tenant conditionCiphertext bound to tenant
Encrypted data must be decryptable in a DR Region without re-encryptionMulti-Region keySame material in both Regions
Chapter 7 · Part 7.4

Certificates and PKI

ACM for public TLS, AWS Private CA for internal identity and mTLS.

Task 5.3.5 · ACM and Private CA

Public certificates vs private PKI

ACM manages certificates for integrated services; AWS Private CA issues certificates you control.

AWS Certificate Manager (public)

  • Free public certificates for ELB, CloudFront, API Gateway, App Runner…
  • DNS validation (recommended, auto-renews) or email validation.
  • Regional: request in each Region; CloudFront needs us-east-1.
  • Imported certificates are not renewed by ACM — monitor expiry.
  • Exportable public certificates exist (paid) for non-integrated targets.

AWS Private CA

  • Managed private root and subordinate CAs; keys in FIPS-validated HSMs.
  • General-purpose mode or short-lived certificate mode (≤7 days validity).
  • Issue via ACM (managed renewal) or directly via API.
  • Share CAs across accounts with AWS RAM.
  • CRL in S3 and/or OCSP for revocation.

Design patterns

  • Root CA in a dedicated security account; subordinate CAs per environment.
  • Keep the root CA offline-like: issue only subordinates.
  • IAM Roles Anywhere trust anchors can be Private CA.
  • EKS / service mesh workload certs via cert-manager issuer for Private CA.
  • Restrict acm-pca:IssueCertificate with templates and conditions.

EventBridge + ACM “Certificate Approaching Expiration” events and the Security Hub CSPM control on expiring imported certificates catch the certificates ACM cannot renew.

Task 5.1.1 · Mutual TLS

mTLS on ALB and API Gateway

mTLS authenticates the client by certificate before any application code runs.

Application Load Balancer

  • Trust store: CA bundle uploaded to S3, optional CRLs.
  • Verify mode: ALB validates the client chain and rejects failures.
  • Passthrough mode: ALB forwards the whole client chain in the X-Amzn-Mtls-Clientcert header; the backend validates.
  • Connection logs record the TLS handshake outcome.

API Gateway (REST and HTTP)

  • Requires a custom domain name.
  • Truststore PEM in S3 (versioned).
  • Disable the default execute-api endpoint so clients cannot bypass mTLS.
  • Certificate details reach authorizers in the request context.

Exam cues

  • “Authenticate IoT devices / partners by certificate” → mTLS.
  • “Offload certificate validation from the app” → ALB verify mode.
  • “App needs the client certificate itself” → passthrough.
  • AWS IoT Core uses X.509 client certificates natively.
Chapter 7 · Part 7.5

Data at rest on Amazon S3

Encryption choices, enforcement, immutability, lifecycle, and secure replication.

Task 5.2.1 · S3 encryption

Five ways to encrypt an S3 object

Since January 2023 every new object is encrypted; the question is with which key and who controls it.

OptionKey managed byAudit in CloudTrailNotes
SSE-S3S3 (AES-256)No KMS eventsDefault for all buckets
SSE-KMSKMS (AWS managed aws/s3 or customer managed)Yes, per requestKey policy controls readers; KMS quotas apply
SSE-KMS + S3 Bucket KeyKMS → bucket-level keyFewer eventsReduces KMS calls and cost; context becomes the bucket ARN
DSSE-KMSKMS, two independent layersYesFor mandates requiring dual-layer encryption
SSE-CCustomer supplies the key per requestNo KMS eventsDisabled by default on new buckets since Apr 2026
Client-sideYou (often KMS via Encryption SDK)DependsS3 never sees plaintext

SSE-C opt-in: call PutBucketEncryption with BlockedEncryptionTypes set to NONE. Blocked requests get HTTP 403. Most designs should use SSE-KMS instead.

Task 5.2.1 · Enforcing encryption

Bucket policies that enforce encryption and TLS

Default encryption covers objects; policies make violations fail loudly.

{
  "Version": "2012-10-17",
  "Statement": [
    {"Sid": "DenyNonTLS", "Effect": "Deny", "Principal": "*",
     "Action": "s3:*",
     "Resource": ["arn:aws:s3:::data-prod", "arn:aws:s3:::data-prod/*"],
     "Condition": {"Bool": {"aws:SecureTransport": "false"}}},
    {"Sid": "DenyWrongKey", "Effect": "Deny", "Principal": "*",
     "Action": "s3:PutObject",
     "Resource": "arn:aws:s3:::data-prod/*",
     "Condition": {"StringNotEqualsIfExists": {
       "s3:x-amz-server-side-encryption-aws-kms-key-id":
         "arn:aws:kms:us-east-1:111122223333:key/1234abcd-..."}}}
  ]
}

Notes

  • Default bucket encryption with a customer managed key makes the header optional for clients.
  • A deny on the key ID stops uploads that name a different key.
  • s3:TlsVersion can require a minimum TLS version (e.g. ≥ 1.2).
  • Readers need both s3:GetObject and kms:Decrypt on the key.
  • Existing objects keep their old encryption: re-encrypt with S3 Batch Operations (copy in place).
Task 5.2.1 · Access controls

Block Public Access and Object Ownership

Two settings that remove whole classes of S3 data leaks.

Block Public Access

  • Four settings: block/ignore public ACLs, block/restrict public bucket policies.
  • Account level overrides bucket level; on by default for new buckets.
  • RestrictPublicBuckets limits access to AWS services and the bucket owner account.
  • Pair with IAM Access Analyzer for S3 to find shared buckets.

Object Ownership

  • Bucket owner enforced: ACLs disabled; the bucket owner owns every object.
  • Default for new buckets since April 2023.
  • Solves cross-account uploads where the writer owned the object.
  • Access then depends only on policies.

Data perimeter on S3

  • aws:PrincipalOrgID in the bucket policy: only your org.
  • aws:SourceVpce: only through your gateway endpoint.
  • VPC endpoint policy: only your org’s buckets (aws:ResourceOrgID).
  • An RCP applies this to every bucket in member accounts.
Task 5.2.2 · Immutability

S3 Object Lock, Glacier Vault Lock, versioning, MFA delete

WORM storage protects integrity against mistakes, insiders, and ransomware.

Object Lock

  • Requires versioning; can be enabled on existing buckets.
  • Locks object *versions*, not keys: new versions can still be added.
  • Governance mode: users with s3:BypassGovernanceRetention + bypass header can delete.
  • Compliance mode: nobody, including the root user, can shorten or remove retention.
  • Legal hold: no expiry; removed with s3:PutObjectLegalHold.

S3 Glacier Vault Lock

  • Lock policy on a Glacier vault (the original Glacier API).
  • InitiateVaultLock → 24 hours to test → CompleteVaultLock.
  • After completion the policy is immutable.
  • For Glacier storage classes in S3, use Object Lock instead.

Versioning and MFA delete

  • Versioning keeps prior versions; delete adds a delete marker.
  • MFA delete: MFA needed to change versioning state or permanently delete a version.
  • Only the root user can enable MFA delete, via CLI/API.
  • Lifecycle rules cannot be used on buckets with MFA delete enabled.

Test retention in governance mode first; compliance mode retention on the wrong objects cannot be undone — the only exit is closing the account.

Task 5.2.3 · Lifecycle and replication

Retention automation and secure replication

Lifecycle controls cost and retention; replication controls copies across Regions and accounts.

S3 Lifecycle

  • Transition by age to Standard-IA, Glacier Instant/Flexible/Deep Archive.
  • Expire current versions; permanently delete noncurrent versions after N days.
  • Abort incomplete multipart uploads.
  • Object Lock retention wins over expiration rules.

Replication with KMS

  • Versioning on source and destination.
  • Enable SseKmsEncryptedObjects in SourceSelectionCriteria.
  • Specify ReplicaKmsKeyID in the destination Region/account.
  • Role needs kms:Decrypt on the source key and kms:Encrypt on the destination key.
  • Destination key policy must allow the replication role.

Cross-account copies against ransomware

  • Owner override: replicas owned by the destination account.
  • Object Lock on the destination bucket.
  • Replication Time Control for a 15-minute SLA.
  • Delete markers are not replicated unless you enable it.
Chapter 7 · Part 7.6

Other data stores, backup, and ransomware protection

EBS, RDS, EFS and FSx encryption plus AWS Backup, DLM and DataSync.

Task 5.2.1 · EBS, RDS, EFS

Encryption at rest beyond S3

Most services encrypt only at creation time; changing it means copying the data.

ServiceHow to enableEncrypt an existing unencrypted resourceGotchas
EBSAccount-level “encryption by default” per RegionSnapshot → copy with encryption → new volumeSnapshots and volumes inherit encryption
RDS / AuroraAt creation, choose a KMS keySnapshot → encrypted copy → restoreCannot share snapshots encrypted with aws/rds
RDS read replicasInherit from the source—Cross-Region replica uses a key in the destination Region
EFSAt creation onlyCreate a new encrypted file system, copy with DataSyncIn transit: mount helper -o tls
DynamoDBAlways encrypted; choose owned, managed or customer managed keySwitch key any timeTable key change is online
EKS (1.28+)Envelope encryption of all Kubernetes API data by defaultOptional customer managed keyDoes not cover node disks or EBS volumes

An SCP condition (ec2:Encrypted) can make encryption mandatory across all accounts; Config rule encrypted-volumes detects stragglers.

Task 5.2.4 · AWS Backup

Central backup with tamper-proof vaults

One service for EBS, EC2, RDS, Aurora, DynamoDB, EFS, FSx, S3 and more, managed across the org.

Building blocks

  • Backup plan: schedule, retention, lifecycle, copy rules.
  • Backup vault: encrypted with a KMS key; access policy on the vault.
  • Backup policies in AWS Organizations push plans to every account.
  • Cross-Region and cross-account copies.
  • Restore testing and Backup Audit Manager frameworks prove recoverability.

Vault Lock

  • Governance mode: authorized users can still remove the lock.
  • Compliance mode: after the grace time the vault and lock are immutable — even for AWS.
  • Grace time minimum 72 hours (ChangeableForDays ≥ 3).
  • Set min/max retention; recovery points cannot be deleted early.
  • Avoid “always” retention under a compliance lock.

Logically air-gapped vault

  • A vault type that is always locked in compliance mode.
  • Share it with other accounts via AWS RAM for restore.
  • Restore even if the source account is compromised.
  • GuardDuty Malware Protection can scan backups.
Task 5.2.4 · Ransomware patterns

Designing backups attackers cannot delete

Assume the production account is fully compromised; recovery must still work.

Isolate

  • Copies in a separate backup account in a separate OU.
  • SCP denies backup deletion except to a break-glass role.
→

Make immutable

  • Vault Lock compliance mode or a logically air-gapped vault.
  • S3 Object Lock for exported data.
→

Separate keys

  • Backup account’s own customer managed key.
  • Attacker deleting the source key cannot affect copies.
→

Prove recovery

  • Restore testing on a schedule.
  • Track RPO/RTO; drill restores with FIS game days.

Other tools

  • Amazon Data Lifecycle Manager: EBS snapshot and EBS-backed AMI policies, cross-Region copy, cross-account sharing, archive tier.
  • AWS DataSync: encrypted (TLS) transfer between on-premises, other clouds and AWS storage, with integrity verification.
  • FSx for Lustre: backups apply to persistent file systems, not scratch.
  • EFS lifecycle: move files to IA/Archive by last access.

Exam cues

  • “Even the root user must not delete backups” → compliance mode lock.
  • “Least effort across all accounts” → Backup policies in Organizations.
  • “Recover if the account is compromised” → cross-account copy / air-gapped vault.
  • “Detect deletion attempts” → EventBridge on DeleteRecoveryPoint, Backup Audit Manager.
Exam traps

Data at rest traps

Small details that flip the answer.

Encryption changes

  • You cannot encrypt an existing RDS instance or EBS volume in place.
  • Enabling default encryption does not re-encrypt existing S3 objects.
  • Changing the default key does not change existing objects either.

Locks

  • Object Lock protects versions; a simple DELETE still adds a delete marker that hides the current object, even in compliance mode.
  • Governance mode is bypassable; compliance is not.
  • Legal hold has no retention date.

Keys and backups

  • Copies encrypted with the source account key are lost if that key is deleted.
  • Use a key owned by the backup account for cross-account copies.
  • AWS managed keys block snapshot sharing.
Chapter 7 · Part 7.7

Data in transit

Enforcing TLS at the edge, between services, and inside the VPC.

Task 5.1.1 · TLS at the edge

Security policies on ELB, CloudFront and API Gateway

Every listener has a policy that fixes protocol versions and cipher suites.

Elastic Load Balancing

  • Console default for new HTTPS/TLS listeners: ELBSecurityPolicy-TLS13-1-2-Res-PQ-2025-09.
  • CLI/CloudFormation default is still ELBSecurityPolicy-2016-08 — set the policy explicitly.
  • PQ policies add hybrid post-quantum key exchange (ML-KEM).
  • FIPS variants for FIPS 140 requirements.
  • Redirect HTTP:80 to HTTPS:443 with a listener rule.

CloudFront

  • Viewer protocol policy: redirect to HTTPS or HTTPS only.
  • Security policy for viewers, e.g. TLSv1.2_2021.
  • Origin protocol policy: HTTPS only to the origin.
  • Certificate from ACM in us-east-1.

API Gateway and others

  • Custom domain with a TLS 1.2+ security policy.
  • Private APIs via interface VPC endpoints.
  • RDS: rds.force_ssl / require_secure_transport parameters.
  • ElastiCache, OpenSearch, MSK: enable in-transit encryption (some only at creation).

Config / Security Hub CSPM controls detect listeners with outdated policies and HTTP listeners without redirects.

Task 5.1.3 · Inter-node encryption

Encryption inside clusters and between instances

New in SCS-C03: traffic between nodes, containers and instances must be encrypted too.

Nitro encryption in transit

  • Supported Nitro instance types encrypt traffic between each other automatically (AES-256).
  • Applies within a VPC or across peered VPCs, between supported instances.
  • No performance impact, no configuration.
  • Not a replacement for TLS where identity matters.

EKS

  • Pod-to-pod: Nitro encryption on supported node types, or a service mesh with mTLS.
  • Kubernetes API data in etcd: KMS envelope encryption.
  • Load balancers: TLS at ALB/NLB, re-encrypt to pods if required.

EMR and SageMaker AI

  • EMR security configuration: in-transit TLS (certificates from S3 PEM bundle or a custom provider), plus local disk and EMRFS at-rest encryption.
  • SageMaker AI: enable inter-container traffic encryption for distributed training.
  • VPC-only mode and VPC endpoints keep traffic off the internet.

VPC Encryption Controls (Nov 2025)

  • Per-VPC setting with monitor and enforce modes.
  • Monitor adds an encryption-status field to flow logs and lists non-compliant resources.
  • Enforce blocks resources that would allow plaintext traffic.
  • Existing VPCs start in monitor mode; can be enforced org-wide via declarative policies.
Task 5.1.2 · Private paths

Keeping traffic off the public internet

Private connectivity reduces exposure; it does not replace encryption.

NeedUseDetail
EC2 → S3/DynamoDB without internetGateway VPC endpointFree; endpoint policy restricts buckets/tables
EC2 → other AWS APIs (KMS, Secrets Manager, STS…)Interface endpoint (PrivateLink)ENI in your subnet; SG + endpoint policy
Expose your service to other VPCs/accountsPrivateLink endpoint service (NLB/GWLB)Consumers see only one service, not your VPC
Remote users → private apps without VPNAWS Verified AccessIdentity and device posture per request
Remote users → whole VPCAWS Client VPNOpenVPN-based, mutual or SAML auth
On-prem → AWSSite-to-Site VPN (IPsec) / Direct Connect + MACsecDX alone is private but not encrypted
Exam-style scenarios

In-transit encryption

Pick the control that satisfies the exact requirement.

ScenarioAnswerWhy
Deny any S3 request not using TLSBucket policy deny on aws:SecureTransport = falseApplies to all principals
Direct Connect traffic must be encrypted at line rateMACsec on dedicated connections (or VPN over DX)DX is not encrypted by default
Prove all traffic in a VPC is encryptedVPC Encryption Controls, monitor then enforceFlow log encryption status + enforcement
ALB must authenticate partner clients by certificateALB mTLS verify mode with a trust storeValidation at the edge
Support PQ-capable clients but keep TLS 1.2 clients workingELBSecurityPolicy-TLS13-1-2-Res-PQ-2025-09Hybrid PQ + TLS 1.3/1.2
Encrypt distributed training trafficSageMaker AI inter-container traffic encryptionInter-node encryption
Chapter 7 · Part 7.8

Secrets and sensitive data

Rotate credentials, choose the right store, discover and mask sensitive data.

Task 5.3.1 · Secrets Manager rotation

How rotation works

A Lambda function (or the owning service) moves a secret through four steps using staging labels.

createSecret

  • Generate a new value.
  • Store it as AWSPENDING.
→

setSecret

  • Change the credential in the database or service.
→

testSecret

  • Log in with AWSPENDING.
→

finishSecret

  • Move AWSCURRENT to the new version.
  • Old version becomes AWSPREVIOUS.

Single user strategy

  • Changes the password of one user in place.
  • Brief window where cached old credentials fail.
  • Simplest; fine for apps that retry.

Alternating users strategy

  • Two users; rotation updates the inactive clone.
  • Old credentials stay valid until the next rotation.
  • Needs a superuser secret to manage users.
  • Recommended for high availability.

Managed rotation

  • The owning service rotates, no Lambda: e.g. RDS/Aurora master password (ManageMasterUserPassword), Redshift.
  • Schedules as often as every 4 hours, in UTC.
  • Rotation Lambda needs network access to the DB and the Secrets Manager endpoint.
Task 5.3.1 · Secret stores

Secrets Manager vs Parameter Store, and cross-account secrets

Choose by rotation needs, size, sharing and cost.

Secrets ManagerParameter Store SecureString
RotationBuilt in (Lambda or managed)None (build your own)
SizeUp to 64 KB4 KB standard, 8 KB advanced
Cross-accountResource policy + customer managed keyAdvanced parameters via AWS RAM
ReplicationMulti-Region replica secretsNo
CostPer secret per month + API callsStandard tier free
EncryptionKMS (aws/secretsmanager or customer managed)KMS

Cross-account access checklist

  • Secret resource policy allows the other account’s role.
  • Secret encrypted with a *customer managed key* (not aws/secretsmanager).
  • Key policy allows kms:Decrypt for that role (with kms:ViaService = secretsmanager).
  • Caller IAM policy allows secretsmanager:GetSecretValue on the secret ARN.
  • Block public secrets: BlockPublicPolicy on PutResourcePolicy.
Task 5.3.4 · Discover and mask

Macie, CloudWatch Logs data protection, SNS message data protection

Find sensitive data at rest and stop it leaking through logs and messages.

Amazon Macie

  • Discovers PII, credentials and financial data in S3.
  • Automated sensitive data discovery (sampling) or targeted jobs.
  • Managed and custom data identifiers, allow lists.
  • Policy findings (bucket public, unencrypted) and sensitive data findings.
  • Discovery results stored in an S3 bucket encrypted with your KMS key.

CloudWatch Logs data protection

  • Data protection policy on a log group or account.
  • Audits and masks matches of managed data identifiers.
  • Masked in Logs Insights, metric filters and subscriptions.
  • Viewing unmasked data needs logs:Unmask.
  • Findings can be sent to CloudWatch Logs, S3 or Firehose.

SNS message data protection

  • Policy on a standard topic with operations: audit, de-identify (mask or redact), deny.
  • Applied to inbound (publish) or outbound (delivery) messages.
  • Stops PII reaching unapproved subscribers.
  • Closed to new customers since 30 Apr 2026; AWS suggests Lambda + Bedrock Guardrails instead. Still named in skill 5.3.4.

Macie findings flow to EventBridge and Security Hub; use EventBridge to tag or quarantine buckets automatically.

Exam-style scenarios

Secrets and sensitive data

Typical SCS-C03 wording and the answer it expects.

ScenarioAnswerWhy
Rotate RDS credentials every 30 days with no downtimeSecrets Manager, alternating users strategyOld user stays valid during rotation
Hard-coded DB password in Lambda environment variablesMove to Secrets Manager; fetch with the extension or SDKRotation + least privilege
Share a secret with a partner accountResource policy + customer managed key policyaws/secretsmanager cannot be shared
Application logs contain credit card numbersCloudWatch Logs data protection policyMask at ingestion; logs:Unmask to view
Find buckets containing PII across 200 accountsMacie with a delegated administrator + automated discoveryOrg-wide, low effort
Prevent PII in notifications to an email subscriberSNS message data protection (de-identify/deny outbound)Exam answer; closed to new customers since Apr 2026
Self-check

Data protection: can you answer without looking?

Explain each answer out loud, then verify in the docs or a lab.

KMS

  • Why can an IAM admin get AccessDenied on a key?
  • What does the :root principal in a key policy mean?
  • Which keys support automatic rotation, and which only on-demand?
  • What happens to an EBS volume when its key is disabled?
  • When would you choose XKS over a CloudHSM key store?

At rest and integrity

  • How do governance and compliance Object Lock modes differ?
  • How do you encrypt an existing unencrypted RDS database?
  • What makes a backup survive a compromised account?
  • Why can an aws/rds snapshot not be shared?
  • What changed for SSE-C in April 2026?

In transit and secrets

  • How do you force TLS 1.2+ for every S3 request?
  • ALB mTLS: verify vs passthrough?
  • What do VPC Encryption Controls monitor and enforce?
  • Single vs alternating users rotation?
  • How do you stop PII appearing in CloudWatch Logs?
Exam strategy

Reading an SCS-C03 question

Most questions have two technically valid answers. The qualifier in the stem picks the winner.

1 · Find the constraint

  • "Least operational overhead" → managed, built-in, automated.
  • "Most cost-effective" → avoid Shield Advanced, CloudHSM, extra appliances.
  • "Across all accounts" → Organizations policy, delegated admin, StackSets.
  • "Without changing application code" → infrastructure-level control.

2 · Classify the control

  • Must never happen → preventive (SCP, RCP, key policy, Object Lock).
  • Need to know when it happens → detective (Config, GuardDuty, CloudTrail).
  • Fix it automatically → EventBridge + SSM Automation or Lambda.
  • Prove it to an auditor → Audit Manager (exam answer; closed to new customers since Apr 2026), Config, Artifact.

3 · Eliminate

  • Long-lived access keys when a role works.
  • Custom code when a native feature exists.
  • Answers that weaken another control (e.g. open a port to "fix" logging).
  • Services that do not do what is claimed (Inspector does not detect threats).

Ordering questions follow real procedures: evidence before containment changes, isolation before termination, and test before rollout.

Exam strategy

Keyword → answer cheat sheet (1/2)

Common stems and the answer they almost always point to.

If the stem says…Think first of
Restrict what member accounts can do, even adminsSCP (does not affect the management account)
Stop outside principals from reaching our S3/KMS/STS, whatever the bucket policy saysRCP with aws:PrincipalOrgID
Enforce IMDSv2 / block public AMIs and snapshots org-wideDeclarative policy for EC2
Let developers create roles without escalatingPermission boundary + condition requiring it
Which resources are shared outside the org?IAM Access Analyzer external access analyzer
Unused roles, keys, and permissionsIAM Access Analyzer unused access analyzer
Workforce SSO with Okta / Entra ID across accountsIAM Identity Center + SAML + SCIM
Exam strategy

Keyword → answer cheat sheet (2/2)

Common stems and the answer they almost always point to.

If the stem says…Think first of
Crypto-mining, malicious IPs, credential exfiltrationGuardDuty (and Detective to investigate)
CVEs in EC2, ECR images, or LambdaAmazon Inspector
PII in S3 bucketsAmazon Macie
Prove logs were not modifiedCloudTrail log file integrity validation
Data must be undeletable for N years, even by rootS3 Object Lock in compliance mode
Single-tenant HSM, PKCS#11, full key controlAWS CloudHSM (or a CloudHSM key store)
Keys must stay outside AWSKMS external key store (XKS)
Lab 1

Organization guardrails: SCP and RCP

Sandbox organization with a Workloads OU. Attach to a test OU first, never the root.

aws organizations enable-policy-type --root-id r-abcd \
  --policy-type SERVICE_CONTROL_POLICY
aws organizations enable-policy-type --root-id r-abcd \
  --policy-type RESOURCE_CONTROL_POLICY

aws organizations create-policy --name deny-other-regions \
  --type SERVICE_CONTROL_POLICY --description "Region guardrail" \
  --content file://deny-regions.json
aws organizations attach-policy --policy-id p-1111 \
  --target-id ou-abcd-test

# test from a member account
aws ec2 describe-instances --region eu-west-3   # expect AccessDenied

Steps and checks

  • Write deny-regions.json with aws:RequestedRegion and NotAction for global services (IAM, STS, Organizations, CloudFront, Route 53, Support).
  • Create an RCP that denies S3 access unless aws:PrincipalOrgID matches your org (exempt service principals).
  • Try reading a bucket from an account outside the org: expect AccessDenied even with a permissive bucket policy.
  • Confirm the management account is unaffected by both.
Lab 2

Organization trail into a Log Archive account

One trail for every account and Region, encrypted, validated, and queryable.

# in the management (or delegated admin) account
aws cloudtrail create-trail --name org-trail \
  --s3-bucket-name log-archive-trail-111122223333 \
  --is-organization-trail --is-multi-region-trail \
  --enable-log-file-validation \
  --kms-key-id arn:aws:kms:us-east-1:111122223333:key/abcd-...
aws cloudtrail start-logging --name org-trail

# prove integrity later
aws cloudtrail validate-logs \
  --trail-arn arn:aws:cloudtrail:us-east-1:999988887777:trail/org-trail \
  --start-time 2026-10-01T00:00:00Z

Steps and checks

  • Bucket policy allows cloudtrail.amazonaws.com with aws:SourceArn of the trail.
  • KMS key policy allows CloudTrail to GenerateDataKey* with the trail encryption context.
  • Create an Athena table from the CloudTrail console; query ConsoleLogin events without MFA.
  • Delete a log object in a copy and see validation fail.
Lab 3

GuardDuty and Security Hub with a delegated administrator

Detect once for the whole organization and route findings to a human.

# management account
aws guardduty enable-organization-admin-account \
  --admin-account-id 222233334444
aws securityhub enable-organization-admin-account \
  --admin-account-id 222233334444

# delegated admin (security tooling) account
aws guardduty update-organization-configuration \
  --detector-id <id> --auto-enable-organization-members ALL
aws guardduty create-sample-findings --detector-id <id> \
  --finding-types "UnauthorizedAccess:EC2/SSHBruteForce"

# EventBridge pattern for the alert rule
{"source": ["aws.guardduty"], "detail-type": ["GuardDuty Finding"]}

Steps and checks

  • Route the EventBridge rule to an SNS topic with your e-mail.
  • Filter on detail.severity ≥ 7 for paging-level alerts.
  • See the sample finding in Security Hub as well.
  • Disable GuardDuty and Security Hub when done, or let the trials expire knowingly.
Lab 4

Config conformance pack with auto-remediation

Detect a public bucket and fix it without a human.

# managed rule
aws configservice put-config-rule --config-rule '{
  "ConfigRuleName": "s3-bucket-public-read-prohibited",
  "Source": {"Owner": "AWS",
             "SourceIdentifier": "S3_BUCKET_PUBLIC_READ_PROHIBITED"}}'

# attach an SSM Automation remediation
aws configservice put-remediation-configurations \
  --remediation-configurations file://remediation.json
#   TargetId: AWS-DisableS3BucketPublicReadWrite
#   Automatic: true, MaximumAutomaticAttempts: 3
#   Parameters: AutomationAssumeRole, S3BucketName (RESOURCE_ID)

Steps and checks

  • Turn off Block Public Access on a test bucket and add a public-read policy.
  • Watch the rule go NONCOMPLIANT, then the remediation run.
  • Package the rule as a conformance pack and deploy it org-wide from the delegated admin.
  • Check results in the Config aggregator.
Lab 5

ABAC, permission boundaries, and AccessDenied debugging

Let a team create roles safely, then work out exactly why a call fails.

# simulate before you deploy
aws iam simulate-principal-policy \
  --policy-source-arn arn:aws:iam::111122223333:role/dev-app \
  --action-names s3:GetObject \
  --resource-arns arn:aws:s3:::team-a-data/report.csv

# decode an encoded authorization failure message
aws sts decode-authorization-message \
  --encoded-message <message> --query DecodedMessage --output text

# find who can reach a resource from outside the org
aws accessanalyzer list-findings-v2 --analyzer-arn <arn>

Steps and checks

  • Create a boundary policy, and a delegated-admin policy that allows iam:CreateRole only with iam:PermissionsBoundary set to it.
  • Tag roles and buckets with team; write one ABAC policy using aws:PrincipalTag/team = aws:ResourceTag/team.
  • Prove team-a cannot read team-b data and cannot remove its boundary.
Lab 6

KMS customer managed key, grants, and cross-account use

Two accounts: A owns the key, B uses it.

# account A
aws kms create-key --description "lab key"
aws kms create-alias --alias-name alias/lab --target-key-id <key-id>
aws kms enable-key-rotation --key-id <key-id> \
  --rotation-period-in-days 180
aws kms create-grant --key-id <key-id> \
  --grantee-principal arn:aws:iam::444455556666:role/app \
  --operations Decrypt GenerateDataKey

# account B (role must also allow kms:Decrypt on the key ARN)
aws kms encrypt --key-id arn:aws:kms:...:key/<key-id> \
  --plaintext fileb://secret.txt --query CiphertextBlob --output text

Steps and checks

  • Add account B to the key policy instead of a grant; compare both approaches.
  • Note that the alias does not work cross-account: use the key ARN.
  • Add an encryption context and see decrypt fail without it.
  • Schedule deletion with the minimum 7-day window when finished.
Lab 7

CloudFront with OAC and a WAF rate-based rule

Private S3 origin, edge-only access, and a basic flood control.

Build

  • Create a private bucket (Block Public Access on) and a CloudFront distribution with an origin access control.
  • Paste the bucket policy CloudFront generates: it allows cloudfront.amazonaws.com with AWS:SourceArn of the distribution.
  • Create a web ACL with scope CLOUDFRONT (managed in us-east-1).
  • Add AWSManagedRulesCommonRuleSet and a rate-based rule keyed on IP.
  • Associate the web ACL with the distribution and enable WAF logging.

Verify

  • Direct S3 URL returns 403; CloudFront URL works.
  • Run a quick loop of requests and watch the rate rule block (rate windows and limits are configurable).
  • Find the blocked requests in the WAF logs with their rule labels.
  • Tear down: disable and delete the distribution, then the web ACL.
Lab 8

EC2 incident playbook end to end

Treat a test instance as compromised and walk the full sequence.

# 1. protect and preserve
aws ec2 modify-instance-attribute --instance-id i-0abc \
  --disable-api-termination
aws ec2 create-tags --resources i-0abc \
  --tags Key=ir-status,Value=quarantined
aws ec2 create-snapshot --volume-id vol-0abc \
  --description "IR case 42 evidence"

# 2. remove from service
aws autoscaling detach-instances --instance-ids i-0abc \
  --auto-scaling-group-name web --no-should-decrement-desired-capacity

# 3. isolate (SG with no rules; see connection-tracking caveat)
aws ec2 modify-instance-attribute --instance-id i-0abc \
  --groups sg-0isolation

Steps and checks

  • Capture memory before isolation if tooling is pre-installed.
  • Share the snapshot with the forensics account and copy it there.
  • Review the instance role in CloudTrail; revoke its sessions.
  • Write a timeline and one new preventive control.
Lab safety

Cost and cleanup

Security services bill per account, Region, and volume. A forgotten lab can cost more than the exam.

Never enable in a lab

  • Shield Advanced: US$3,000 per month per payer account, with a 1-year commitment.
  • CloudHSM: billed per HSM-hour for as long as the cluster has HSMs.
  • Organization-wide Macie full data discovery jobs on large buckets.

Watch the trials

  • GuardDuty, Security Hub, Macie, and Inspector offer free trials; billing starts automatically after them.
  • Check the usage and cost estimate page in each console.
  • Set an AWS Budgets alert before starting.

Clean up

  • Disable services in every Region you enabled them in.
  • Delete trails, Config recorders, Firewall Manager policies, and NAT or firewall endpoints.
  • Schedule KMS keys for deletion; empty and delete lab buckets.
Glossary

Governance and identity terms

Short anchors; explain each in your own words.

TermShort meaning
SCPCaps permissions of principals in member accounts
RCPCaps permissions on resources in member accounts
Declarative policyEnforces a service configuration baseline
Delegated administratorMember account that runs a service org-wide
Landing zonePre-built multi-account baseline (Control Tower)
Data perimeterTrusted identities × trusted resources × expected networks
TermShort meaning
Permission boundaryMax permissions an identity policy can grant
Session policyInline cap passed when assuming a role
ABACAuthorization by matching tags or attributes
Confused deputyService tricked into acting for the wrong party
Permission setIdentity Center template that becomes a role
Trust policyResource policy on a role: who may assume it
Glossary

Detection, response, and data terms

Short anchors; explain each in your own words.

TermShort meaning
OCSFOpen schema for security events (Security Lake, Security Hub)
ASFFAWS finding format used by Security Hub CSPM
Attack sequenceGuardDuty finding correlating multi-stage activity
Conformance packBundle of Config rules and remediations
Runbook / playbookStep-by-step automated or manual response
Chain of custodyRecord proving evidence was not altered
TermShort meaning
Envelope encryptionData key encrypts data; KMS key encrypts data key
Encryption contextNon-secret key-value pairs bound to ciphertext
GrantDelegated, revocable KMS permission
XKSKMS external key store: keys stay outside AWS
Object LockWORM retention for S3 objects
mTLSTLS in which the client also presents a certificate
Further reading

Primary references

The exam tests current AWS behavior; when a slide and the docs disagree, the docs win.

Exam and architecture

  • SCS-C03 exam guide — docs.aws.amazon.com/aws-certification/latest/security-specialty-03/
  • AWS Security Reference Architecture — docs.aws.amazon.com/prescriptive-guidance/latest/security-reference-architecture/
  • Well-Architected Security Pillar — docs.aws.amazon.com/wellarchitected/latest/security-pillar/
  • AWS Security Incident Response Guide — docs.aws.amazon.com/security-ir/latest/userguide/
  • Data perimeters — aws.amazon.com/identity/data-perimeters-on-aws/

Service references

  • IAM policy evaluation logic — docs.aws.amazon.com/IAM/latest/UserGuide/reference_policies_evaluation-logic.html
  • Organizations policies (SCP, RCP, declarative) — docs.aws.amazon.com/organizations/latest/userguide/
  • KMS developer guide — docs.aws.amazon.com/kms/latest/developerguide/
  • GuardDuty, Security Hub, Inspector, Macie user guides
  • AWS Security Blog — aws.amazon.com/blogs/security/
  • Practice: official question sets on AWS Skill Builder
1 / 1