ALICEWHO?ALLOWED?PHOTOSAPP SERVERPAYROLL1{"Version": "2012-10-17",2 "Statement": [3 {"Effect": "Allow",4 "Action": "s3:GetObject",5 "Resource": "arn:aws:s3:::photos/*"},6 {"Effect": "Deny",7 "Action": "s3:DeleteObject",8 "Resource": "*"}]}
Back: who asks (Alice, the app), the two checks, the two bucketsFront: Alice's policy, a JSON documentTokens: a request (green allowed, red denied) and a key (credentials)Every request to a cloud service passes two checks: who is asking (authentication), then whether a policy allows this action on this resource (authorization). Alice's policy allows reading anything in the photos bucket and denies deleting anything. Her three requests come out allowed, explicitly denied and denied by default. The app server uses a role with temporary credentials instead of a stored password. The figure follows AWS IAM, simplified. Real evaluation also weighs resource-based policies, permissions boundaries, session policies and organization-wide controls, and statements can add Conditions. The rule "explicit deny wins, else an allow, else deny" still holds.

The idea

  1. In the cloud, every request, such as "read this file", is checked. Identity and access management (IAM) asks two questions: who is asking (authentication), and are they allowed to do this (authorization)?

Who: authentication

What: authorization

Good habits

What happens

;; step 1/11 · iam
every request to a cloud service is checked

  1. authentication  who is asking?
  2. authorization   may they do this, to that?

IAM = identity and access management

The figure follows AWS IAM, simplified. Real evaluation also weighs resource-based policies, permissions boundaries, session policies and organization-wide controls, and statements can add Conditions. The rule "explicit deny wins, else an allow, else deny" still holds. The policy card is valid JSON and also a valid Python dict. The Python rule uses fnmatchcase for the * wildcard; real IAM matches action names without regard to case and does not use fnmatch.