Flashcards from AWS Course
What is AWS Serverless Application Model (AWS SAM)?
A framework for building serverless applications in AWS.
How do you share AWS CloudFormation templates across multiple AWS accounts?
Use CloudFormation StackSets.
Where do you store files for an AWS Lambda function that needs temporary storage during execution?
/tmp directory.
In Amazon Elastic Container Server (Amazon ECS), where are port mappings located and where are they configured?
Port mappings are part of the container definition and are configured in the task definition.
What is the unit of scale for Lambda?
Concurrent executions.
What condition keys would you use to limit the execution of a Lambda function to a particular Amazon VPC?
lambda:VpcIds – Allow or deny one or more VPCs.
lambda:SubnetIds – Allow or deny one or more subnets.
lambda:SecurityGroupIds – Allow or deny one or more security groups.
Global secondary index queries support what type of consistency?
Eventual consistency only.
What are best practices for partition keys in Amazon DynamoDB?
Use high-cardinality attributes which are attributes that have distinct values for each item.
Use composite attributes to combine more than one attribute to form a unique key.
Cache the popular items when there is a high volume of read traffic using Amazon DynamoDB Accelerator (DAX).
Add random numbers or digits from a predetermined range for write-heavy use cases.
How do you ensure that your applications cannot retrieve a message from an Amazon Simple Queue Service (Amazon SQS) queue that is being processed or has already been processed?
Increase the VisibilityTimeout value from the ChangeMessageVisibility API and delete the message using the DeleteMessage API.
What API call do you use to give the ability to the application so that it can use an IAM role?
AssumeRole API.
What do you use to authenticate users for a website using identity profiles?
Amazon Cognito identity pools.
What is a role-based access control (RBAC) models?
It is the traditional authorization model used in IAM and it defines the permissions based on a user’s job.
What is an attribute-based access control (ABAC) model?
An authorization model that defines permissions based on attributes or tags.
What are the AWS Directory Services and when are they used?
Simple AD is compatible with basic Active Directory functions and can handle 500 users to 5000 users. Simple AD is for simple requirements.
AWS Managed Microsoft AD is an actual Microsoft Active Directory service. You can create a trust relationship with your on premises directory.
AD Connector provides proxy requests back to an on premises directory. It is great for proxy identities to integrate with AWS services when you do not want to store any directory information in the cloud.
What are the three types of identity federation?
Cross account role: When a remote account, so a remote identity provider (IdP), is allowed to assume a role and access your account resources. Look further into AssumeRole and cross-account access as well as AssumeRoleWithSAML and AssumeRoleWithWebIdentity.
SAML 2.0: A standard that is used mostly for on premises, for example, Microsoft Active Directory or others. Users can log in to AWS with their on premises credentials.
Web identity federation: When you use IdPs (for example, Amazon, Google, and Facebook) to allow users to assume roles and access your AWS resources using their IdP credentials.
What are the differences between STS Get Tokens, GetFederationToken, and GetSessionToken and when you would use each?
GetFederationToken could be used in a proxy application that gets temporary security credentials for a distributed application in a corporate network.
GetSessionToken could be used if you want to use multi-factor authentication to protect programmatic calls to specific AWS API operations.
You can also use roles to delegate access to not only users and services, but also applications that do not have access to your AWS resources (for example, access to resources or services that a user does not usually have access to or to grant access for users in a different AWS account).
What are the two types of Lambda authorizers used with Amazon API Gateway?
Lambda authorizer and REQUEST authorizer.
A token-based Lambda authorizer is the answer for this scenario because a TOKEN authorizer receives the caller’s identity in a bearer token, such as a JSON Web Token (JWT) or an OAuth token.
A request parameter-based Lambda authorizer, also known as REQUEST authorizer, receives the caller’s identity in a combination of headers, query string parameters, StageVariables, and $context variables.
What are Amazon Cognito user pools and identity pools?
User pools are user directories that provide sign-up or sign-in for users and authenticate a user to obtain tokens related to user identity and access policies.
Identity pools help to grant temporary and limited credentials for your users to access AWS services and resources and federate them with identity providers.
What additional protection does tokenization provide?
Tokenization adds additional protection for your data and can help to meet compliance requirements.