Design Secure ArchitecturesQuestion 1
A company serves private static content from Amazon S3 through Amazon CloudFront and needs to ensure that the S3 bucket can be accessed only through the CloudFront distribution, not directly over the internet. Which feature should the architect configure?
Choose one.
- AAn S3 bucket policy that allows s3:GetObject for all principals
- BAn S3 gateway VPC endpoint with an endpoint policy for the bucket
- COrigin access control (OAC) with a bucket policy that allows only the distribution
- DCloudFront signed URLs with S3 Block Public Access turned off
Show answer
Answer: C
Origin access control makes CloudFront sign its requests to S3, and the bucket policy allows only the CloudFront service principal for that distribution, so direct requests to the bucket are denied.
The correct answer is Origin access control (OAC) with a bucket policy that allows only the distribution. With OAC, CloudFront signs origin requests with SigV4. The bucket policy grants s3:GetObject to the cloudfront.amazonaws.com service principal with a condition on AWS:SourceArn matching the distribution, and S3 Block Public Access can stay enabled. OAC replaces the legacy origin access identity (OAI) and supports SSE-KMS. A public bucket policy lets anyone bypass CloudFront. A gateway VPC endpoint controls access from resources inside a VPC and does not apply to CloudFront or internet users. Signed URLs restrict which viewers can use the distribution, but they do nothing to stop direct access to the bucket, especially with Block Public Access turned off.
Design Secure ArchitecturesQuestion 2
A company wants to continuously identify Amazon S3 buckets and IAM roles in its accounts that are accessible from outside its AWS organization. Which service should it use?
Choose one.
- AAWS Config managed rules
- BAmazon GuardDuty
- CIAM Access Analyzer with the organization as the zone of trust
- DAWS Trusted Advisor cost optimization checks
Show answer
Answer: C
IAM Access Analyzer uses automated reasoning on resource policies to report resources, such as S3 buckets and IAM roles, that are shared with principals outside the zone of trust.
The correct answer is IAM Access Analyzer with the organization as the zone of trust. An external access analyzer created for the organization continuously analyzes resource-based policies for supported resources, including S3 buckets, IAM role trust policies, KMS keys, Lambda functions and SQS queues, and generates a finding for any resource that grants access to a principal outside the organization. AWS Config managed rules can flag specific settings, such as public S3 buckets, but they do not provide comprehensive cross-account access analysis of IAM role trust policies. Amazon GuardDuty detects malicious or anomalous activity rather than analyzing policies. Trusted Advisor cost optimization checks look for savings opportunities, not external access.
Design Secure ArchitecturesQuestion 3
A company uses an Amazon S3 gateway VPC endpoint and wants to ensure that instances in the VPC can reach only one specific company-owned S3 bucket through that endpoint, and no other bucket in any account. Which control should be applied?
Choose one.
- AA security group outbound rule that blocks port 443
- BAn endpoint policy on the gateway VPC endpoint that allows access only to the specific bucket ARN
- CA bucket policy on the company bucket that requires the aws:SourceVpce condition
- DS3 Block Public Access enabled at the account level
Show answer
Answer: B
A VPC endpoint policy limits which S3 resources can be reached through the endpoint, so allowing only the company bucket's ARN blocks access to every other bucket.
The correct answer is An endpoint policy on the gateway VPC endpoint that allows access only to the specific bucket ARN. Endpoint policies are resource-based policies attached to the endpoint that control which principals, actions and resources are allowed through it. Allowing only the company bucket and its objects prevents instances from reading from or exfiltrating data to any other bucket through the endpoint. Blocking port 443 in a security group would stop all S3 access, including to the approved bucket. A bucket policy that requires aws:SourceVpce restricts who can access the company bucket, but it cannot stop instances from reaching other buckets. S3 Block Public Access prevents public access to the company's own buckets and does not control access to buckets in other accounts.
Design Secure ArchitecturesQuestion 4
A company stores datasets in Amazon S3 and requires the data to be encrypted at rest. Which approaches meet this requirement? (Select THREE.)
Choose three.
- AEncrypt the data on the client side with a customer-managed key before uploading it
- BUse S3 server-side encryption with AWS KMS keys (SSE-KMS)
- CUse S3 server-side encryption with customer-provided keys (SSE-C)
- DApply a restrictive bucket policy without enabling any encryption
- EUse Amazon EC2 key pairs to encrypt the S3 objects
- FEnable S3 Versioning on the bucket
Show answer
Answer: A, B, C
Client-side encryption, SSE-KMS, and SSE-C all store the object data in encrypted form; bucket policies, EC2 key pairs, and versioning do not encrypt data.
The correct answers are Encrypt the data on the client side with a customer-managed key before uploading it, Use S3 server-side encryption with AWS KMS keys (SSE-KMS), and Use S3 server-side encryption with customer-provided keys (SSE-C). With client-side encryption, data is encrypted before it reaches S3, so it is stored encrypted. SSE-KMS has S3 encrypt objects with keys managed in AWS KMS, with key policies and CloudTrail auditing. SSE-C has S3 encrypt objects with a key the customer supplies on each request and does not store. S3 also applies SSE-S3 to new objects by default. A bucket policy controls access but does not encrypt data. EC2 key pairs authenticate SSH sessions to instances. Versioning keeps multiple object versions but does not encrypt them.
Design Secure ArchitecturesQuestion 5
An application on Amazon EC2 calls several AWS services. Which approach best prevents exposure of long-term access keys?
Choose one.
- AEmbed an IAM user's access keys in the application source code
- BStore an IAM user's access keys in a configuration file on the instance
- CAttach an IAM role to the EC2 instance through an instance profile
- DEnable MFA on the root user and use root access keys in the application
Show answer
Answer: C
An IAM role attached through an instance profile provides automatically rotated temporary credentials through the instance metadata service, so no long-term keys are stored anywhere.
The correct answer is Attach an IAM role to the EC2 instance through an instance profile. The AWS SDKs automatically retrieve temporary credentials for the role from the instance metadata service (preferably IMDSv2), and AWS rotates these credentials before they expire. Because there are no long-term access keys on the instance or in the code, there is nothing to leak or rotate manually, and permissions can be scoped with the role's policies. Embedding keys in source code risks exposing them through repositories. Keeping keys in a configuration file still stores long-term credentials that can be copied from the instance or backups. Root access keys should never be used by applications, and MFA does not protect programmatic access with those keys.
Design Secure ArchitecturesQuestion 6
Application servers run in an Auto Scaling group, so their IP addresses change frequently. The database must accept traffic only from those application servers. How should access be configured?
Choose one.
- AAllow the application subnet CIDR range in a network ACL
- BAdd every application instance IP address to the database security group
- CReference the application security group as the source in the database security group
- DAdd network ACL deny rules for all other traffic to the database subnet
Show answer
Answer: C
A security group rule can use another security group as its source, so every current and future instance in the application security group can reach the database without maintaining IP addresses.
The correct answer is Reference the application security group as the source in the database security group. When the database security group allows the database port with the application security group as the source, any instance with that group attached is permitted, regardless of its IP address. New instances launched by the Auto Scaling group are covered automatically, and anything without the group is denied. Allowing the subnet CIDR in a network ACL also admits any other resource in that subnet and does not restrict access to the application servers specifically. Maintaining individual IP addresses breaks every time the group scales. Network ACL deny rules are stateless, subnet-level, and IP-based, so they cannot identify the application instances.
Design Resilient ArchitecturesQuestion 7
A company wants to route events from multiple internal applications and third-party SaaS providers to different targets based on event content, without writing custom routing logic in each application. Which service is best suited?
Choose one.
- AAn Amazon SQS standard queue polled by every application
- BAmazon EventBridge with rules that match event patterns
- CAmazon Kinesis Data Streams with a custom routing consumer
- DAn Amazon MQ broker with routing code in each consumer
Show answer
Answer: B
EventBridge event buses receive events from AWS services, custom applications, and SaaS partner sources, and rules with event patterns route each event to the right targets without custom code.
The correct answer is Amazon EventBridge with rules that match event patterns. Applications publish events to an event bus, and supported SaaS providers deliver events through partner event sources. Rules filter on any field in the event content and send matching events to targets such as Lambda functions, SQS queues, Step Functions state machines or API destinations, so no application needs its own routing logic. An SQS standard queue delivers messages to whichever consumer polls it, and every application would have to filter and discard messages. Kinesis Data Streams would require a custom consumer to inspect and route each record. Amazon MQ is a managed message broker for existing protocols, and routing logic would still live in application code.
Design Resilient ArchitecturesQuestion 8
A company's disaster recovery requirements allow a recovery time objective (RTO) and recovery point objective (RPO) of up to 24 hours, and the company wants to minimize ongoing disaster recovery cost. Which strategy is most appropriate?
Choose one.
- AA pilot light with a continuously replicated database and core services in another Region
- BBackup and restore using AWS Backup with periodic backups copied to another Region
- CAn active-active multi-Region deployment with data replicated between Regions
- DA warm standby running a scaled-down copy of production in another Region
Show answer
Answer: B
Backup and restore is the lowest-cost disaster recovery strategy and fits workloads whose RTO and RPO can be measured in hours, such as 24 hours.
The correct answer is Backup and restore using AWS Backup with periodic backups copied to another Region. With backup and restore, no infrastructure runs in the recovery Region; the company pays mainly for backup storage and cross-Region copies, and it rebuilds the environment from backups, ideally with infrastructure as code, when a disaster occurs. Daily backups meet a 24-hour RPO, and the restore time fits a 24-hour RTO. A pilot light keeps a replicated database and core services running continuously, which costs more and is intended for tighter recovery objectives. Warm standby runs a smaller but fully functional copy of production at all times, and active-active runs full capacity in multiple Regions; both are far more expensive than the requirements justify.
Design Resilient ArchitecturesQuestion 9
A web tier behind a Classic Load Balancer spans two Availability Zones, with six instances in AZ-A and two instances in AZ-B. Traffic is split evenly between the AZs, which overloads the two instances in AZ-B. What should a solutions architect enable to fix this?
Choose one.
- ASticky sessions
- BCross-zone load balancing
- CConnection draining
- DProxy protocol
Show answer
Answer: B
With cross-zone load balancing, each load balancer node distributes traffic across all registered instances in every enabled Availability Zone, so each of the eight instances receives an equal share.
The correct answer is Cross-zone load balancing. Without it, each Classic Load Balancer node routes only to instances in its own Availability Zone, and because DNS spreads clients roughly evenly across the nodes, the two instances in AZ-B each receive about 25 percent of the traffic and the six in AZ-A each receive about 8 percent. Enabling cross-zone load balancing lets every node send traffic to all eight instances evenly. For Classic Load Balancers, cross-zone load balancing is disabled by default when the load balancer is created with the API or CLI. Sticky sessions bind clients to specific instances and can make imbalance worse. Connection draining only lets in-flight requests finish during deregistration. Proxy protocol passes client connection information to back ends.
Design Resilient ArchitecturesQuestion 10
A team is redesigning a web application to span three Availability Zones, with a web tier and an application tier each behind its own load balancer. Each tier must scale independently, and if one Availability Zone fails, lost capacity must be replaced automatically in the remaining Availability Zones with the least operational overhead. How should the Auto Scaling groups be structured?
Choose one.
- ACreate one Auto Scaling group per tier, each spanning all three Availability Zones
- BCreate one Auto Scaling group per Availability Zone that launches both web and application instances
- CCreate six Auto Scaling groups, one for each tier in each Availability Zone
- DCreate a single Auto Scaling group that launches web and application instances in all three Availability Zones
Show answer
Answer: A
One Auto Scaling group per tier, spanning all three Availability Zones, lets each tier scale on its own metrics and automatically rebalances and replaces capacity in healthy Availability Zones when one fails.
The correct answer is Create one Auto Scaling group per tier, each spanning all three Availability Zones. Each tier has its own launch template, scaling policies, and load balancer target group, so web and application capacity scale independently. Because each group spans all three Availability Zones, EC2 Auto Scaling balances instances across them and, if one Availability Zone fails, launches replacement instances in the remaining zones automatically. An Auto Scaling group uses one launch template, so a group that launches both web and application instances cannot scale the tiers independently, whether it is per AZ or shared. Six single-AZ groups add management overhead and cannot shift capacity to other zones when their own Availability Zone fails.
Design Resilient ArchitecturesQuestion 11
Several Amazon EC2 instances read messages from an Amazon SQS queue, write the results to Amazon RDS, and then delete the messages. Processing sometimes takes longer than the visibility timeout, which creates duplicate database records. What should the application do?
Choose one.
- AChange the access permissions on the SQS queue
- BEnable long polling on the queue
- CDelete the queue and create a new one
- DExtend the visibility timeout of messages being processed
Show answer
Answer: D
If processing outlasts the visibility timeout, the message becomes visible again and another worker processes it; extending the visibility timeout prevents this premature redelivery.
The correct answer is Extend the visibility timeout of messages being processed. When a consumer receives a message, SQS hides it for the visibility timeout. If the consumer has not deleted it by then, the message reappears and another instance processes it again, creating duplicate records. Setting a longer default timeout on the queue, or calling ChangeMessageVisibility while a long job is still running, keeps the message hidden until processing finishes and the message is deleted. Consumers should still be idempotent, because standard queues provide at-least-once delivery. Queue permissions control who can access the queue, not redelivery. Long polling reduces empty receives and cost but does not affect visibility. Recreating the queue changes nothing about timing.
Design High-Performing ArchitecturesQuestion 12
An application's load correlates closely with the depth of an Amazon SQS queue rather than with CPU utilization, and the company wants Auto Scaling to automatically maintain a target backlog per instance. Which scaling policy is most appropriate?
Choose one.
- AA target tracking scaling policy based on a custom CloudWatch metric for backlog per instance
- BA scheduled scaling policy based on the time of day
- CA simple scaling policy based on average CPU utilization
- DA target tracking scaling policy on the ApproximateNumberOfMessagesVisible metric alone
Show answer
Answer: A
Target tracking on a custom backlog-per-instance metric (queue depth divided by running instances) keeps capacity proportional to the amount of queued work.
The correct answer is A target tracking scaling policy based on a custom CloudWatch metric for backlog per instance. AWS recommends publishing a metric equal to ApproximateNumberOfMessagesVisible divided by the number of InService instances and setting the target to the acceptable backlog per instance, calculated from the acceptable latency divided by average processing time per message. Target tracking then adds or removes instances to keep that ratio near the target. Scheduled scaling cannot react to unpredictable queue growth. CPU utilization does not reflect queue load for this application. Tracking raw queue depth alone does not change proportionally with the number of instances, so target tracking cannot calculate the right capacity from it.
Design High-Performing ArchitecturesQuestion 13
A company has 15 VPCs across several AWS accounts that all need to communicate with each other and with an on-premises network over AWS Direct Connect. Managing individual VPC peering connections has become unmanageable. Which solution simplifies this connectivity?
Choose one.
- AA full mesh of VPC peering connections with a separate VPN from each VPC
- BA shared NAT gateway in a central networking VPC for all accounts
- CAWS Transit Gateway associated with a Direct Connect gateway through a transit virtual interface
- DAWS PrivateLink endpoint services published from each VPC
Show answer
Answer: C
Transit Gateway is a regional hub that connects many VPCs and on-premises networks, replacing a peering mesh; a Direct Connect gateway with a transit VIF links it to the data center.
The correct answer is AWS Transit Gateway associated with a Direct Connect gateway through a transit virtual interface. Each VPC attaches once to the transit gateway, which can be shared across accounts with AWS Resource Access Manager, and transit gateway route tables control which networks can reach each other. Associating the transit gateway with a Direct Connect gateway over a transit VIF extends the same hub to the on-premises network. A full peering mesh needs 105 connections for 15 VPCs, and peering is non-transitive, so it cannot carry on-premises traffic. A NAT gateway provides outbound internet access and does not route traffic between VPCs. PrivateLink exposes individual services in one direction and does not provide full network connectivity.
Design High-Performing ArchitecturesQuestion 14
A team needs to monitor memory utilization and disk space usage on a fleet of Amazon EC2 instances and receive an alarm when either crosses a threshold. The default EC2 metrics in Amazon CloudWatch do not include this data. What should the team do?
Choose one.
- AEnable detailed monitoring to get 1-minute metric granularity
- BInstall the CloudWatch agent on each instance to publish memory and disk metrics
- CUse AWS Trusted Advisor checks for memory and disk alerts
- DRely on EC2 status checks to report OS-level memory and disk usage
Show answer
Answer: B
Default EC2 metrics are collected at the hypervisor level and do not include in-guest memory or disk usage; the CloudWatch agent collects these OS-level metrics and publishes them to CloudWatch, where alarms can be created.
The correct answer is Install the CloudWatch agent on each instance to publish memory and disk metrics. EC2 publishes metrics such as CPU utilization, network, and EBS I/O from the hypervisor, which cannot see memory or file-system usage inside the guest operating system. The CloudWatch agent runs inside the OS, collects metrics like mem_used_percent and disk_used_percent, and sends them to CloudWatch as custom metrics that support alarms. The agent can be deployed at scale with AWS Systems Manager. Detailed monitoring only increases the frequency of the existing metrics. Trusted Advisor provides account-level best-practice checks, not per-instance memory alarms. EC2 status checks verify instance and system reachability, not resource usage.
Design High-Performing ArchitecturesQuestion 15
A three-tier e-commerce application runs continuously, and its traffic changes dramatically by time of day, promotions, and holidays. Which strategies keep the web tier cost-effective and able to scale? (Select TWO.)
Choose two.
- AServe static assets from Amazon S3 through Amazon CloudFront
- BRun the EC2 web instances in an Auto Scaling group behind an Elastic Load Balancer
- CUse Amazon Route 53 multi-Region routing as the primary scaling mechanism
- DUse S3 multipart upload to scale web request processing
- EStore static web assets in Amazon Aurora
Show answer
Answer: A, B
CloudFront with S3 offloads static content from the web servers, and an Auto Scaling group behind a load balancer adjusts web capacity to match demand.
The correct answers are Serve static assets from Amazon S3 through Amazon CloudFront and Run the EC2 web instances in an Auto Scaling group behind an Elastic Load Balancer. Serving images, scripts, and stylesheets from S3 through CloudFront removes most requests from the web tier and caches content close to users, so fewer and smaller instances are needed. An Auto Scaling group behind a load balancer adds instances during promotions and holidays and removes them during quiet periods, so the company pays only for needed capacity. Route 53 routes DNS queries but does not add compute capacity. Multipart upload improves uploading large objects to S3, not web request handling. Aurora is a relational database and an expensive, inappropriate store for static files.
Design High-Performing ArchitecturesQuestion 16
A company wants to perform real-time sentiment analysis on a social media stream by using SQL, with minimal operational overhead. Which architecture should it use?
Choose one.
- ABuild custom ingestion and analysis applications on Amazon EC2 instances
- BIngest with Kinesis Data Streams and analyze with Amazon Managed Service for Apache Flink using SQL
- CLoad every event into Amazon Redshift and run batch SQL queries every hour
- DRun a persistent, self-managed Hadoop cluster on Amazon EC2
Show answer
Answer: B
Kinesis Data Streams provides scalable, managed ingestion, and Amazon Managed Service for Apache Flink runs continuous SQL queries on the stream without servers to manage.
The correct answer is Ingest with Kinesis Data Streams and analyze with Amazon Managed Service for Apache Flink using SQL. Kinesis Data Streams captures the social media events durably and scales with throughput. Amazon Managed Service for Apache Flink, the successor to Kinesis Data Analytics, runs Flink SQL applications or Studio notebooks that process records continuously, and it can call sentiment models or Amazon Comprehend through user-defined functions. AWS manages the infrastructure, scaling, and checkpointing. Custom applications on EC2 require building and operating the ingestion and processing layers. Hourly batch queries in Amazon Redshift are not real time. A self-managed Hadoop cluster is batch-oriented and has high operational overhead.
Design Cost-Optimized ArchitecturesQuestion 17
A team runs an Amazon RDS for MySQL DB instance only for a weekly 6-hour batch reconciliation job, but leaves the instance running 24/7 for the rest of the week. The instance class and performance must stay unchanged. Which approach reduces cost the most with the least operational effort?
Choose one.
- ADownsize the instance class between runs and resize it back before each job
- BStop the DB instance when the job finishes and start it again before the next run
- CTake a manual snapshot, delete the instance, and restore it from the snapshot before each run
- DPurchase a Reserved Instance for the DB instance and keep it running
Show answer
Answer: B
A stopped RDS DB instance incurs no instance-hour charges, only storage, and starting it again restores the same configuration with no resize or restore steps.
The correct answer is Stop the DB instance when the job finishes and start it again before the next run. While an RDS DB instance is stopped, you pay only for provisioned storage and backups, not instance hours, so the team pays compute for roughly 6 of 168 hours each week. Starting the instance brings back the same instance class, endpoint, and configuration. RDS automatically restarts a stopped instance after 7 days, which fits a weekly schedule, and the stop and start can be automated. Resizing between runs still pays for compute all week and causes downtime for each modification. Snapshot, delete, and restore saves a little more storage but changes the endpoint and adds a lengthy restore each week. A Reserved Instance only discounts an instance that still runs 24/7.
Design Cost-Optimized ArchitecturesQuestion 18
A company shares one AWS Direct Connect connection among separate AWS accounts that belong to its departments. The company needs data transfer charges to be allocated to the correct departments. What should it do?
Choose one.
- AOrder a separate physical Direct Connect connection for every department
- BCreate hosted virtual interfaces and have each department's account accept and own its VIF
- CTag the single physical connection with every department name
- DKeep all VIFs in the central networking account and split charges manually
Show answer
Answer: B
A hosted virtual interface created on the shared connection can be accepted and owned by a department's AWS account, so Direct Connect data transfer for that VIF is billed to that account.
The correct answer is Create hosted virtual interfaces and have each department's account accept and own its VIF. The connection owner can create a hosted VIF on the shared connection and assign it to another AWS account. Once the department account accepts it, the VIF belongs to that account, and data transfer out over that VIF is billed to the department, while the port-hour charges stay with the connection owner. Ordering a separate physical connection for each department multiplies port and cross-connect costs. A single tag on the connection cannot split usage among departments. Keeping all VIFs in the central account and dividing charges manually is error-prone and does not produce accurate per-department billing.
Design Cost-Optimized ArchitecturesQuestion 19
Production Amazon EC2 instances run continuously, while development and test instances run only about 8 hours per day and are stopped when not in use. Which purchasing strategy is most cost-effective?
Choose one.
- AUse Spot Instances for every environment
- BUse On-Demand Instances for every environment
- CUse Reserved Instances for production and On-Demand Instances for development and test
- DUse Reserved Instances for development and test and Spot Instances for production
Show answer
Answer: C
Reserved Instances (or Savings Plans) give the largest discount for steady 24/7 production usage, and On-Demand pricing avoids paying for commitments that intermittent development and test instances would leave unused.
The correct answer is Use Reserved Instances for production and On-Demand Instances for development and test. Production runs every hour of the year, so a 1-year or 3-year Reserved Instance or Savings Plan commitment is fully used and saves up to about 72 percent compared with On-Demand. Development and test instances run only about a third of the day, so a commitment billed for every hour would cost more than paying On-Demand rates only while they run. Spot Instances can be interrupted with two minutes' notice, which is unacceptable for production. Using On-Demand for everything gives up the large production discount. Reserving the development and test capacity wastes the commitment during the hours those instances are stopped.
Design Cost-Optimized ArchitecturesQuestion 20
A company continuously runs critical and non-critical Docker batch jobs and wants to reduce cost without risking the availability of the critical jobs. Which architecture is best?
Choose one.
- ARun all jobs on Amazon ECS using only Reserved Instance capacity
- BRun all jobs on Amazon ECS using only Spot Instance capacity
- CUse Amazon ECS with Reserved capacity for critical jobs and Spot capacity for non-critical jobs
- DUse Amazon ECS with Spot capacity for critical jobs and Reserved capacity for non-critical jobs
Show answer
Answer: C
Reserved capacity gives critical jobs a stable, discounted baseline, and interruption-tolerant non-critical jobs can run on Spot capacity at up to 90 percent off On-Demand prices.
The correct answer is Use Amazon ECS with Reserved capacity for critical jobs and Spot capacity for non-critical jobs. Because the jobs run continuously, Reserved Instances or Savings Plans give a steady discount on the capacity that the critical jobs depend on and cannot be interrupted. Non-critical jobs tolerate interruptions, so they can use ECS capacity providers backed by Spot Instances, which cost much less and are replaced automatically when reclaimed. Using only Reserved capacity misses the deeper Spot savings for work that can be interrupted. Using only Spot puts critical jobs at risk of interruption. Placing critical jobs on Spot and non-critical jobs on Reserved capacity reverses the logic and risks the critical workload.
Ready for more?
Practice the full SAA-C03 question set one at a time, weighted like the real exam, with every answer explained.