Everyday Guidebooks
Cover of Cloud Developer Associate

Cybersecurity & IT

Cloud Developer Associate: Secure Application Identity

An Unofficial Case-Based Study Guide to Roles, Temporary Credentials, Permission Policies, and Secrets

by Todd Michael

Available now

A cloud application needs to read a database secret—but which identity does it use, where do its credentials come from, and what permissions actually allow the request?

Cloud Developer Associate: Secure Application Identity turns those questions into short, approachable code-reading and configuration cases. Designed for readers searching for aws certified developer associate preparation, this focused guide explores application roles, temporary credentials, permission policies, and secret handling through practical decisions developers encounter in cloud applications.

Trace a request from application code to an authorization decision, compare policy statements, diagnose access failures, and examine safer ways to retrieve and use secrets. Original practice questions include explanations of both correct and incorrect choices, helping you understand the reasoning behind each answer.

This independent guide is a focused supplement, not a complete exam-preparation course. It contains no real exam questions and is not affiliated with or endorsed by AWS.

Contents
  1. 1. Follow the Application Identity
  2. 2. Roles and Trust Relationships
  3. 3. Temporary Credentials in Application Code
  4. 4. Finding Credentials in Developer Environments
  5. 5. Workload Roles in Cloud Environments
  6. 6. Reading Permission Policies
  7. 7. How Authorization Decisions Are Made
  8. Start with the request
  9. The default and the override
  10. Identity policies and resource policies
  11. Permission boundaries: the permitted range
  12. Organization-level controls
  13. A practical evaluation sequence
  14. Practice questions
  15. 8. Designing Least-Privilege Permissions
  16. Start with the Application’s Operations
  17. Match the Action to the Resource Type
  18. Conditions Refine a Grant
  19. Compare Policies That All Seem Reasonable
  20. Case: Separate the Reader from the Writer
  21. Resource Scoping Has Limits
  22. Case: A Queue Consumer
  23. Least Privilege and Effective Access
  24. Validate with Positive and Negative Cases
  25. A Practical Refinement Loop
  26. 9. Role Assumption and Cross-Account Access
  27. 10. Secret Storage and Retrieval
  28. 11. Secret Handling Throughout the Application
  29. 12. Diagnosing Access Failures
  30. Build a Request Record
  31. Case 1: The Policy Is Attached to the Wrong Identity
  32. Case 2: The Action Is Right, but the Resource Is Not
  33. Case 3: An Allow Exists Alongside an Explicit Deny
  34. Case 4: The Role Was Assumed, but the Session Is Narrower
  35. Case 5: The Secret Permission Is Not the Whole Path
  36. Case 6: Credentials Worked Yesterday
  37. Case 7: The Boundary Limits an Apparent Allow
  38. Use Diagnostic Tools as Evidence
  39. A Compact Troubleshooting Pass
  40. 13. Integrated Application Identity Cases

Read a sample: 1. Follow the Application Identity

A developer deploys a small application that reads invoices from an Amazon S3 bucket. The code worked on a laptop. In the cloud, the same request returns an access-denied error.

The natural impulse is to open the bucket policy or add a broad permission to the application’s role. Neither step is a good starting point. Before changing permissions, the developer needs to know who actually made the request, which credentials the application used, what action it attempted, and which resource it addressed.

Those questions form the central habit of this book: follow the application identity from code to authorization.

An application can make an AWS request without containing an access key in its source code. It can also make a request under an identity different from the one its developer expected. Understanding the difference requires more than recognizing an IAM policy. It requires tracing the request through the environment in which the code runs.

This chapter introduces that trace. Later chapters examine each part in more depth, from role trust and credential providers to permission policies, secret retrieval, and access-denied troubleshooting.

Consider a Python application using Boto3, the AWS SDK for Python:

python import boto3

s3 = boto3.client("s3") response = s3.getobject( Bucket="example-invoice-archive", Key="2025/january.csv", )

The code names an AWS service, an operation, a bucket, and an object key. It does not visibly name an IAM user or role. It also does not visibly include credentials.

Yet the request needs an authenticated identity and authorization. The SDK obtains credentials from a source available to the process and uses them to sign the request. AWS evaluates the resulting request against the applicable authorization controls.

A useful first-pass trace has five steps:

1. Operation: What does the code ask AWS to do? 2. Resource: Which specific resource does the request address? 3. Credential source: Where does the running process obtain credentials? 4. Effective identity: Which principal or role session do those credentials represent? 5. Authorization: Do the applicable policies and other controls permit this request?

For the example, the operation is GetObject, the resource is the object named 2025/january.csv in the bucket example-invoice-archive, and the relevant IAM action is s3:GetObject. The snippet alone does not establish the credential source, effective identity, or final authorization decision.

That last distinction matters. Code tells you what the application requests; it does not necessarily tell you who the application is when the request reaches AWS.

The object’s Amazon Resource Name, or ARN, is:

text arn:aws:s3:::example-invoice-archive/2025/january.csv

The corresponding bucket ARN is different:

text arn:aws:s3:::example-invoice-archive

An object operation and a bucket-level operation can require different actions and resource ARNs. Reading only the service name—“this application uses S3”—is not specific enough to assess access.

The developer who wrote the S3 code might sign in to the AWS Management Console using a human identity. The developer might also run the application locally with credentials from a configured profile. After deployment, the application can run using a role associated with its workload.

These are related activities, but they are not necessarily the same identity.

Imagine that Maya, a developer, can read the invoice object from her laptop. The deployed application cannot. Maya’s successful request shows that the credentials used on her laptop were authorized for that request at that time. It does not prove that the deployed workload uses those credentials or has equivalent permissions.

Likewise, a user signing in to an application is not automatically the AWS principal making the application’s service calls. A customer might authenticate to a web application, and the application might then use its own workload identity to call S3. The application remains responsible for deciding what that customer is allowed to request; AWS evaluates the service call under the AWS credentials used to sign it.

Some designs deliberately obtain distinct AWS credentials for different users or sessions. Do not assume that design merely because the application has a login screen. Follow the credentials used for the AWS request in the case you are reading.

This separation helps prevent a common reasoning error: assigning the permissions of a person to the process they built. A workload needs an appropriate identity and permissions of its own.

An IAM role is an identity with permissions, but an application does not put the role itself into an HTTP request. The application uses credentials associated with a role session. Temporary AWS credentials include an access key ID, a secret access key, and a session token. They expire and must be replaced when needed.

For many AWS-hosted workloads, the SDK can obtain and refresh temporary credentials supplied through the runtime environment. The application can then create a service client without embedding the credential values in its code. Exactly how credentials are delivered depends on the compute service and configuration.

A role therefore answers a different question from the credentials:

- The role defines an identity that can be assumed and has associated permissions. - The temporary credentials let a particular session make signed requests. - The SDK credential provider is the mechanism the application uses to find usable credentials. - The authorization decision determines whether a particular signed request is allowed.

Having credentials does not imply permission to perform every action. Conversely, attaching a suitable permission to a role does not help a process that is actually using credentials for a different identity.

These distinctions will recur throughout the book. Chapter 2 focuses on who can assume a role; Chapter 3 follows…

More Cybersecurity & IT

Cover of The White Hat Bible, Volume 1The White Hat Bible, Volume 1Available nowCover of The White Hat Bible, Volume 2The White Hat Bible, Volume 2Available nowCover of The White Hat Bible, Volume 3The White Hat Bible, Volume 3Available nowCover of The White Hat Bible, Volume 4The White Hat Bible, Volume 4Available nowThe White Hat Bible, Volume 5Available nowCover of The White Hat Pocket GuideThe White Hat Pocket GuideAvailable now

About Todd Michael

Todd Michael is an American author and the founder of ToddMichael.tv. He writes practical, plain-English books on money, health, preparedness, technology, games, humor and more.

About the author Todd Michael · Todd Michael’s author site

Part of the ToddMichael.tv network.