Question 1 of 75
0% complete
Review your answers
0 of 75 correct
-
Question 1
Correct IncorrectWhich change starts the pipeline only on a release tag with the least ongoing maintenance?
Keep the V1 pipeline and set the source action branch name to the tag that is being released before each run. Correct answer Your answerKeep the V1 pipeline and add a first-stage CodeBuild action that inspects the commit and fails the build when no version tag points at it. Correct answer Your answerConvert the pipeline to the V2 pipeline type and add a trigger on the source action with a push filter that includes git tags matching v*.*.*. Correct answer Your answerKeep the V1 pipeline and create an Amazon EventBridge rule on repository tag events from the connection that calls StartPipelineExecution. Correct answer Your answerExplanation
Only the V2 pipeline type carries trigger configuration, and its push filters accept git tags with wildcard include and exclude patterns, so a filter on v*.*.* starts a run for a release tag and for nothing else. Setting a V1 source action branch field to a tag name does not work — that field names a branch, accepts no wildcards, and would need a pipeline edit for every release. Adding a build action that inspects the commit still starts and bills a full execution for every push and leaves a trail of failed runs that the team has to interpret. Repository tag events from a third-party provider reached through a connection are not delivered to EventBridge, so a rule built on them never fires.
-
Question 2
Correct IncorrectWhich statement correctly describes the recovery point that each path offers?
Both the Multi-AZ standby and the cross-Region read replica are kept current by synchronous replication, so neither path loses committed transactions. Correct answer Your answerThe Multi-AZ standby is maintained by synchronous replication, so an automatic failover loses no committed transactions; promoting the asynchronous cross-Region read replica can lose any transactions that had not yet been shipped, which is a nonzero RPO. Correct answer Your answerBoth paths replicate asynchronously and therefore share the same nonzero RPO; the only difference between them is that the Multi-AZ failover completes faster. Correct answer Your answerPromoting the cross-Region read replica gives the lower RPO, because a replica continuously applies transaction log records while the Multi-AZ standby is rebuilt from the most recent automated snapshot. Correct answer Your answerExplanation
Multi-AZ replication is synchronous — RDS does not acknowledge a commit until the write is durable on the standby as well — so an automatic failover is effectively a zero-RPO event, and the cost is availability time while the endpoint is remapped, not data. A cross-Region read replica ships changes asynchronously, so anything still in flight when the primary is lost is gone once the replica is promoted, making its RPO equal to the replica lag at the moment of failure. Describing both as synchronous misstates the replica, and describing both as asynchronous misstates the standby. The claim that the standby is rebuilt from a snapshot describes neither mechanism: the standby is continuously updated block for block.
-
Question 3
Correct IncorrectWhich approach meets this requirement with the least operational overhead?
Run an hourly AWS Lambda function that calls the AWS Health DescribeEvents API, records the event ARNs it has already processed in an Amazon DynamoDB table, and opens a ticket for anything new. Correct answer Your answerAdd the operations distribution list as the operations alternate contact on the account so that retirement notices reach the whole team instead of one mailbox. Correct answer Your answerCreate an Amazon EventBridge rule on the default event bus in each Region that matches the aws.health source and the scheduledChange event type category, and target an AWS Lambda function that creates the ticket. Correct answer Your answerCreate an Amazon CloudWatch alarm on the StatusCheckFailed_System metric for every instance and send the alarm to an Amazon SNS topic subscribed to the ticket system's intake address. Correct answer Your answerExplanation
AWS Health publishes account-specific events to the default EventBridge bus in the Region where the event occurs, so a rule per Region filtering on the aws.health source and the scheduledChange category captures retirement notices the moment AWS raises them, with no polling code and no missed mail. Polling DescribeEvents works but requires a Business or Enterprise Support plan, a scheduler, and a deduplication table that the team then owns and must operate. Setting an alternate contact only redirects email and still leaves a human to open the ticket. A system status check alarm is reactive rather than predictive: it fires once the host is already impaired, which is precisely the outage the team is trying to avoid.
-
Question 4
Correct IncorrectWhich change gives the fastest reuse of those unchanged layers between consecutive builds with the least configuration?
Enable local caching on the project with the Docker layer cache mode and run the build environment in privileged mode. Correct answer Your answerEnable Amazon S3 caching on the project and list the Docker storage directory under the cache paths in the buildspec. Correct answer Your answerBake the eight unchanging layers into a custom build image, publish it to Amazon ECR, and use it as the project build environment image. Correct answer Your answerMove the project to a larger compute type so the layers are rebuilt on faster vCPUs and more memory. Correct answer Your answerExplanation
The Docker layer cache mode of CodeBuild local caching keeps the layer store on the build host so a following build on that host reuses the eight unchanged layers, and the documented requirement for it is a Linux environment with privileged mode enabled. S3 caching copies declared paths in and out of a bucket between builds, and the Docker storage directory is not a supported cache path — the upload and download of a multi-gigabyte layer store would also erase the saving. Baking the layers into a custom build image does cut the work, but it adds an image to rebuild and re-publish whenever a package changes. A larger compute type shortens the same work rather than skipping it.
-
Question 5
Correct IncorrectWhich approach meets both requirements with the least operational overhead?
Schedule a Lambda function every five minutes to call FilterLogEvents on each log group and index the matching events into the OpenSearch Service domain, writing a copy to Amazon S3. Correct answer Your answerCreate an hourly CloudWatch Logs export task for each log group that writes to Amazon S3, then run an AWS Glue crawler over the bucket so the data can be queried with Amazon Athena. Correct answer Your answerCreate a CloudWatch Logs subscription filter on each log group with an ERROR filter pattern that delivers to an Amazon Data Firehose stream, and configure the stream to deliver to the OpenSearch Service domain and to back up all records to Amazon S3. Correct answer Your answerCreate a CloudWatch Logs metric filter for ERROR on each log group and configure an alarm on the resulting metric to publish to an Amazon SNS topic that the OpenSearch Service domain subscribes to. Correct answer Your answerExplanation
A subscription filter is the only mechanism that streams matching log events out of CloudWatch Logs continuously, and Amazon Data Firehose is a managed destination that can both index into OpenSearch Service and write every record to S3 in one delivery stream, so a single configuration satisfies the search requirement and the archive requirement. Polling FilterLogEvents on a schedule reintroduces latency, paging logic, and checkpoint state that must be maintained. Export tasks are batch jobs with per-account concurrency limits and delivery measured in minutes to hours, which cannot meet a one-minute target. A metric filter only produces a numeric count, it does not carry the log line, and OpenSearch Service cannot subscribe to an SNS topic.
-
Question 6
Correct IncorrectHow should the team identify the instances that are still using IMDSv1 before enforcement?
Review the per-instance MetadataNoToken CloudWatch metric in the AWS/EC2 namespace over a representative window, and switch only the instances whose count stays at zero. Correct answer Your answerEnable VPC flow logs on the subnets and filter for traffic to 169.254.169.254 to see which instances call the metadata service without a token. Correct answer Your answerEnable AWS CloudTrail data events for the EC2 service so that each metadata request is logged with the calling instance ID. Correct answer Your answerUse AWS Systems Manager Run Command to curl the metadata endpoint on every instance and record which instances answer without a token. Correct answer Your answerExplanation
EC2 publishes MetadataNoToken to CloudWatch for each instance, counting metadata requests served over IMDSv1. A sustained zero across a window that covers the application's full workload is the evidence needed to flip HttpTokens to required safely. VPC flow logs never help here because link-local traffic to 169.254.169.254 is not captured by flow logs at all. CloudTrail does not record instance metadata requests: the metadata service is answered locally on the instance and is not an AWS API call, so no data event type exists for it. Running curl through Run Command only proves the endpoint still accepts token-less requests, which every instance does until enforcement, and says nothing about which applications depend on that behavior.
-
Question 7
Correct IncorrectWhich approach should the team adopt to share these values going forward?
Convert the twelve application stacks into nested stacks of the networking stack and pass the IDs down as parameters. Correct answer Your answerPublish each value as an AWS Systems Manager Parameter Store parameter and have the application templates consume it through an AWS::SSM::Parameter::Value<String> parameter type. Correct answer Your answerKeep the exports and add a DependsOn attribute in each application template so CloudFormation orders the updates correctly. Correct answer Your answerCopy the current IDs into a Mappings section in each application template and edit the twelve templates whenever the network changes. Correct answer Your answerExplanation
A cross-stack export is locked for as long as any stack imports it, which is exactly the deadlock described, and the lock is by design. Parameter Store breaks the coupling: the networking stack writes the current IDs as parameters, and each application template declares a parameter of an SSM parameter type that resolves the value at deploy time, so the producer can change without asking permission from the consumers. Nesting the application stacks makes one enormous stack whose every deployment is coupled to the network. DependsOn only orders resources inside a single template and has no effect on export locking. Hardcoding the IDs into Mappings guarantees drift and twelve manual edits.
-
Question 8
Correct IncorrectWhich approach meets the new RPO and RTO?
Convert the cluster to an Aurora global database with a secondary cluster in eu-west-1, serve European reads from that secondary, and promote it to a standalone writer during a Regional event. Correct answer Your answerAdd a second Aurora reader instance in another Availability Zone in us-east-1 and rely on Aurora automatic failover between the writer and that reader. Correct answer Your answerReplace the nightly snapshot copy with an hourly AWS Backup cross-Region copy job and restore the copied snapshot into eu-west-1 when the primary Region is impaired. Correct answer Your answerEnable cross-Region automated backup replication to eu-west-1 and perform a point-in-time restore into a new cluster in that Region when the primary Region is impaired. Correct answer Your answerExplanation
An Aurora global database replicates at the storage layer to the secondary Region with typical lag well under a second, and the secondary cluster is a live, readable cluster that can be promoted in minutes — which is exactly the combination of sub-second RPO, low RTO, and local reads the requirement describes. Adding a reader in a second Availability Zone improves availability inside us-east-1 and does nothing for the loss of the whole Region. An hourly cross-Region backup copy caps the RPO at an hour, an order of magnitude worse than required. Replicated automated backups still require a full restore into a brand-new cluster, which takes far longer than a few minutes for a cluster of any size and leaves Europe with no local reads.
-
Question 9
Correct IncorrectWhich configuration meets these requirements with the least custom code?
Create an Amazon SNS topic with the primary and secondary engineers subscribed by SMS, and set the alarm action to publish to that topic. Correct answer Your answerCreate an AWS Systems Manager Incident Manager response plan with an escalation plan whose first stage engages the primary contact and whose second stage engages the secondary after five minutes, attach a chat channel and an automation runbook to the plan, and set the CloudWatch alarm to start an incident from that response plan. Correct answer Your answerCreate an Amazon SNS topic and subscribe an AWS Lambda function that re-publishes the message every five minutes until an engineer writes an acknowledgement row to an Amazon DynamoDB table. Correct answer Your answerConfigure Amazon Q Developer in chat applications to post the alarm into the on-call Slack channel and rely on the channel members to pick the incident up. Correct answer Your answerExplanation
Incident Manager is the managed service that models contacts, engagement plans, and time-boxed escalation stages, and a response plan can also open a chat channel and attach Systems Manager Automation runbooks while recording a timeline for the postmortem. A CloudWatch alarm can start an incident from that plan directly. An SNS topic has no acknowledgement or escalation semantics, so both engineers are notified at once and nobody is guaranteed to respond. The Lambda re-publishing loop reimplements escalation and acknowledgement as code the team must maintain, and still produces no incident record. Chatbot delivers the alarm into Slack but has no paging, no escalation timer, and no way to detect that the message went unread.
-
Question 10
Correct IncorrectWhich two changes are required for the production role to read the artifact?
Add a statement to the KMS key policy that allows the production account deployment role to call kms:Decrypt and kms:DescribeKey. Correct answer Your answerAdd a bucket policy on the artifact bucket that allows the production account deployment role s3:GetObject and s3:GetObjectVersion. Correct answer Your answerSwitch the artifact bucket to the AWS managed key aws/s3 and grant the production role kms:Decrypt in its own IAM policy. Correct answer Your answerEnable cross-Region replication of the artifact bucket into a bucket owned by the production account. Correct answer Your answerGrant the tooling account pipeline service role s3:PutObject on a new artifact bucket created in the production account. Correct answer Your answerExplanation
Cross-account artifact access needs permission on both the object and the key that encrypts it, and because both resources live in the tooling account each needs a resource policy naming the production role — a bucket policy for the object reads and a KMS key policy statement for the decrypt. Moving to the AWS managed key makes the problem permanent, because the key policy of an AWS managed key cannot be edited to trust another account. Replicating the bucket copies objects but does not change which principal CodePipeline hands to the deploy action, and the replica is not what the action reads. Writing artifacts into a production bucket reverses the flow and leaves the deploy action still reading the tooling bucket.
-
Question 11
Correct IncorrectWhich approach reduces the ongoing cost while keeping the audit data, with the least ongoing effort?
Delete the log groups that contain data older than one year, and repeat the cleanup each quarter. Correct answer Your answerSet a three-day retention policy on every log group and rely on CloudWatch Logs Insights to query anything older when an investigation needs it. Correct answer Your answerRemove the logs:CreateLogStream and logs:PutLogEvents permissions from the Lambda execution roles and ECS task roles that generate the largest volume. Correct answer Your answerSet a 30-day retention policy on every log group, export or subscribe the audit log groups to Amazon S3 where a lifecycle rule moves objects to an archival storage class, and add an automation rule that applies the retention setting to newly created log groups. Correct answer Your answerExplanation
CloudWatch Logs charges for ingestion and then for stored data indefinitely when no retention is set, so the fix is a retention policy on every group plus a cheaper destination for the small subset that genuinely needs seven years — S3 with a lifecycle transition costs a fraction of CloudWatch Logs storage — and an automation rule keeps newly created groups from silently reverting to Never expire. Deleting whole log groups by hand is manual, destroys recent data along with old, and the groups reappear on the next invocation. A blanket three-day retention loses the audit data outright, and Logs Insights can only query events still inside the retention window. Stripping logging permissions removes the troubleshooting signal entirely.
-
Question 12
Correct IncorrectWhich approach produces both answers as continuously updated findings with the least operational overhead?
Use IAM Access Advisor in each account to review service last accessed data, and export the results monthly to an Amazon S3 bucket for the auditors. Correct answer Your answerRun a monthly AWS Lambda function that calls GetAccountAuthorizationDetails in each account, parses every trust policy and resource policy, and writes a report to Amazon S3. Correct answer Your answerCreate one IAM Access Analyzer external access analyzer with the account as the zone of trust in each member account, and query AWS CloudTrail Lake for role usage over 90 days. Correct answer Your answerCreate an IAM Access Analyzer external access analyzer with the organization as the zone of trust and an unused access analyzer with a 90-day tracking period, both from the delegated administrator account. Correct answer Your answerExplanation
IAM Access Analyzer has two analyzer types that map onto the two questions: an external access analyzer, which evaluates resource and trust policies and reports grants to principals outside the chosen zone of trust, and an unused access analyzer, which reports roles, users, and permissions idle beyond a configured tracking period. Creating both from the delegated administrator covers every member account with no per-account work. Access Advisor shows only which services a principal used and never identifies external access. The custom job reimplements automated reasoning and runs only monthly. Choosing the account as the zone of trust would flag routine cross-account access inside the organization as external, burying the real findings.
-
Question 13
Correct IncorrectWhich CodeDeploy deployment configuration matches this requirement exactly?
CodeDeployDefault.LambdaLinear10PercentEvery1Minute Correct answer Your answerCodeDeployDefault.LambdaAllAtOnce Correct answer Your answerCodeDeployDefault.LambdaCanary10Percent5Minutes Correct answer Your answerCodeDeployDefault.LambdaCanary10Percent10Minutes Correct answer Your answerExplanation
A canary configuration shifts a fixed first slice, holds it for a named interval, then moves everything that is left, which is the two-step pattern described; the ten percent slice and the ten-minute bake period name the configuration precisely. The linear configuration instead adds ten percent every minute until the shift completes, so traffic keeps climbing during the window rather than resting at ten percent. The all-at-once configuration moves the alias in a single step and gives the alarm nothing to observe before full exposure. The five-minute canary has the right shape but halves the bake window, which would let the deployment complete before a slow-burning error alarm reaches its threshold.
-
Question 14
Correct IncorrectWhich action restores the data with the shortest recovery time?
Restore the most recent automated snapshot into a new cluster and repoint the application at the new cluster endpoint. Correct answer Your answerBacktrack the existing cluster to a timestamp one minute before the DELETE statement ran. Correct answer Your answerPerform a point-in-time restore to a new Aurora cluster using a target time one minute before the DELETE, then repoint the application. Correct answer Your answerFail the cluster over to one of its Aurora Replicas so that the application reads from a copy that predates the DELETE. Correct answer Your answerExplanation
Backtrack rewinds an Aurora MySQL cluster in place to a point inside the backtrack window, typically in minutes and without creating a new cluster, so the existing endpoints keep working and no application reconfiguration is needed — which makes it the fastest path when the feature was enabled ahead of time, as it was here. Restoring the latest automated snapshot loses every change made since that snapshot and still produces a new cluster with a new endpoint. A point-in-time restore reaches the right moment but provisions an entirely new cluster from backup, which takes far longer and forces a cutover. Failing over to an Aurora Replica changes nothing, because replicas read the same shared storage volume and see the same deleted rows.
-
Question 15
Correct IncorrectWhich two actions should the DevOps engineer take to meet these requirements with the least custom code?
Enable the AWS Config managed rule restricted-ssh in every Region that hosts workloads, so that existing and newly created security groups are evaluated. Correct answer Your answerAttach a remediation action to the AWS Config rule that runs the AWS-DisablePublicAccessForSecurityGroup automation document with an IAM role that AWS Config can assume, and turn on automatic remediation. Correct answer Your answerCreate an Amazon EventBridge rule that matches the AuthorizeSecurityGroupIngress API call in AWS CloudTrail and invokes an AWS Lambda function that revokes the offending rule. Correct answer Your answerAttach a service control policy to the organizational unit that denies the ec2:AuthorizeSecurityGroupIngress action for every principal in the member accounts. Correct answer Your answerEnable Amazon GuardDuty in every Region and subscribe an AWS Lambda function to findings so that open security groups are revoked when they are reported. Correct answer Your answerExplanation
AWS Config evaluates existing resources when a rule is first enabled and again on every configuration change, so the managed restricted-ssh rule covers pre-existing groups as well as new ones, and the evaluation history is the audit record. Attaching the automation document as a remediation action with automatic remediation turned on closes the finding within minutes, with no function to maintain. The CloudTrail-driven EventBridge rule reacts only to new API calls, so it would never touch groups that were already open. A policy denying the ingress action blocks legitimate rule changes too. GuardDuty reports suspicious behavior, not configuration drift, and raises no finding for an open security group.
-
Question 16
Correct IncorrectWhich control enforces this at update time?
Attach a stack policy that denies Update:Replace and Update:Delete on the ProdDatabase logical resource ID and allows Update:* on every other resource. Correct answer Your answerAdd the DeletionPolicy attribute with a value of Retain to the ProdDatabase resource in the template. Correct answer Your answerAttach an IAM policy to the engineering role that denies the cloudformation:UpdateStack action on the production stack. Correct answer Your answerEnable termination protection on the production stack. Correct answer Your answerExplanation
A stack policy is evaluated by CloudFormation during an update and is the only one of these controls that can allow most updates while refusing specific update actions on a named logical resource, which is precisely the requirement. DeletionPolicy with Retain does not stop a replacement — it only governs what happens to the physical resource when CloudFormation removes it, so the database would still be replaced and the old instance simply left behind. Denying UpdateStack blocks every change to the stack, including the routine ones the team still needs. Termination protection refuses stack deletion and says nothing about an update that replaces a resource inside a stack that continues to exist.
-
Question 17
Correct IncorrectWhich change reduces the paging noise with the least operational overhead?
Create a composite alarm whose rule expression combines the meaningful child alarms, move the Amazon SNS paging action onto the composite alarm, and remove the notification actions from the child alarms. Correct answer Your answerRaise the datapoints-to-alarm and evaluation-periods settings on every existing alarm to 15 out of 15 so that transient conditions never page. Correct answer Your answerReplace the 300 metric alarms with a single anomaly detection alarm on the service's CPU utilization metric. Correct answer Your answerSubscribe an AWS Lambda function to every Amazon SNS topic and have it suppress duplicate notifications inside a rolling ten-minute window before forwarding to the paging provider. Correct answer Your answerExplanation
A composite alarm evaluates a rule expression over other alarms, so the child alarms keep evaluating and stay visible on dashboards while only the composite carries the paging action — exactly one notification per correlated incident, configured declaratively with no code. Pushing every alarm to 15 of 15 datapoints does not deduplicate anything; it simply delays all 40 pages by a quarter of an hour and hides short real incidents. Collapsing 300 alarms into one anomaly detection alarm on CPU discards nearly all of the service's coverage and would miss error-rate and latency regressions entirely. A deduplicating Lambda in front of the paging provider is custom code to write, test, and maintain for a problem the service already solves.
-
Question 18
Correct IncorrectWhich configuration meets these requirements with the least ongoing administration?
Designate a security account as the AWS Security Hub delegated administrator, turn on automatic enablement for new organization accounts and for the security standard, and configure a finding aggregation Region with the other five Regions linked to it. Correct answer Your answerEnable Security Hub in every account and Region, then send invitations from the security account to each member account and accept them individually. Correct answer Your answerEnable Security Hub only in the aggregation Region of each account, and rely on the fact that findings from other Regions are forwarded to that Region automatically. Correct answer Your answerCreate an AWS Config aggregator in the security account that collects configuration items from every account and Region, and read the standard's controls from the aggregator. Correct answer Your answerExplanation
Security Hub integrates with Organizations: the management account designates a delegated administrator, and that account can auto-enable Security Hub and the chosen standards in existing and future member accounts. Cross-Region aggregation is separate and explicit, so the aggregation Region must be configured with its linked Regions before findings appear in one place. Manual invitations produce the same membership but must be repeated for every new account and Region, the toil being removed. Findings are never forwarded between Regions on their own, so enabling only the aggregation Region leaves five Regions unassessed. A Config aggregator collects configuration items and Config rule compliance, not Security Hub standard findings.
-
Question 19
Correct IncorrectWhich approach satisfies these requirements?
Rotate the access key pair nightly with a scheduled AWS Lambda function that writes the new key into the GitHub repository secret. Correct answer Your answerCreate an IAM OIDC identity provider for token.actions.githubusercontent.com, create a role whose trust policy conditions on the repo and ref values in the token sub claim, and have the workflow exchange its OIDC token for temporary credentials. Correct answer Your answerStore the access key pair in AWS Secrets Manager and have the workflow retrieve it at the start of every job. Correct answer Your answerMove the workflows to a self-hosted runner on an Amazon EC2 instance that carries an instance profile with the deployment permissions. Correct answer Your answerExplanation
GitHub Actions can present a signed OIDC token that describes the repository, the branch and the workflow; registering GitHub as an IAM identity provider and conditioning a role trust policy on the sub claim yields temporary credentials scoped to exactly one repository and branch, with no stored secret at all. Nightly rotation still leaves a valid long-lived key sitting in the repository for up to a day and adds a function to run. Storing the key in Secrets Manager only moves it, and the workflow still needs a credential to read the secret. A self-hosted runner does remove the key but introduces an EC2 fleet to patch and scale, which the team ruled out.
-
Question 20
Correct IncorrectWhich change resolves the connection exhaustion with the least application change?
Edit the DB parameter group to raise max_connections to 20,000 so that every concurrent invocation can hold its own connection. Correct answer Your answerConvert the instance to a Multi-AZ deployment so that the standby absorbs part of the connection load. Correct answer Your answerProvision Amazon RDS Proxy in front of the instance and change the function's connection string to the proxy endpoint, so that database connections are pooled and reused across invocations. Correct answer Your answerSet a reserved concurrency of 50 on the Lambda function so that no more than 50 connections can ever be opened. Correct answer Your answerExplanation
RDS Proxy sits between the function and the database and multiplexes many short-lived client connections onto a small pool of persistent database connections, which absorbs exactly this kind of burst; the only application change is the hostname in the connection string. Raising max_connections far beyond what the instance class can support trades a connection error for memory pressure and instability, because each MySQL connection consumes server memory. Multi-AZ maintains a standby that accepts no client connections at all, so it adds availability and no connection capacity. Reserved concurrency would cap connections but does so by throttling the function, which drops the legitimate customer requests the scenario says must be served.
-
Question 21
Correct IncorrectHow should the DevOps engineer reprocess the events from the outage window?
Start a replay from the archive for the start and end times of the outage, targeting the ticketing-prod bus and the rule that routes to the function. Correct answer Your answerConfigure a dead-letter queue on the rule target, then redrive the queue so that the failed deliveries from the outage window are sent to the function again. Correct answer Your answerIncrease the rule target's maximum event age and maximum retry attempts, so that EventBridge delivers the events from the outage window once the function is healthy. Correct answer Your answerQuery AWS CloudTrail for the PutEvents calls made during the outage window and replay the event payloads recorded in the trail. Correct answer Your answerExplanation
An EventBridge archive captures events that match its filter from the moment the archive exists, and a replay re-sends them to the same bus for chosen rules over a chosen time window, which is exactly the recovery path here because the archive predates the outage. Adding a dead-letter queue now changes nothing retroactively: a DLQ only captures deliveries that fail after the queue exists, and there is nothing in it to redrive. The retry settings are also forward-looking and are capped at 24 hours of event age, so raising them cannot resurrect events whose delivery attempts already ended. CloudTrail does not record the event payloads that flow through an event bus, so there is nothing in the trail to rebuild the events from.
-
Question 22
Correct IncorrectWhich Systems Manager capability meets this with the least operational overhead?
Add the agent installation and configuration commands to the launch template user data of every Auto Scaling group. Correct answer Your answerCreate an Amazon EventBridge scheduled rule that runs a Systems Manager Run Command document against the fleet once a week. Correct answer Your answerCreate a State Manager association that targets instances by the Role=web tag, runs the agent install and configuration documents, and repeats on a rate schedule. Correct answer Your answerCreate an AWS Config custom rule that evaluates each instance and writes noncompliant instance IDs to an Amazon SNS topic for an engineer to fix. Correct answer Your answerExplanation
A State Manager association is the Systems Manager feature built for keeping instances in a defined state: it targets by tag so newly launched instances are picked up without any registration step, it reapplies on a schedule, and it records association compliance per instance. User data runs once at launch and cannot repair an instance that drifts hours later. A scheduled Run Command invocation reapplies the state but has no association compliance record and no automatic handling of instances that appear between runs. A custom Config rule detects the problem and then hands it to a human, which is neither continuous enforcement nor low overhead.
-
Question 23
Correct IncorrectWhich alarm configuration detects the real drop while ending the nightly pages, with the least ongoing tuning?
Create 24 separate alarms, one per hour of the day, each with a static threshold derived from the previous month's traffic for that hour. Correct answer Your answerCreate a CloudWatch anomaly detection model on OrdersAccepted and configure the alarm to fire when the metric falls below the lower edge of the anomaly detection band. Correct answer Your answerChange the alarm's statistic from Average to Sum and raise the period to 24 hours so that overnight volume no longer breaches the threshold. Correct answer Your answerCreate a composite alarm that combines the existing threshold alarm with a second alarm so that it only fires during business hours. Correct answer Your answerExplanation
Anomaly detection trains a model on up to two weeks of history and learns the daily and weekly seasonality, producing a band that is wide overnight and tight at midday; alarming on LessThanLowerThreshold against that band therefore ignores the expected nightly trough and catches a 30 percent midday shortfall without anyone maintaining numbers. Twenty-four per-hour alarms encode the seasonality by hand and have to be re-derived every time traffic grows. Summing over a 24-hour period smooths the trough away but also smooths away the outage — a 30 percent dip for a few hours barely moves a daily total. A composite alarm evaluates other alarms and has no notion of time of day, so it cannot express a business-hours window on its own.
-
Question 24
Correct IncorrectWhich two changes should the engineer make to meet these requirements?
Add the password as a plaintext environment variable on the CodeBuild project and delete the value from buildspec.yml. Correct answer Your answerStore the credential in AWS Secrets Manager and enable rotation on a 30-day schedule using the managed rotation function for the database engine, with network access from the rotation function to the database. Correct answer Your answerStore the credential in AWS Systems Manager Parameter Store as a SecureString and reference it from the buildspec with the PARAMETER_STORE environment variable type. Correct answer Your answerEncrypt the password with AWS KMS, commit the ciphertext in buildspec.yml, and decrypt it in the pre_build phase with the build role. Correct answer Your answerReference the secret from the CodeBuild project using the SECRETS_MANAGER environment variable type and grant the build service role secretsmanager:GetSecretValue on that secret. Correct answer Your answerExplanation
Secrets Manager is the only option here that both stores the credential and rotates it on a schedule, and CodeBuild's SECRETS_MANAGER environment variable type resolves the secret at build time so the value never appears in the project definition, the repository, or the build log. A plaintext project environment variable is visible to anyone who can read the project and is echoed in logs, and it still never rotates. Parameter Store SecureString solves the storage problem but has no rotation of its own, so the 30-day requirement would go unmet. Committing KMS ciphertext keeps a long-lived secret in the repository, where anyone with decrypt permission and the repository can recover it, and the value is still never rotated.
-
Question 25
Correct IncorrectWhich two changes would let the build reach the source and registry endpoints?
Add a route to an internet gateway in the route table associated with the private subnets. Correct answer Your answerTurn on the option that assigns a public IP address to the build environment so the build host can reach the internet directly. Correct answer Your answerAdd a NAT gateway in a public subnet and route outbound traffic from the build subnets through it. Correct answer Your answerAdd an inbound rule to the build security group that allows TCP 443 from 0.0.0.0/0. Correct answer Your answerCreate interface VPC endpoints for the ECR API and ECR Docker registry services and a gateway VPC endpoint for Amazon S3 in the build VPC. Correct answer Your answerExplanation
A CodeBuild build inside a VPC runs behind an elastic network interface that never receives a public IP address, so outbound access has to come from either a NAT gateway or VPC endpoints. A NAT gateway in a public subnet gives the build general outbound reachability, and interface endpoints for the two ECR services plus the S3 gateway endpoint carry the image layer and artifact traffic privately. Routing the private subnets straight at an internet gateway does not help, because an interface with no public address cannot use it. There is no public IP assignment option for VPC-configured builds. Security groups are stateful, so the replies to outbound requests are already allowed and an inbound rule changes nothing.
-
Question 26
Correct IncorrectWhich control satisfies the auditor's immutability requirement?
Write an IAM policy that denies backup:DeleteRecoveryPoint and attach it to every operator role that touches the backup account. Correct answer Your answerEnable Amazon S3 Object Lock in compliance mode on the bucket where the AWS Backup recovery points are stored. Correct answer Your answerAttach a service control policy to the organizational unit that denies backup:DeleteRecoveryPoint for all principals in the member accounts. Correct answer Your answerApply AWS Backup Vault Lock in compliance mode to the backup vault with a seven-year minimum retention, and let the cooling-off period elapse so the lock becomes permanent. Correct answer Your answerExplanation
Vault Lock in compliance mode is the only one of these that survives an administrator: once the cooling-off period expires, the lock and its retention floor cannot be changed or removed by any principal, including the account root user and AWS Support, which is precisely the evidence an auditor asks for. An IAM deny on operator roles is edited away by anyone holding administrative permissions. A service control policy is stronger but is still mutable by the organization's management account, and it does not apply to that account's own principals. S3 Object Lock is a real immutability control, but AWS Backup recovery points live in service-managed vaults rather than in a customer bucket, so there is no bucket on which to set it.
-
Question 27
Correct IncorrectWhich configuration meets these requirements without adding code to the function?
Configure a dead-letter queue on the Lambda function so that failed event payloads are written to an Amazon SQS queue. Correct answer Your answerConfigure a dead-letter queue on the EventBridge rule target so that events the rule could not process are written to an Amazon SQS queue. Correct answer Your answerWrap the handler body in a try/catch block that writes the event and the exception to an Amazon SQS queue on failure and to a second queue on success. Correct answer Your answerConfigure Lambda asynchronous invocation destinations with an on-failure destination and an on-success destination, each pointing at an Amazon SQS queue. Correct answer Your answerExplanation
Lambda asynchronous invocation destinations cover both halves of the requirement: an on-failure destination receives an invocation record for events that exhaust their retries, and an on-success destination receives one for events that complete, each record carrying the request context and the response or error payload. A Lambda dead-letter queue is the older mechanism and carries only the event payload, with no error detail and no success path. A dead-letter queue on the EventBridge rule target captures only events EventBridge failed to deliver, which is a different failure from a function that was invoked and then threw. The try/catch approach is code the team maintains and cannot capture timeouts or out-of-memory terminations.
-
Question 28
Correct IncorrectWhich combination of resource attributes should be set on the cluster?
DeletionPolicy set to Snapshot only. Correct answer Your answerUpdateReplacePolicy set to Retain only. Correct answer Your answerDeletionPolicy set to Retain and UpdateReplacePolicy set to Retain. Correct answer Your answerDeletionPolicy set to Snapshot and UpdateReplacePolicy set to Snapshot. Correct answer Your answerExplanation
CloudFormation treats removal on stack deletion and removal caused by a replacing update as two separate events governed by two separate attributes, and both accept Snapshot for a resource type that supports snapshots, such as an Aurora cluster. Setting both to Snapshot produces a restorable copy in each case and lets CloudFormation delete the old cluster afterward, so nothing keeps billing. DeletionPolicy alone leaves the replacement path uncovered, and the replaced cluster would be deleted with no snapshot. UpdateReplacePolicy with Retain covers only the update and leaves the old cluster running. Retain on both preserves the data but abandons two live clusters that nobody is tracking.
-
Question 29
Correct IncorrectWhich approach preserves the per-tenant detail with the least request-path overhead and without hitting PutMetricData throttling?
Write CloudWatch embedded metric format JSON to the application's log stream, declaring the metric values and the dimension sets in the document, and let CloudWatch extract the metrics asynchronously while the full-cardinality records stay queryable in CloudWatch Logs Insights. Correct answer Your answerBuffer metrics in memory and send them in batched PutMetricData calls of up to 1,000 metric data items every 60 seconds. Correct answer Your answerCreate one CloudWatch Logs metric filter per tenant on the application's log group so that each tenant gets its own latency metric. Correct answer Your answerPublish a single latency metric with no tenant dimension and derive per-tenant numbers on demand from CloudWatch Logs Insights queries over the raw logs. Correct answer Your answerExplanation
Embedded metric format lets the application emit one structured log line that carries both the metric values and the high-cardinality context; CloudWatch parses the declared dimension sets into metrics out of band, so the request path only writes a log line and never calls the CloudWatch API, which removes both the added latency and the throttling. Batching PutMetricData reduces call volume but still puts an API call, its retries, and its failure modes on the critical path. Per-tenant metric filters collapse immediately against the metric-filter-per-log-group quota, and 4,000 of them would be unmanageable in any case. Dropping the tenant dimension keeps the raw data but gives up alarmable, chartable per-tenant metrics.
-
Question 30
Correct IncorrectWhich key configuration meets these requirements?
Create an independent customer managed key in each Region and give both keys the same alias, so the SDK resolves the local key by alias. Correct answer Your answerCreate a multi-Region primary key in us-east-1 and a replica key in eu-west-1, and let each application use the key in its own Region. Correct answer Your answerUse the AWS managed key for DynamoDB in each Region, because AWS managed keys are shared across the Regions of an account. Correct answer Your answerCreate a customer managed key in us-east-1, export its key material, and import the same material into a second key in eu-west-1. Correct answer Your answerExplanation
Multi-Region keys exist for this case: a primary and its replicas share key ID and key material, so ciphertext produced under one can be decrypted by another without a cross-Region call, while each replica keeps its own editable key policy. Two independent keys have different key material and different key IDs regardless of their aliases, so a decrypt attempt in the other Region fails. AWS managed keys are per-Region and per-service, cannot be made interoperable, and give the security team no policy control. KMS never allows the key material of a KMS-generated key to be exported, and imported material placed in two keys still produces two distinct key ARNs, so ciphertext bound to one cannot be decrypted by the other.
-
Question 31
Correct IncorrectHow should the actions be configured?
Give both deploy actions runOrder 1 and give the smoke test action runOrder 2, all within the Deploy stage. Correct answer Your answerPlace each deploy in its own stage and the smoke test in a third stage, so the stages run in sequence. Correct answer Your answerGive the eu-west-1 deploy runOrder 1, the us-east-1 deploy runOrder 2, and the smoke test runOrder 3. Correct answer Your answerCreate one pipeline per Region on the same source, and schedule the smoke test to run ten minutes after the pipelines start. Correct answer Your answerExplanation
Actions in the same stage that share a runOrder value run in parallel, and CodePipeline does not begin a higher runOrder until every action at the lower value has succeeded, so one stage with the deploys at runOrder 1 and the test at runOrder 2 gives both the concurrency and the barrier the team asked for. Splitting the deploys into separate stages serializes them and roughly doubles the stage time for no benefit. Giving the deploys different runOrder values inside one stage serializes them just as thoroughly. Two pipelines plus a timed test removes the dependency guarantee entirely — a slow deploy would let the smoke test run against a half-updated fleet.
-
Question 32
Correct IncorrectWhich two changes together let Route 53 shift traffic automatically and shorten the time clients take to follow it? (Select TWO.)
Raise the TTL on both records to 86,400 seconds so that resolvers query Route 53 less often during an incident. Correct answer Your answerAssociate a Route 53 health check with the standby record only, so that Route 53 learns when the us-west-2 stack is ready to receive traffic. Correct answer Your answerReplace the two independent records with a failover record set — one primary and one secondary — and associate a Route 53 health check with the primary record. Correct answer Your answerReplace the public hosted zone with a private hosted zone so that resolver caching no longer applies to the record. Correct answer Your answerLower the TTL on the records to 60 seconds so that resolver caches expire quickly once Route 53 begins returning the standby answer. Correct answer Your answerExplanation
Failover routing is what makes the switch automatic: Route 53 returns the primary answer while the health check attached to the primary record is healthy and returns the secondary answer once it is not, with no human editing records. The TTL is what decides how long resolvers keep serving the old answer after that switch, so a 3,600-second TTL is the direct cause of the 40-minute tail and lowering it to 60 seconds is the other half of the fix. Raising the TTL makes the tail dramatically worse. A health check on the secondary record alone gives Route 53 nothing to evaluate for the failover decision, which is driven by the primary. A private hosted zone only answers inside associated VPCs and would take the public name offline.
-
Question 33
Correct IncorrectWhich change prevents duplicate rows while still allowing recovery from transient failures?
Set the function's maximum retry attempts for asynchronous invocation to 0 so that a failed invocation is never repeated. Correct answer Your answerIncrease the function timeout and the table's provisioned write capacity so that invocations no longer fail during a throttling episode. Correct answer Your answerDerive a deterministic item key from the S3 bucket, object key, and version ID, and write with a condition expression that the item does not already exist. Correct answer Your answerSet the function's reserved concurrency to 1 so that only one invocation processes objects at a time. Correct answer Your answerExplanation
Asynchronous invocation is at-least-once by design, so the fix belongs in the function's own write path: a key derived deterministically from the object's identity, combined with a condition that the item does not exist, makes a repeated invocation a no-op instead of a second row. Setting retries to 0 removes duplicates by removing the recovery the team still wants, so a single throttled write would silently lose the object. Raising the timeout and write capacity reduces how often retries happen but does nothing about the ones that still occur. Reserved concurrency of 1 only serializes invocations, and a retried invocation running alone writes the duplicate just as readily.
-
Question 34
Correct IncorrectWhich service configuration meets these requirements with the least custom tooling?
Copy approved tarballs into an Amazon S3 bucket and set the npm registry configuration in the buildspec to the bucket website endpoint. Correct answer Your answerCreate an AWS CodeArtifact domain and repository with an upstream repository that has an external connection to public npm, and point the build npm configuration at the CodeArtifact endpoint. Correct answer Your answerPush every dependency as an image layer to a private Amazon ECR repository and pull it during the install phase. Correct answer Your answerCommit the resolved node_modules directory into the application repository so builds install nothing at all. Correct answer Your answerExplanation
CodeArtifact is the managed package repository for exactly this shape: builds authenticate to one endpoint, an upstream external connection fetches a public package the first time it is requested, and the package is then retained in the domain so later builds resolve it internally and reproducibly, while internal libraries are published to the same repository. An S3 bucket does not implement the npm registry protocol, so an npm client cannot resolve metadata or versions against it. ECR stores container images and OCI artifacts, not npm packages an install step can resolve. Committing node_modules bloats the repository, breaks native modules across platforms, and gives no provenance record at all.
-
Question 35
Correct IncorrectWhich configuration gives the team near-complete trace coverage of the checkout path at an acceptable cost?
Raise the fixed rate on the default sampling rule to 100 percent so that no request goes untraced. Correct answer Your answerEnable X-Ray active tracing on the Application Load Balancer so that the load balancer samples every request before it reaches the services. Correct answer Your answerCreate a CloudWatch Logs metric filter that counts checkout errors and add the resulting metric to the X-Ray service map. Correct answer Your answerCreate a custom X-Ray sampling rule with a higher priority than the default rule that matches the checkout service name and the /checkout URL path, with a reservoir of 50 traces per second and a fixed rate of 100 percent, leaving the default rule to handle everything else. Correct answer Your answerExplanation
X-Ray sampling rules are evaluated in priority order and can match on service name, HTTP method, URL path, and host, so a high-priority rule scoped to the checkout path with a generous reservoir and a full fixed rate traces essentially every checkout request while all other traffic continues to fall through to the default rule — targeted coverage without a platform-wide cost increase. Setting the default rule to 100 percent traces all 9,000 requests per second, which is the expense the scenario rules out. An Application Load Balancer does not sample traces; it only injects or forwards a trace header. A metric filter produces a count from log data and cannot add trace segments or nodes to the service map.
-
Question 36
Correct IncorrectWhich configuration meets these requirements?
Create a gateway VPC endpoint for Amazon S3, add an endpoint policy that allows access only to the organization's bucket ARNs, and route S3 traffic in the private subnets' route tables through the endpoint. Correct answer Your answerAttach a security group to the instances whose egress rules allow traffic only to the com.amazonaws.region.s3 managed prefix list. Correct answer Your answerAdd a bucket policy to each of the company's buckets that denies requests unless aws:SourceVpce matches the VPC's endpoint ID. Correct answer Your answerReplace the NAT gateway routes with network ACL rules that permit outbound traffic only to the published Amazon S3 IP address ranges for the Region. Correct answer Your answerExplanation
A gateway endpoint keeps S3 traffic on the AWS network instead of the NAT path, and its endpoint policy decides which buckets that traffic may address, so scoping it to the organization's bucket ARNs blocks exfiltration to an attacker-owned bucket. A security group referencing the S3 prefix list restores private connectivity only alongside an endpoint and cannot distinguish one bucket from another, because every bucket shares the same addresses. A bucket policy with a source endpoint condition protects the company's own buckets from outside callers but says nothing about what the instances may reach, the exfiltration path in question. Network ACL rules built on published IP ranges are brittle and again cannot express bucket identity.
-
Question 37
Correct IncorrectWhich two additions to the Auto Scaling group resource achieve this?
Set MinInstancesInService equal to the desired capacity so that no instance is ever taken out of service during the update. Correct answer Your answerAdd an UpdatePolicy with AutoScalingRollingUpdate specifying MaxBatchSize of 2 and MinInstancesInService of 10. Correct answer Your answerIn the same AutoScalingRollingUpdate policy, set WaitOnResourceSignals to true with a PauseTime of PT15M and have the instance bootstrap call cfn-signal on success. Correct answer Your answerAdd a CreationPolicy with a ResourceSignal count of 12 and a timeout of fifteen minutes. Correct answer Your answerAttach a stack policy that denies Update:Modify on the Auto Scaling group logical resource. Correct answer Your answerExplanation
AutoScalingRollingUpdate controls the shape of the rolling replacement, and the batch size of two with ten instances kept in service is the direct expression of the capacity requirement. Turning on WaitOnResourceSignals makes CloudFormation hold each batch until the new instances signal success within the pause time, and a batch that times out fails the update and rolls it back, which is the safety net the team is missing. Setting MinInstancesInService to the full desired capacity is rejected, because it must be lower than the group maximum size for any instance to be replaced. A CreationPolicy applies only when the group is first created and is ignored during updates. A stack policy denial blocks the update rather than making it safe.
-
Question 38
Correct IncorrectWhich change lets in-flight work finish and logs ship before an instance is terminated, with the least change to the worker application?
Add an EC2_INSTANCE_TERMINATING lifecycle hook to the Auto Scaling group so the instance pauses in Terminating:Wait, and have an Amazon EventBridge rule invoke automation that stops the worker from taking new jobs, uploads the logs, and then calls CompleteLifecycleAction. Correct answer Your answerIncrease the deregistration delay on the target group to 3,600 seconds so that the Auto Scaling group waits before terminating an instance. Correct answer Your answerEnable EC2 termination protection on the worker instances so that a scale-in event cannot terminate them. Correct answer Your answerSet the Auto Scaling group's default cooldown to 900 seconds so that scaling activities are spaced far enough apart for jobs to complete. Correct answer Your answerExplanation
A termination lifecycle hook is the supported way to insert custom work between the scale-in decision and the actual termination: the instance sits in Terminating:Wait for the heartbeat timeout, an EventBridge rule drives the drain-and-upload automation, and CompleteLifecycleAction releases the instance as soon as the work is done. Deregistration delay only governs how long a load balancer keeps draining existing connections, and these workers pull from a queue rather than receiving load balancer traffic, so nothing is deregistered. Termination protection does not apply to Auto Scaling scale-in. Cooldown controls how soon the next scaling activity may start, not what happens to an instance already being terminated.
-
Question 39
Correct IncorrectWhich approach meets these requirements with the least operational overhead?
Subscribe an AWS Lambda function to the alarm's Amazon SNS topic and have it format the message and post it to a Slack incoming webhook. Correct answer Your answerAdd the Slack channel's email address as an email subscription on the alarm's Amazon SNS topic. Correct answer Your answerCreate an Amazon EventBridge rule for the alarm state change with an API destination that calls the Slack API using a connection holding the bot token. Correct answer Your answerConfigure Amazon Q Developer in chat applications (formerly AWS Chatbot) with the Slack workspace and channel, subscribe the channel configuration to the alarm's Amazon SNS topic, and attach a channel IAM role with a read-only guardrail policy. Correct answer Your answerExplanation
Amazon Q Developer in chat applications (formerly AWS Chatbot) is the managed integration for this: it renders CloudWatch alarm notifications from an SNS topic into a formatted Slack message with links, and its channel IAM role plus channel guardrail policies bound which commands members may run from the channel, which is how read-only diagnostics are made safe. The Lambda and webhook approach delivers the notification but is code the team maintains, and it offers no way to run commands back into the account. An email subscription pointed at a channel address loses the formatting and the links and again supports no commands. An EventBridge API destination calling Slack directly means owning the bot token, the connection, and the message payloads, with the same missing command path.
-
Question 40
Correct IncorrectWhich change to the CodeBuild project produces this?
Copy the XML files to an Amazon S3 bucket at the end of the build and query them with Amazon Athena. Correct answer Your answerPublish a custom Amazon CloudWatch metric for the pass count and the fail count from a script in the post_build phase. Correct answer Your answerAdd a reports section to the buildspec that names a report group, lists the JUnit XML files under file paths, and sets the file format to JUNITXML. Correct answer Your answerParse the XML in the post_build phase and exit with a nonzero status code when any test has failed. Correct answer Your answerExplanation
A reports section in the buildspec tells CodeBuild to ingest the named result files into a report group after the build, and the console then shows per-test outcomes, durations and the pass-rate trend for the group across builds — no extra service and no code. Writing the XML to S3 and querying it with Athena reproduces that view by hand, complete with a table, a schema and a query to maintain. A pair of CloudWatch metrics gives a trend line but throws away every individual test name and failure message. Failing the build on a nonzero exit code is worth doing anyway, but it reports only that something broke, not which test or how the rate is moving.
-
Question 41
Correct IncorrectWhich approach detects the failure reliably during periods of no customer traffic?
Create a CloudWatch metric alarm on the load balancer's HTTPCode_Target_5XX_Count metric with a threshold of one or more over a five-minute period. Correct answer Your answerCreate an Amazon CloudWatch Synthetics canary that calls /v1/settlement every minute, asserts the status code and a field in the response body, and alarm on the canary's SuccessPercent metric. Correct answer Your answerEnable Amazon CloudWatch RUM on the partner web portal so that failures on the settlement path are reported from real sessions. Correct answer Your answerChange the load balancer target group health check path from /health to /v1/settlement so the load balancer exercises the real endpoint. Correct answer Your answerExplanation
A Synthetics canary generates its own traffic on a schedule and can assert far more than a status code, so it turns an unused endpoint into a continuously measured one and produces a SuccessPercent metric that alarms within a couple of intervals regardless of customer activity. An alarm on 5XX counts is defeated by exactly the condition described: with no requests there are no datapoints, so the alarm sits in INSUFFICIENT_DATA and never fires. CloudWatch RUM instruments real browser sessions and is therefore just as blind during a quiet weekend. Repointing the target group health check at the settlement path would mark otherwise healthy targets as unhealthy the moment that code path broke, turning one broken endpoint into a full outage.
-
Question 42
Correct IncorrectWhich change to the trail produces the required record?
Rely on the existing management events in the organization trail, because S3 object API calls and Lambda invocations are management events. Correct answer Your answerEnable Amazon S3 server access logging on the bucket and Amazon CloudWatch Logs on the two functions, and hand the auditor those logs. Correct answer Your answerAdd advanced event selectors for data events that match the AWS::S3::Object resource type where the ARN starts with the patient-exports bucket ARN, and the AWS::Lambda::Function resource type where the ARN equals each function ARN. Correct answer Your answerTurn on AWS CloudTrail Insights on the trail so that unusual object access and invocation patterns are recorded alongside the management events. Correct answer Your answerExplanation
Object-level S3 calls and Lambda Invoke calls are data events, which CloudTrail does not log by default and bills separately, so they must be requested explicitly. Advanced event selectors narrow data events by resource ARN, which keeps the cost to one bucket and two functions instead of the whole account. Management events never include GetObject, PutObject, or Invoke, so the existing trail cannot answer the auditor. S3 server access logs are best-effort with no integrity guarantee, and function logs show what the code printed rather than who called it. CloudTrail Insights analyzes call-rate anomalies on top of events already being logged and records no per-object history of its own.
-
Question 43
Correct IncorrectWhich template construct meets these requirements?
Declare a template parameter with NoEcho set to true and have the deployment script read the secret and pass it in at deploy time. Correct answer Your answerAdd Fn::ImportValue to read the password from an output exported by a separate secrets stack. Correct answer Your answerUse the dynamic reference {{resolve:ssm:/prod/db/password:1}} against a SecureString parameter in Parameter Store. Correct answer Your answerUse the dynamic reference {{resolve:secretsmanager:prod/db/credentials:SecretString:password}} directly in the master password property. Correct answer Your answerExplanation
The Secrets Manager dynamic reference is resolved by CloudFormation when the resource is created or updated, and the resolved value is never stored in the template, in the parameter list or in the change set, which is exactly the set of exposures the security requirement names. A NoEcho parameter hides the value in the console but the deployment tooling still handles the plaintext and passes it over the API, so it is present in the caller command history. Stack exports are plaintext by design and are readable by anything in the account, so exporting a password is the worst option here. The plain ssm dynamic reference does not support SecureString parameters, so that reference fails rather than decrypting anything.
-
Question 44
Correct IncorrectWhich change lets the group absorb a three-minute spike while keeping steady-state cost low?
Replace target tracking with step scaling using larger step adjustments so that more instances are added per alarm breach. Correct answer Your answerRaise the Auto Scaling group's minimum capacity to the observed peak so that enough instances are always running. Correct answer Your answerConfigure an Auto Scaling warm pool holding pre-initialized instances in the Stopped state, with an EC2_INSTANCE_LAUNCHING lifecycle hook that completes the domain join and cache population before an instance enters the pool. Correct answer Your answerEnable predictive scaling on the group so that capacity is provisioned ahead of each spike. Correct answer Your answerExplanation
A warm pool keeps instances that have already booted, joined the domain, and warmed their cache in a stopped state, so a scale-out only has to start them — seconds to a couple of minutes instead of eleven — and stopped instances incur storage cost rather than full instance cost, which is what keeps the steady-state bill down. Larger step adjustments change how many instances are requested, not how long each one takes to become useful, so the eleven-minute initialization still dominates. Raising the minimum to peak solves the latency at exactly the cost the business rejected. Predictive scaling forecasts from historical cyclical patterns and has nothing to learn from spikes driven by unpredictable news events.
-
Question 45
Correct IncorrectWhich two actions should the team take to meet these requirements?
Create an Amazon CloudWatch alarm on the function's Throttles metric with a threshold of one, so that the team is paged when throttling begins. Correct answer Your answerEnable the AWS Trusted Advisor service limits checks and review the dashboard weekly in the run-up to the promotion. Correct answer Your answerUse Service Quotas to create a CloudWatch alarm on the concurrent-executions quota that fires when utilization reaches 80 percent of the applied quota value. Correct answer Your answerSubmit a quota increase request through Service Quotas ahead of the promotion, and add the increase to a quota request template in AWS Organizations so that new accounts inherit it. Correct answer Your answerSet reserved concurrency on the API's function to the expected peak so that the capacity is guaranteed during the promotion. Correct answer Your answerExplanation
Service Quotas publishes usage metrics for supported quotas and can create a CloudWatch alarm against the applied quota value, so an 80 percent threshold warns the team while there is still headroom rather than after requests are rejected. Raising the quota through Service Quotas before the event is the other half, and a quota request template propagates the same value to accounts created later. An alarm on the Throttles metric is by definition too late, because throttling is the customer-visible failure. Trusted Advisor limit checks refresh on their own cadence and require someone to look, the manual step that failed last time. Reserved concurrency carves capacity out of the same account quota rather than adding any.
-
Question 46
Correct IncorrectWhich deployment configuration values should the team set?
Minimum healthy percent 100 and maximum percent 200. Correct answer Your answerMinimum healthy percent 50 and maximum percent 100. Correct answer Your answerMinimum healthy percent 100 and maximum percent 100. Correct answer Your answerMinimum healthy percent 0 and maximum percent 200. Correct answer Your answerExplanation
The minimum healthy percent is the floor the scheduler must keep running, and the maximum percent is the ceiling of running plus pending tasks, so a floor of one hundred with a ceiling of two hundred lets Amazon ECS start replacement tasks alongside all eight existing ones and only drain an old task once a new one is healthy. A floor of fifty allows half the tasks to be stopped first, which is the dip the team is trying to remove. A floor and a ceiling both at one hundred leaves no headroom to launch anything, so a rolling deployment cannot make progress. A floor of zero permits the scheduler to stop every task before starting replacements, which is a full outage.
-
Question 47
Correct IncorrectWhich approach gives the SRE team a unified view with the least operational overhead?
Grant the SRE role cross-account trust in all 60 accounts and document a role-switching runbook for incident response. Correct answer Your answerCreate a CloudWatch Logs subscription filter in every account that ships all log events into a central log group in the tooling account. Correct answer Your answerSchedule an AWS Lambda function in the tooling account that calls GetMetricData in each workload account and republishes the results as custom metrics in the tooling account. Correct answer Your answerConfigure CloudWatch cross-account observability: designate the tooling account as the monitoring account and link the 60 workload accounts as source accounts through the organization, sharing metrics, logs, and traces. Correct answer Your answerExplanation
CloudWatch cross-account observability is purpose-built for this: source accounts are linked to a monitoring account through the organization, and the monitoring account can then search logs, graph metrics, and view service maps across every linked account in one console, without copying telemetry anywhere or writing code. Cross-account role switching is what the team already does and is the problem being solved. Centralizing every log event with subscription filters duplicates ingestion and storage cost for 60 accounts and still leaves metrics and traces stranded in the source accounts. A scheduled Lambda that re-publishes metrics creates a fragile pipeline to own, doubles custom metric charges, and loses the original resource context.
-
Question 48
Correct IncorrectWhich access configuration meets these requirements?
Create an IAM user for the vendor with the ReadOnlyAccess policy, and deliver the access key and secret key through an encrypted channel. Correct answer Your answerCreate an IAM role with the ReadOnlyAccess policy whose trust policy allows the vendor's account as principal and requires a sts:ExternalId condition matching the unique identifier the vendor issued for this customer. Correct answer Your answerCreate an IAM role with the ReadOnlyAccess policy whose trust policy allows the vendor's account as principal, and share the role ARN with the vendor. Correct answer Your answerCreate an IAM user for the vendor, store its access keys in AWS Secrets Manager, and grant the vendor's account cross-account permission to read that secret. Correct answer Your answerExplanation
A cross-account role removes long-lived credentials, and the external ID condition addresses the confused deputy problem that multi-tenant vendors create: without it, any other customer of the vendor could persuade the vendor's platform to assume this company's role, because the role ARN is all that is needed. Requiring the vendor-issued identifier ties an assume-role call to this specific customer relationship. An IAM user hands out static keys the company must rotate and cannot easily revoke. A role that trusts the vendor account with no condition is the confused deputy case itself. Storing user keys in Secrets Manager only moves the same long-lived credentials somewhere else.
-
Question 49
Correct IncorrectWhich two actions are required?
Register the security team account as a delegated administrator for CloudFormation StackSets in AWS Organizations. Correct answer Your answerCreate the stack set with self-managed permissions and create the execution role in each target account by hand. Correct answer Your answerCreate the stack set with service-managed permissions and leave automatic deployment turned off so the team controls each rollout. Correct answer Your answerCreate the stack set with service-managed permissions, target the Workloads organizational unit, and enable automatic deployment. Correct answer Your answerCreate an AWS Config organization conformance pack in the security account and let it provision the detection stack resources in each account. Correct answer Your answerExplanation
StackSets operations from anywhere other than the management account require the account to be registered as a delegated administrator for the service, which is the first half of the requirement. Service-managed permissions are what allow an organizational unit to be used as a target and are the prerequisite for automatic deployment, which puts the stack into accounts that join that unit later. Self-managed permissions cannot target an organizational unit and force an execution role to be created in every account, including future ones. Service-managed permissions with automatic deployment disabled misses new accounts. A conformance pack deploys Config rules and remediation configurations, not an arbitrary detection stack.
-
Question 50
Correct IncorrectWhich two changes together stop the duplicate processing and get the malformed messages off the queue? (Select TWO.)
Raise the queue's visibility timeout to at least six minutes so that a message is not made visible again while a consumer is still working on it. Correct answer Your answerConvert the queue to a FIFO queue so that a failing message blocks its message group until processing succeeds. Correct answer Your answerConfigure a redrive policy on the queue that points at a dead-letter queue with a maxReceiveCount of five, so messages that keep failing are moved off the main queue. Correct answer Your answerReduce the message retention period to one hour so that malformed messages age out of the queue quickly. Correct answer Your answerEnable long polling by setting ReceiveMessageWaitTimeSeconds to 20 on the queue. Correct answer Your answerExplanation
The duplicates come from a visibility timeout shorter than the processing time: at 30 seconds the message becomes visible again while the first consumer is still rendering it, so a second consumer picks it up, and raising the timeout past the worst-case duration ends that. The perpetual retries need a redrive policy, which moves a message to a dead-letter queue once the receive count exceeds the configured maximum, isolating poison messages for inspection. A FIFO queue shortens nothing and would let one malformed message stall an entire message group. Cutting retention to an hour discards legitimate backlog along with the bad messages. Long polling reduces empty receives and request cost, and does not affect redelivery or poison messages.
-
Question 51
Correct IncorrectWhich automated response meets these requirements?
Create an Amazon EventBridge rule matching the aws.guardduty source, the finding type, and a severity of 7 or higher, and target an AWS Systems Manager Automation runbook that deregisters the instance from the target group, replaces its security groups with an isolation group that allows no traffic, and snapshots its EBS volumes. Correct answer Your answerCreate an Amazon EventBridge rule matching the finding and target an AWS Lambda function that calls TerminateInstances on the affected instance. Correct answer Your answerEnable GuardDuty automatic remediation for cryptocurrency findings so that GuardDuty quarantines the instance itself. Correct answer Your answerCreate an Amazon EventBridge rule matching the finding and target an AWS Lambda function that replaces the subnet's network ACL with one that denies all inbound and outbound traffic. Correct answer Your answerExplanation
Containment here has three parts, and an Automation runbook driven by an EventBridge rule on the GuardDuty finding performs all of them in one documented, repeatable step: removing the instance from the target group stops customer traffic, an isolation security group with no rules cuts the network path, and EBS snapshots preserve the disks for the investigation. Terminating the instance contains the threat but destroys the evidence the team was asked to keep. GuardDuty has no remediation capability of its own; it produces findings and leaves the response to EventBridge targets. Replacing the subnet's network ACL isolates every instance in that subnet, not just the compromised one, so it converts a contained incident into a wider outage.
-
Question 52
Correct IncorrectWhich configuration passes both values into the build action?
Have the source action write the commit ID to an AWS Systems Manager parameter and have the build action read both values from Parameter Store. Correct answer Your answerDeclare a pipeline-level variable for the environment label and set the build action environment variables to #{variables.EnvLabel} and #{SourceVariables.CommitId}. Correct answer Your answerSet the image tag from the CODEBUILD_RESOLVED_SOURCE_VERSION environment variable inside the buildspec and hardcode the environment label in the buildspec. Correct answer Your answerReference $CODEPIPELINE_COMMIT_ID and $CODEPIPELINE_ENVIRONMENT in the buildspec, which CodePipeline injects into every downstream action. Correct answer Your answerExplanation
Every CodePipeline action publishes output variables under a namespace, and a source action exposes CommitId there, so a later action can reference it with the namespaced syntax in its own configuration. Pipeline-level variables are a V2 feature whose values are supplied when a release is started and are referenced the same way, which covers the label without a pipeline edit. Writing the commit ID to Parameter Store adds a component and races between concurrent executions. The CodeBuild resolved source version does give the commit but leaves the label hardcoded, so the second requirement fails. The two invented CodePipeline environment variables do not exist and nothing would be injected.
-
Question 53
Correct IncorrectWhich approach gives the team queryable history across all accounts with the least infrastructure to build and maintain?
Create an organization CloudTrail Lake event data store with a seven-year retention period that ingests management and data events from all accounts, and run SQL queries directly against the event data store. Correct answer Your answerKeep delivering to Amazon S3 and build an AWS Glue crawler plus an Athena table with partition projection over the trail prefixes. Correct answer Your answerEnable CloudTrail Insights on the organization trail so that the team can query the resulting findings. Correct answer Your answerCreate an Amazon EventBridge rule that forwards CloudTrail events to an Amazon OpenSearch Service domain, and have analysts query the domain. Correct answer Your answerExplanation
CloudTrail Lake is a managed, immutable event data store with its own SQL query engine and a retention period configurable up to seven years or more, and an organization-level store collects events from every member account without any per-account wiring — there is no table, crawler, or partition scheme to own. The Glue-and-Athena route works and is cheaper per query, but it is precisely the partitioning and cataloging maintenance the team is trying to escape. CloudTrail Insights only surfaces anomalies in API call rates and error rates; it is not a general query facility. Forwarding through EventBridge sees management events as they occur but not three years of history, and it adds an OpenSearch cluster to size, secure, and pay for.
-
Question 54
Correct IncorrectWhich combination of controls meets these requirements?
Turn on the four block public access settings on each existing bucket, and give the partner a set of presigned URLs regenerated nightly by an AWS Lambda function. Correct answer Your answerCreate an AWS Config rule that detects public buckets and notifies the security team so that the setting can be corrected when it drifts. Correct answer Your answerAttach a service control policy that denies s3:PutBucketAcl in the member accounts, and give the partner an IAM user with a policy scoped to the prefix. Correct answer Your answerTurn on account-level block public access in every member account and attach a service control policy that denies s3:PutAccountPublicAccessBlock, and give the partner access through an S3 access point whose policy is scoped to the reports/2026/ prefix. Correct answer Your answerExplanation
Account-level block public access applies to every existing and future bucket in the account, and denying the API that changes it through a service control policy is what turns the setting into a guarantee rather than a default someone can undo. An access point with its own policy then carries the partner's prefix-scoped access without reopening the bucket policy. Bucket-level settings alone leave every newly created bucket to be configured again. A Config rule is detective: it reports the exposure after it exists rather than preventing it. Denying only the bucket ACL API leaves bucket policies and object ACLs as open paths to a public object, and a partner IAM user means issuing long-lived credentials the company must rotate.
-
Question 55
Correct IncorrectWhich implementation meets these requirements?
Create AWS Config managed rules for both conditions in every account and alert the governance team when a resource is marked noncompliant. Correct answer Your answerAdd a CodeBuild action that runs cfn-lint over the templates and fails the build on any finding it reports. Correct answer Your answerAdd a CodeBuild action before the deploy stage that runs AWS CloudFormation Guard against a rules file held by the governance team, exiting nonzero on any violation. Correct answer Your answerAttach a stack policy to each target stack that denies updates which would create unencrypted buckets or open security groups. Correct answer Your answerExplanation
CloudFormation Guard evaluates a template against declarative rules written in its own policy language, so the governance team can express both conditions as rules, keep them in a repository, and fail a build action on any violation before a stack is touched. AWS Config rules evaluate resources that already exist, which is detection after the fact rather than prevention in the pipeline. cfn-lint validates templates against the resource specification and catches malformed properties and bad references, but it does not express organization-specific policy such as a required encryption block. A stack policy governs which existing logical resources may be changed by an update and cannot inspect resource properties at all.
-
Question 56
Correct IncorrectWhich configuration meets the latency objective and enforces the concurrency ceiling?
Set a reserved concurrency of 200 on the function, which both caps concurrency at 200 and keeps 200 execution environments initialized and ready. Correct answer Your answerConfigure provisioned concurrency of 150 on the function's published alias with an Application Auto Scaling scheduled action that raises it just before each hourly peak, and set the function's reserved concurrency to 200. Correct answer Your answerConfigure provisioned concurrency of 150 on the $LATEST version of the function and leave the account's unreserved concurrency available to absorb the rest of the burst. Correct answer Your answerCreate an Amazon EventBridge rule that invokes the function with a warm-up payload every minute so that execution environments stay initialized between bursts. Correct answer Your answerExplanation
Provisioned concurrency keeps initialized environments ready so bursts hit warm code, Application Auto Scaling scheduled actions raise it just before the predictable hourly peak and lower it afterwards to control cost, and reserved concurrency is a separate setting that caps the function at 200 — the two solve different halves of the requirement. Reserved concurrency alone only sets a limit and pre-initializes nothing, so every burst still pays the 2.5-second cold start. Provisioned concurrency cannot be configured on $LATEST at all — it requires a published version or an alias — and that option also leaves the partner limit unenforced. Scheduled warm-up invocations keep one or two environments alive, nowhere near 150.
-
Question 57
Correct IncorrectWhich access method satisfies the policy?
Launch a hardened bastion host in a public subnet, rotate its host keys weekly, and allow SSH from the bastion to the private instances. Correct answer Your answerUse EC2 Instance Connect to push a short-lived public key to the instance for each session, so that no key is stored permanently. Correct answer Your answerUse AWS Systems Manager Session Manager with an instance profile granting the managed SSM policy, interface VPC endpoints for ssm, ssmmessages, and ec2messages, and session logging to Amazon S3 and Amazon CloudWatch Logs. Correct answer Your answerConnect responders to the VPC over AWS Client VPN and store the shared SSH private key in AWS Secrets Manager, granting responders read access during incidents. Correct answer Your answerExplanation
Session Manager reaches the instance through an outbound connection the SSM Agent makes, so no inbound port and no bastion are needed, and the three interface endpoints keep that connection inside the VPC for instances with no internet route. Access is granted through IAM rather than keys, and session logging to S3 and CloudWatch Logs produces the command record the compliance team requires. A bastion is forbidden outright by the policy. EC2 Instance Connect still speaks SSH on port 22 and therefore needs inbound access to the instance, and it produces no keystroke record. Client VPN plus a shared private key reintroduces exactly the long-lived key the policy bans and again logs nothing about what was typed.
-
Question 58
Correct IncorrectWhich lifecycle event hook should invoke the AWS Lambda function that runs the contract test?
AfterAllowTraffic Correct answer Your answerApplicationStart Correct answer Your answerBeforeInstall Correct answer Your answerAfterAllowTestTraffic Correct answer Your answerExplanation
In an ECS blue/green deployment the replacement task set becomes reachable on the test listener partway through, and the hook that fires at that point is the one whose Lambda function is meant to validate the new task set; returning a failed status from it stops the deployment and rolls back before any production traffic shifts. The hook that runs after production traffic has already moved is too late to protect customers. ApplicationStart belongs to EC2 and on-premises deployments driven by an AppSpec script section, not to ECS. The hook that runs before installation fires before the replacement task set exists, so there is nothing for the contract test to call.
-
Question 59
Correct IncorrectWhich two actions together produce that evidence? (Select TWO.)
Create a VPC flow log on the instance's elastic network interface that captures ALL traffic and delivers records to an Amazon CloudWatch Logs log group. Correct answer Your answerEnable Amazon S3 server access logging on the bucket that the application writes to, and correlate the request timestamps. Correct answer Your answerEnable AWS CloudTrail data events for the instance's attached Amazon EBS volumes so that the network calls are recorded. Correct answer Your answerTurn on AWS Config recording for the instance's security group so that the current inbound rules are captured as a configuration item. Correct answer Your answerQuery the flow log group with CloudWatch Logs Insights, filtering on a destination port of 8443 and grouping by the action field to compare ACCEPT and REJECT records. Correct answer Your answerExplanation
A VPC flow log at the network interface level records the IP traffic metadata that settles the argument — source, destination, port, protocol, packet and byte counts, and an action of ACCEPT or REJECT — and it is enabled entirely from the VPC console with no agent and no restart. Logs Insights then turns those records into the actual answer, because grouping by action on destination port 8443 distinguishes packets that never arrived from packets that arrived and were rejected by a security group or network ACL. S3 server access logging describes bucket requests, not TCP traffic to an instance. CloudTrail data events for EBS are not a way to observe network flow. AWS Config captures configured rules, not dropped packets.
-
Question 60
Correct IncorrectWhich two actions should the DevOps engineer take to meet these requirements with the least operational overhead?
Enable Amazon Inspector from a delegated administrator for the organization with Amazon ECR, Amazon EC2, and AWS Lambda scanning activated, so that workloads and stored images are rescanned as new CVEs are published. Correct answer Your answerEnable Amazon ECR basic scanning on the repository so that every image is scanned when it is pushed. Correct answer Your answerAdd a scheduled AWS Lambda function that runs a third-party scanner against the running tasks each week and emails the results to the platform team. Correct answer Your answerAdd a pipeline stage between build and deploy that reads the Amazon Inspector findings for the pushed image digest and fails the stage when a finding of CRITICAL severity exists. Correct answer Your answerEnable the relevant AWS Security Hub controls so that Security Hub scans the images in Amazon ECR and blocks deployment of vulnerable ones. Correct answer Your answerExplanation
Amazon Inspector is the continuous scanner: activated for the organization, it covers ECR images, EC2 instances, and Lambda functions, and it re-evaluates existing resources when new vulnerabilities are published rather than only at push time. The gate is a separate job, so a pipeline stage that queries the findings for the exact image digest and fails on a critical severity is what actually stops the deployment. ECR basic scanning runs only on push, covers operating system packages, and does not rescan as new CVEs appear. A weekly third-party scan is code and schedule the team owns and leaves a six-day window. Security Hub aggregates and normalizes findings from scanners such as Inspector but performs no scanning and blocks no deployment.
-
Question 61
Correct IncorrectWhich approach meets these requirements with the least operational overhead?
Create an EC2 Image Builder image pipeline with a build component, test components, a distribution configuration listing the three Regions and the six target accounts, and a monthly schedule. Correct answer Your answerCreate a CodePipeline pipeline that runs a Packer template in AWS CodeBuild, then runs a test harness, then calls CopyImage and ModifyImageAttribute for each Region and account. Correct answer Your answerWrite an AWS Systems Manager Automation runbook that launches an instance, runs the hardening script through Run Command, creates an image, and is invoked by an Amazon EventBridge schedule. Correct answer Your answerHave an engineer launch an instance monthly, apply the hardening script interactively, create an image from the instance, and share it from the console. Correct answer Your answerExplanation
EC2 Image Builder is the managed image pipeline service, and each requirement maps to one of its parts: build components install and harden, test components gate the release of the image, a distribution configuration copies the finished AMI into named Regions and shares it with named accounts, and the pipeline schedule runs the whole thing monthly. A Packer pipeline reproduces all of that but leaves the team owning a template, a build project, a test harness and the copy and share calls. A Systems Manager Automation runbook can build an image but has no test gate or distribution model, so both would be hand-written. Doing it interactively every month is unrepeatable and produces no record of what was applied.
-
Question 62
Correct IncorrectWhich change addresses both the slow failover and the allow-listing requirement with the least client-side change?
Lower the TTL on the latency records to 10 seconds and publish the load balancer DNS names to the enterprise customers for allow-listing. Correct answer Your answerPlace an Amazon CloudFront distribution with an origin group in front of the three Regions, and ask customers to allow-list the CloudFront address ranges published in the AWS IP ranges file. Correct answer Your answerCreate an AWS Global Accelerator standard accelerator with the three load balancers as endpoints in Regional endpoint groups, and publish the accelerator's two static anycast IP addresses to the customers. Correct answer Your answerReplace latency-based routing with Route 53 failover routing backed by health checks on each Regional load balancer. Correct answer Your answerExplanation
Global Accelerator gives clients two static anycast IP addresses that never change, satisfying the allow-listing requirement, and it makes failover a network-layer decision rather than a DNS one: when an endpoint group's health checks fail, traffic is withdrawn and rerouted over the AWS backbone within seconds, so a client that caches DNS forever still lands on a healthy Region. Lowering the TTL does not help clients that already ignore it, and load balancer DNS names resolve to changing addresses. CloudFront is optimized for HTTP caching, its origin failover covers only specific request methods and status codes, and its published address ranges are large and change. Failover routing is still DNS and inherits the same caching problem.
-
Question 63
Correct IncorrectWhich approach meets these requirements with the least custom code?
Create an AWS Glue crawler over the buckets and run scheduled Amazon Athena queries with regular expressions that look for card and identifier formats. Correct answer Your answerEnable Amazon GuardDuty S3 protection so that access to buckets containing sensitive data is reported as findings. Correct answer Your answerEnable Amazon Inspector with Amazon S3 scanning so that objects are evaluated against the managed rules package each month. Correct answer Your answerEnable Amazon Macie for the organization from a delegated administrator, and run a monthly sensitive data discovery job scoped to those buckets that uses the managed data identifiers together with a custom data identifier for the employee pattern. Correct answer Your answerExplanation
Macie is the managed sensitive data discovery service: it inventories buckets, scans objects on a schedule, ships managed data identifiers for card numbers and national identifiers, accepts a custom data identifier for a house-specific pattern such as the employee format, and publishes findings that Security Hub picks up. The Glue and Athena approach sees only data that can be crawled into a table, misses everything unstructured, and makes the compliance team own a library of regular expressions. GuardDuty S3 protection analyzes API activity for anomalous access and never inspects object content. Amazon Inspector scans instances, images, and functions for software vulnerabilities and performs no data classification.
-
Question 64
Correct IncorrectWhich trigger configuration matches this?
A push trigger with a branch filter that includes feature/* and excludes main. Correct answer Your answerA pull request trigger with the opened and updated events, a branch filter that includes main, and a file path filter that excludes docs/**. Correct answer Your answerA push trigger with a branch filter that includes main, combined with a manual approval action at the head of the pipeline. Correct answer Your answerNo trigger at all, with the source action left on periodic change detection so the pipeline polls the repository every few minutes. Correct answer Your answerExplanation
A V2 pipeline trigger can be built on pull request events rather than pushes, and the event list distinguishes a pull request being opened from one being updated with a new commit, which together give the refresh behavior reviewers asked for. The branch filter on a pull request trigger matches the destination branch, so scoping it to main ignores pull requests aimed elsewhere, and the file path exclusion suppresses documentation-only changes. A push trigger on feature branches starts runs for exactly the pushes that should start nothing. A push trigger on main fires after a merge rather than before review. Periodic change detection polls the branch and knows nothing about pull requests.
-
Question 65
Correct IncorrectWhich two configurations together meet the requirement? (Select TWO.)
Save a CloudWatch Logs Insights query that counts the matching lines, and schedule it to run every five minutes so that it raises an alert when the count exceeds 20. Correct answer Your answerCreate a metric filter on the log group that matches the error pattern and publishes a count to a custom metric, then create a metric alarm on that metric with a threshold of 20 over a five-minute period and treat missing data as not breaching. Correct answer Your answerCreate a subscription filter that delivers the matching lines to an Amazon Data Firehose stream so that the count can be evaluated from the objects written to Amazon S3. Correct answer Your answerAdd a Systems Manager OpsCenter action to the alarm so that the transition into ALARM creates an OpsItem, alongside any Amazon SNS notification action. Correct answer Your answerEnable CloudWatch Container Insights on the ECS cluster so that the error count is collected automatically as a built-in performance metric. Correct answer Your answerExplanation
A metric filter is what turns a text pattern in a log group into a numeric CloudWatch metric, and a metric alarm on that metric expresses the threshold of 20 in five minutes; treating missing data as not breaching keeps the alarm quiet during periods with no matching lines. CloudWatch alarms support a Systems Manager OpsCenter action, so entering ALARM can create an OpsItem directly, which is the no-code half of the requirement. Logs Insights saved queries run on demand and cannot be scheduled to raise alerts. A subscription filter into Firehose moves the raw lines to S3 but leaves counting and alerting to something else. Container Insights collects CPU, memory, and task-level performance metrics, not application error strings.
-
Question 66
Correct IncorrectWhich approach meets these requirements?
Attach AppBaseline as a managed policy to every role the leads create, and review new roles weekly to confirm that no additional inline policies were attached. Correct answer Your answerGrant the leads permission to call iam:CreateRole and iam:PutRolePolicy only when the iam:PermissionsBoundary condition key matches the AppBaseline policy ARN, and deny them any action that modifies or deletes that policy. Correct answer Your answerAttach a service control policy to the organizational unit containing the shared account that allows only the actions in AppBaseline. Correct answer Your answerCreate an IAM group whose permissions are AppBaseline, add the leads to the group, and have them create roles from the group's console session. Correct answer Your answerExplanation
A permissions boundary caps the effective permissions of a principal, and the iam:PermissionsBoundary condition key lets the platform team require that any role a lead creates carries the AppBaseline boundary, while denying changes to the policy itself closes the obvious bypass. Because the constraint sits in the leads' own policies, the platform team's automation is untouched. Attaching AppBaseline as a plain managed policy sets a floor rather than a ceiling, since a lead can add an inline policy that grants more, and the weekly review finds that only afterward. A service control policy applies to every principal in the account, so it would clamp the platform automation too. IAM groups apply only to users and have no effect on roles.
-
Question 67
Correct IncorrectWhich two actions implement this split?
Create one custom patch baseline with a seven-day auto-approval delay and register it for all instances, relying on maintenance window timing to give development earlier patches. Correct answer Your answerCreate two custom patch baselines for the operating system, one with an auto-approval delay of zero days and one with an auto-approval delay of seven days, and register each with its own patch group. Correct answer Your answerUse the AWS predefined default patch baseline for both environments and vary only the maintenance window schedules. Correct answer Your answerReplace Patch Manager with a State Manager association that runs the package manager upgrade command on a schedule in each environment. Correct answer Your answerTag the instances with a Patch Group tag whose value matches the patch group registered on the intended baseline, and run each group from its own maintenance window. Correct answer Your answerExplanation
Which patches are approved is decided by a baseline approval rule, and how long after release they are approved is the auto-approval delay, so two baselines with different delays is the only way to express the two policies. A baseline reaches instances through a patch group, and an instance joins one by carrying the Patch Group tag key with the matching value, after which each group patches in its own window and reports compliance. A single baseline with a seven-day delay withholds patches from development whenever the window runs, because a window controls timing rather than approval. The predefined baseline has one delay for everyone. A package upgrade run from State Manager abandons baselines and patch compliance data.
-
Question 68
Correct IncorrectWhich approach removes the manual renewal work for both tiers?
Keep importing the third-party certificate and create an Amazon EventBridge rule on the ACM certificate approaching expiration event that opens a ticket 45 days ahead. Correct answer Your answerRequest a public ACM certificate validated by email for the internet-facing load balancer, and continue issuing self-signed certificates for the internal load balancers with a longer validity period. Correct answer Your answerRequest a public ACM certificate validated by DNS and leave the validation CNAME record in the Route 53 zone, and issue certificates for the internal load balancers from ACM backed by a private CA in AWS Private CA. Correct answer Your answerRun certbot on a scheduled AWS Lambda function that obtains certificates from a free public CA and imports them into ACM for both tiers. Correct answer Your answerExplanation
ACM renews the certificates it issues, and it does so without human action only when the validation method keeps proving domain ownership on its own, which is what leaving the DNS validation CNAME in the Route 53 zone provides; the load balancer then picks up the renewed certificate with no change. Private certificates issued through ACM from a private CA are managed the same way, retiring the annual self-signed replacement. Imported certificates are never renewed by ACM, so the expiration event produces only a better-timed ticket for the same manual work. Email validation asks a human to act on renewal mail, the step that failed over a holiday. The certbot job is custom infrastructure reimplementing what ACM already does.
-
Question 69
Correct IncorrectWhich approach meets these requirements?
Enable basic scanning on the repository with scan on push, and have the very next pipeline action read the results immediately after the push action reports success. Correct answer Your answerAdd an ECR lifecycle policy rule that expires any image whose scan findings include a critical severity vulnerability. Correct answer Your answerEnable Amazon Inspector enhanced scanning for the registry and insert a Lambda invoke action that waits for the scan to complete, calls DescribeImageScanFindings, and fails the action when a critical finding is present. Correct answer Your answerConfigure the ECS task definition to reference only images carrying the tag scanned, so unscanned images can never be deployed. Correct answer Your answerExplanation
Enhanced scanning is the ECR mode backed by Amazon Inspector and is the one that covers language package vulnerabilities alongside operating system packages, which the requirement names explicitly. Scanning is asynchronous, so the gate has to be an action that waits for completion, reads the findings, and fails the stage on a critical severity, which stops the pipeline before the deploy stage runs. Basic scanning covers operating system packages only, and reading results the instant the push succeeds usually finds the scan still running. Lifecycle policy rules select images by tag pattern, age or count, and cannot reference scan findings. A tag convention blocks nothing unless something applies the tag, and nothing here does.
-
Question 70
Correct IncorrectWhich action resolves the failure and prepares the account for the pipeline?
Run cdk synth with staging disabled so the application no longer produces assets that require a staging location. Correct answer Your answerCreate a CloudFormation stack in the new account containing an Amazon S3 bucket named after the account and Region, and re-run the deployment. Correct answer Your answerGrant the deploying principal the AdministratorAccess managed policy in the new account, since the error is a permissions failure in disguise. Correct answer Your answerRun cdk bootstrap for the account and Region with a trust option naming the tooling account, which creates the toolkit stack with the asset bucket, the asset repository, the deployment roles and the version parameter. Correct answer Your answerExplanation
The CDK stores assets and the roles it assumes during deployment in a per-environment toolkit stack, and the missing version parameter is the marker the toolkit uses to detect that the environment was never bootstrapped. Bootstrapping the account and Region creates the staging bucket, the asset repository for Docker images, the deployment roles and the version parameter, and the trust option authorizes the tooling account to assume those roles later. Disabling staging does not remove the need for a repository to hold image assets. Hand-building a bucket produces none of the roles or the version parameter that the toolkit looks for. The failure is a missing stack rather than a missing permission, so broad administrator rights change nothing.
-
Question 71
Correct IncorrectWhich change lets the single pipeline deploy into all three Regions?
Configure a cross-Region deploy action for each Region and define an artifact store for every Region the pipeline deploys into, so CodePipeline replicates the artifact into each Regional bucket. Correct answer Your answerCreate one pipeline per Region, each with its own source action on the same repository and branch. Correct answer Your answerEnable cross-Region replication on the us-east-1 artifact bucket and point the two remote deploy actions at the replica buckets. Correct answer Your answerLeave one deploy action in place and set the target Region inside the template by overriding the AWS::Region pseudo parameter per deployment. Correct answer Your answerExplanation
A CodePipeline action that runs in a Region other than the pipeline Region needs an artifact bucket in that Region, declared in the pipeline artifact stores, and CodePipeline then copies the input artifact there before the action runs — the failure described is exactly the missing Regional store. Three separate pipelines work but triple the definitions to keep in step and lose the single release view, and they rebuild the artifact rather than promoting one. Bucket replication does not register a Regional artifact store, so the action still has nowhere to read from. AWS::Region is a read-only pseudo parameter that reports where the stack is being created and cannot be set to redirect a deployment.
-
Question 72
Correct IncorrectWhich approach meets these requirements with the least ongoing effort?
Deploy a CloudFormation stack in each account containing 40 individual Config rule resources, and update every stack when a rule is added. Correct answer Your answerDeploy an organization conformance pack from the management account or a delegated administrator account, targeting all accounts, and edit the pack template when a rule is added. Correct answer Your answerEnable an AWS Security Hub standard in every account and rely on its controls to cover the 40 rules. Correct answer Your answerWrite service control policies that block the actions the 40 rules are meant to detect. Correct answer Your answerExplanation
A conformance pack is a packaged collection of Config rules and remediation actions deployed as a unit, and the organization form of it fans out from the management account or a delegated administrator to every member account, reporting compliance at the pack level as well as per rule — both the single-edit requirement and the single score follow directly. Sixty stacks of individual rules deliver the same evaluations but leave the team updating sixty stacks and aggregating the results by hand. A Security Hub standard has a fixed control set that cannot be replaced by an arbitrary list of 40 rules. Service control policies prevent actions rather than evaluate configuration, and they produce no compliance record at all.
-
Question 73
Correct IncorrectWhich source configuration should the team move to?
Create a fine-grained personal access token owned by a shared machine user, store it in AWS Secrets Manager, and reference it from the source action. Correct answer Your answerReplace the source action with an Amazon S3 source and add a GitHub Actions workflow that uploads a zipped source bundle on each push. Correct answer Your answerCreate an AWS CodeConnections connection to GitHub, complete the handshake by installing the AWS connector app on the GitHub organization, and grant the pipeline role permission to use the connection. Correct answer Your answerMirror the GitHub repository into AWS CodeCommit on a schedule and point the source action at the mirror. Correct answer Your answerExplanation
A CodeConnections connection starts in a pending state and is completed through a one-time browser handshake that installs the AWS connector application on the GitHub organization, so the trust is owned by the organization, no token is stored in AWS, and the connection manages repository event delivery for the pipeline. A machine-user token is still a long-lived secret that somebody has to rotate and that a repository administrator can revoke by accident. An S3 source plus an uploader workflow works but discards commit metadata and adds a bundle-publishing step to maintain. A scheduled mirror into another repository service introduces a second copy of the truth and a delay between push and pipeline start.
-
Question 74
Correct IncorrectWhich two template settings are required on each function?
AutoPublishAlias set to an alias name such as live, so SAM publishes a new function version and moves that alias on every deployment. Correct answer Your answerDeploymentPreference with its type set to AllAtOnce. Correct answer Your answerDeploymentPreference with its type set to Canary10Percent5Minutes and an Alarms list naming the CloudWatch error alarm. Correct answer Your answerProvisionedConcurrencyConfig on the function so that new versions are warm before traffic arrives. Correct answer Your answerAn API Gateway canary release deployment on the stage that routes ten percent of requests to the new deployment. Correct answer Your answerExplanation
SAM implements gradual deployment by handing a function alias to AWS CodeDeploy, and the alias only exists when AutoPublishAlias is set — without it the deployment preference has nothing to shift and the setting is ignored. The deployment preference itself supplies the canary shape and the alarm list that CodeDeploy watches, and a breaching alarm during the shift reverts the alias to the previous version. The all-at-once type moves everything in one step and gives the alarm no window. Provisioned concurrency changes cold-start behavior and plays no part in traffic shifting. An API Gateway canary stage splits only HTTP traffic through that stage and offers no automatic rollback of the function version.
-
Question 75
Correct IncorrectWhich pipeline design meets these requirements?
Add a CodeBuild action at the start of the production stage that rebuilds the application from the same commit hash before deploying. Correct answer Your answerAdd a Lambda invoke action at the start of the production stage that polls an Amazon DynamoDB table until an operator writes an approval record. Correct answer Your answerCreate three pipelines, one per environment, each triggered by the success of the previous pipeline and each building from the same commit. Correct answer Your answerAdd a manual approval action at the start of the production stage with an Amazon SNS topic for notification and a review URL pointing at the staging test report, and pass the build stage output artifact into every deploy action. Correct answer Your answerExplanation
A manual approval action halts the stage until an authorized principal approves or rejects, publishes the request to the configured SNS topic so subscribers receive it by email, and carries a review URL, while the approver identity and comment are recorded in the execution history for the auditors. Passing the build stage output artifact into all three deploy actions is what guarantees that the bits deployed to production are the bits staging tested. Rebuilding from the same commit produces a different artifact from a different toolchain state, which is what the auditors forbade. A DynamoDB polling function reinvents approval with no audit identity. Three pipelines that each rebuild break artifact identity as well.