DVA-C03 · LESSON 2
Security26% · 3 topics
Obtain credentials through roles and retrieve secrets from managed storage. Model output is not authorization: enforce tool access server-side. Isolate conversations and caches by user, and redact sensitive inputs and logs as required.
2.1Protect application and AI authorization boundaries
Concept
Obtain credentials through roles and retrieve secrets from managed storage. Model output is not authorization: enforce tool access server-side. Isolate conversations and caches by user, and redact sensitive inputs and logs as required.
How it works / steps
- Write requirements and success criteria first.
- Use a test environment and retain success and failure evidence.
- Review the result, then check your decisions with domain practice below.
Workplace example
Test rejection of another user’s session ID and an unauthorized tool request.
Common confusions and exam tips
- Mock accuracy does not convert to official scaled scores. Check current service behavior in official documentation.
Mini quiz
Q1. You are publishing an internal API with API Gateway. Only apps with internal IAM roles should be able to call it. Which authorization method is most appropriate?
- Keep the API public and tell users the API URL is confidential
- Put a NAT gateway in front of API Gateway to restrict sources
- Enable IAM authorization on the methods and allow the callers' roles to invoke them
- Issue API keys, embed them in each app, and identify callers only by matching the API key
Show answer and explanation
Answer: C Enable IAM authorization on the methods and allow the callers' roles to invoke them
IAM authorization evaluates SigV4-signed requests against IAM policies. API keys are for managing usage plans and are not sufficient as an authentication mechanism.
Q2. You want to limit who can use an encryption key. Which setting in the KMS key policy is most appropriate?
- Grant both key administration and usage permissions to all principals, including outside the account
- Allow kms:* to all IAM users and control who uses it in the app
- Leave the key policy empty so only the root user can use the key
- Separate key administrators from the roles that encrypt and decrypt, and allow each only the actions they need
Show answer and explanation
Answer: D Separate key administrators from the roles that encrypt and decrypt, and allow each only the actions they need
Separating key administration (policy changes, scheduling deletion) from key usage (Encrypt/Decrypt) in the key policy achieves separation of duties and least privilege.
Reference links
2.2Design secure access to AWS resources
Concept
The core of access design is IAM policy evaluation. An explicit deny always wins, and without an allow the result is an implicit deny. Across multiple accounts, AWS Organizations SCPs (service control policies) set the maximum permissions available in an account, and IAM Identity Center centralizes human access. Access to another account uses IAM role assumption (AssumeRole) and resource-based policies.
How it works / steps
- Federate human access through IAM Identity Center and an external IdP (SAML, OIDC)
- Use IAM roles for workloads and avoid long-term access keys
- Set organization-wide prohibitions with SCPs (Region restrictions, no disabling of logging and so on)
- Use roles with trust policies for cross-account access
- Detect externally shared resources with Access Analyzer
Workplace example
Staff in the audit account assume a read-only role in the production account with AssumeRole to investigate, and an SCP prevents CloudTrail from being stopped in every account.
Common confusions and exam tips
- SCPs do not “grant” permissions; they only set the maximum (IAM must also allow)
- An explicit Deny takes precedence over any Allow
- The root user is affected by SCPs (except in the management account)
Mini quiz
Q1. Which statement about IAM policy evaluation is correct?
- Even if an identity policy allows access, the request is denied if any policy contains an explicit deny
- When an identity policy and a resource policy conflict, the policy created later always takes precedence
- Operations allowed by an SCP become possible even if no IAM policy allows them
- Operations not mentioned in any policy are allowed by default within the same account
Show answer and explanation
Answer: A Even if an identity policy allows access, the request is denied if any policy contains an explicit deny
In IAM, an explicit deny takes top priority, and anything not allowed anywhere is implicitly denied. SCPs only set the maximum permissions; they do not grant permissions themselves.
Q2. Mobile app users upload photos directly to their own folder in S3. What is the most appropriate approach that avoids embedding AWS credentials in the app?
- Issue scoped-down temporary credentials with a Cognito identity pool
- Encrypt the root user credentials and store them in the app
- Embed a shared IAM user's access key in the app and have all users share it
- Make the S3 bucket public so anyone can write to it
Show answer and explanation
Answer: A Issue scoped-down temporary credentials with a Cognito identity pool
Cognito identity pools issue temporary credentials based on an IAM role to authenticated users. Policy variables can limit writes to the user's own prefix.
Reference links
2.3Determine appropriate data security controls
Concept
Data protection uses encryption at rest (AWS KMS: AWS managed keys and customer managed keys), encryption in transit (TLS with ACM certificates), access control (bucket policies, S3 Block Public Access), and backup and retention (AWS Backup, S3 Versioning, S3 Object Lock). Separate key users from key administrators and control them with key policies.
How it works / steps
- Decide data classifications (confidential, internal, public)
- Enable S3 Block Public Access and set default encryption
- Use customer managed keys (with automatic rotation) when auditing or key management is required
- Put records that must not be tampered with under S3 Object Lock (compliance mode)
- Check where sensitive data lives with Macie
Workplace example
Financial transaction records are stored for 7 years unchangeable with S3 Object Lock, encrypted with a customer managed key, and key use is audited in CloudTrail.
Common confusions and exam tips
- SSE-S3 is easy; SSE-KMS allows auditing of key use and separation of permissions
- Object Lock compliance mode cannot be deleted even by the root user (governance mode can be lifted with permission)
- RDS encryption is set at creation (for an existing DB, encrypt a snapshot and restore)
Mini quiz
Q1. Which is a correct characteristic of resource-based policies such as S3 bucket policies?
- When a resource-based policy is used, all IAM identity policies in the same account are always ignored
- They are attached to an IAM user to specify every service that user can use
- Like SCPs, they set organization-wide maximums and cannot grant permissions
- They are attached to a resource and specify which principals (including other accounts) can do what
Show answer and explanation
Answer: D They are attached to a resource and specify which principals (including other accounts) can do what
Resource-based policies are attached to resources and use the Principal element to specify who is allowed. They can be used for cross-account access.
Q2. You are designing access from another AWS account. Staff in the audit account need to temporarily review CloudTrail, Config, EC2 and other resources in the production account. Which is the most appropriate approach?
- Allow the operations for the other account with an SCP
- Create IAM users in your own account for the other party's staff and hand them out
- Allow read access to the other account's principals in an S3 bucket policy
- Create an IAM role in the target account and allow the other party to AssumeRole
Show answer and explanation
Answer: D Create an IAM role in the target account and allow the other party to AssumeRole
Assuming a role in the target account lets them use that role's permissions with temporary STS credentials. No long-term credentials need to be handed out.
Reference links
Lessons are written by this site based on public information and do not guarantee exam content. Product specifications change, so check the latest information at the reference links.
Notes (unofficial, original questions, no pass guarantee)
- The questions on this site are original practice questions written by this site based on publicly available skills outlines and exam guides. They are not actual exam questions.
- Amazon Web Services, AWS and related marks are trademarks of Amazon.com, Inc. or its affiliates. This site is not affiliated with or endorsed by AWS.
- This content is a study aid and does not guarantee a pass. Exam content, format and prerequisites may change without notice; always check the latest information on the official page before taking the exam.
- Your accuracy on the mock exam cannot be converted to the official (scaled) score and does not predict a pass or fail.
- Progress is saved only in this browser (localStorage) unless you sign in with Google to sync it. You can delete it from the Cookie & storage settings page (Japanese).