Spring Sale Limited Time 70% Discount Offer - Ends in 0d 00h 00m 00s - Coupon code: simple70

Pass the Amazon Web Services AWS Certified Associate DVA-C02 Questions and answers with CertsForce

Viewing page 1 out of 11 pages
Viewing questions 1-15 out of questions
Questions # 1:

A company runs an application in a third-party cloud. The company wants to use the application to update data in AWS by using API calls to AWS services. The API calls require credentials.

The company's security policy requires the company to limit the scope and duration of any credentials used to make API calls to AWS services.

Which solution will meet these requirements in the MOST secure way?

Options:

A.

Create an IAM user for the application. Configure the application to load the IAM user's credentials as environment variables. Use the IAM user's credentials to interact with AWS services.


B.

Create an IAM user for the application. Populate an AWS Secrets Manager secret with the IAM user's AWS credentials. Use the secret to interact with AWS services.


C.

Create an IAM role for the application. Configure the application to call the AWS STS GetFederationToken API. Use the STS credentials to interact with AWS services.


D.

Create an IAM role for the application. Configure the application to call the AWS STS AssumeRole API. Use the STS credentials to interact with AWS services.


Expert Solution
Questions # 2:

A developer is building a serverless application that uses asynchronous AWS Lambda functions. The developer needs a solution to capture records of every Lambda function invocation. Each function must have multiple destinations based on whether each invocation is successful. The solution must record function responses in JSON format.

Which solution will meet these requirements?

Options:

A.

Amazon CloudWatch Logs log groups that use the default log format for Lambda functions. Route each invocation to the appropriate log group by using a Lambda canary deployment and weighted aliases. Set the appropriate log group as the target for each function.


B.

Set up an S3 bucket as an on-failure destination for the Lambda function. Configure an Amazon SNS topic as the destination for successful Lambda function invocations.


C.

Configure an Amazon SQS dead-letter queue as an event source for the Lambda function to store failed invocations. In the Lambda function code, use the PutItem Amazon DynamoDB API call to add the successful invocation information to the database.


D.

Set up an Amazon SQS queue as an on-failure destination for the Lambda function. Configure an Amazon OpenSearch Service cluster as the destination for the Lambda function for successful invocations.


Expert Solution
Questions # 3:

A developer maintains a legacy ecommerce application that sends logs to an Amazon CloudWatch Logs log group. During an audit, the developer discovers that the application sends credit card numbers and credit card verification codes to the log group.

The developer needs a solution to give support staff the ability to view the logs. However, the support staff must not be able to view the sensitive credit card information. Application administrators must be able to view the logs and must have access to the sensitive credit card data. The developer cannot modify the application code.

Which solution will meet these requirements?

Options:

A.

Enable a data protection policy on the log group. Specify the sensitive credit card data to mask. Assign the logs:Unmask IAM permission to the application administrators.


B.

Create an AWS KMS key and associate it with the log group. Assign the kms:Decrypt permission to application administrators.


C.

Create an AWS Lambda function to redact the sensitive credit card information. Configure Amazon Macie to scan the log group for sensitive information and to run the Lambda function.


D.

Configure a WAF for the application. Create a WAF rule to inspect and sanitize log data before it reaches CloudWatch.


Expert Solution
Questions # 4:

An ecommerce company is planning to migrate an on-premises Microsoft SQL Server database to the AWS Cloud. The company needs to migrate the database to SQL Server Always On availability groups. The cloud-based solution must be highly available.

Which solution will meet these requirements?

Options:

A.

Deploy three Amazon EC2 instances with SQL Server across three Availability Zones. Attach one Amazon Elastic Block Store (Amazon EBS) volume to the EC2 instances.


B.

Migrate the database to Amazon RDS for SQL Server. Configure a Multi-AZ deployment and read replicas.


C.

Deploy three Amazon EC2 instances with SQL Server across three Availability Zones. Use Amazon FSx for Windows File Server as the storage tier.


D.

Deploy three Amazon EC2 instances with SQL Server across three Availability Zones. Use Amazon S3 as the storage tier.


Expert Solution
Questions # 5:

A developer has observed an increase in bugs in the AWS Lambda functions that a development team has deployed in its Node.js application.

To minimize these bugs, the developer wants to implement automated testing of Lambda functions in an environment that closely simulates the Lambda environment.

The developer needs to give other developers the ability to run the tests locally. The developer also needs to integrate the tests into the team's continuous integration and continuous delivery (CI/CD) pipeline before the AWS Cloud Development Kit (AWS CDK) deployment.

Which solution will meet these requirements?

Options:

A.

Create sample events based on the Lambda documentation. Create automated test scripts that use the cdk local invoke command to invoke the Lambda functions. Check the response. Document the test scripts for the other developers on the team. Update the CI/CD pipeline to run the test scripts.


B.

Install a unit testing framework that reproduces the Lambda execution environment. Create sample events based on the Lambda documentation. Invoke the handler function by using a unit testing framework. Check the response. Document how to run the unit testing framework for the other developers on the team. Update the CI/CD pipeline to run the unit testing framework.


C.

Install the AWS Serverless Application Model (AWS SAM) CLI tool. Use the sam local generate-event command to generate sample events for the automated tests. Create automated test scripts that use the sam local invoke command to invoke the Lambda functions. Check the response. Document the test scripts for the other developers on the team. Update the CI/CD pipeline to run the test scripts.


D.

Create sample events based on the Lambda documentation. Create a Docker container from the Node.js base image to invoke the Lambda functions. Check the response. Document how to run the Docker container for the other developers on the team. Update the CllCD pipeline to run the Docker container.


Expert Solution
Questions # 6:

A developer is setting up infrastructure by using AWS Cloud Formation. If an error occurs when the resources described in the CloudFormation template are provisioned, successfully provisioned resources must be preserved. The developer must provision and update the CloudFormation stack by using the AWS CLI.

Which solution will meet these requirements?

Options:

A.

Add an --enable-terminal ion-protection command line option to the create-stack command and the update-stack command.


B.

Add a -disable-roll back command line option to the create-stack command and the update-stack command


C.

Add a —parameters ParameterKey=P reserve Resources. ParameterVaIue=True command line option to the create-stack command and the update-stack command.


D.

Add a -tags Key=PreserveResources.VaIue=True command line option to the create-stack command and the update-stack command.


Expert Solution
Questions # 7:

A company requires that all applications running on Amazon EC2 use 1AM roles to gam access to AWS services. A developer is modifying an application that currently relies on 1AM user access keys stored in environment variables to access Amazon DynamoDB tables using boto, the AWS SDK for Python.

The developer associated a role with the same permissions as the 1AM user to the EC2 instance, then deleted the 1AM user. When the application was restarted, the AWS

Access Denied Exception messages started appearing in the application logs. The developer was able to use their personal account on the server to run DynamoDB API commands using the AWS CLI.

What is the MOST likely cause of the exception?

Options:

A.

1AM policies might take a few minutes to propagate to resources.


B.

Disabled environment variable credentials are still being used by the application.


C.

The AWS SDK does not support credentials obtained using an instance role.


D.

The instance's security group does not allow access to http://169.254.169.254.


Expert Solution
Questions # 8:

A developer is designing a full-stack serverless application. Files for the website are stored in an Amazon S3 bucket. AWS Lambda functions that use Amazon API Gateway endpoints return results from an Amazon DynamoDB table.

The developer must create a solution that securely provides registration and authentication for the application while minimizing the amount of configuration.

Which solution meets these requirements?

Options:

A.

Create an Amazon Cognito user pool and an app client. Configure the app client to use the user pool and provide the hosted web UI provided for sign-up and sign-in.


B.

Configure an Amazon Cognito identity pool. Map the users with IAM roles that are configured to access the S3 bucket that stores the website.


C.

Configure and launch an Amazon EC2 instance to set up an identity provider with an Amazon Cognito user pool. Configure the user pool to provide the hosted web UI for sign-up and sign-in.


D.

Create an IAM policy that allows access to the website that is stored in the S3 bucket. Attach the policy to an IAM group. Add IAM users to the group.


Expert Solution
Questions # 9:

A company hosts its application in the us-west-1 Region. The company wants to add redundancy in the us-east-1 Region. The application secrets are stored in AWS Secrets Manager in us-west-1. A developer needs to replicate the secrets to us-east-1.

Which solution will meet this requirement?

Options:

A.

Configure secret replication for each secret. Add us-east-1 as a replication Region. Choose an AWS KMS key in us-east-1 to encrypt the replicated secrets.


B.

Create a new secret in us-east-1 for each secret. Configure secret replication in us-east-1. Set the source to be the corresponding secret in us-west-1. Choose an AWS KMS key in us-west-1 to encrypt the replicated secrets.


C.

Create a replication rule for each secret. Set us-east-1 as the destination Region. Configure the rule to run during secret rotation. Choose an AWS KMS key in us-east-1 to encrypt the replicated secrets.


D.

Create a Secrets Manager lifecycle rule to replicate each secret to a new Amazon S3 bucket in us-west-1. Configure an S3 replication rule to replicate the secrets to us-east-1.


Expert Solution
Questions # 10:

A company is building a micro services app1 cation that consists of many AWS Lambda functions. The development team wants to use AWS Serverless Application Model (AWS SAM) templates to automatically test the Lambda functions. The development team plans to test a small percentage of traffic that is directed to new updates before the team commits to a full deployment of the application.

Which combination of steps will meet these requirements in the MOST operationally efficient way? (Select TWO.)

Options:

A.

Use AWS SAM CLI commands in AWS CodeDeploy lo invoke the Lambda functions to lest the deployment


B.

Declare the EventlnvokeConfig on the Lambda functions in the AWS SAM templates with OnSuccess and OnFailure configurations.


C.

Enable gradual deployments through AWS SAM templates.


D.

Set the deployment preference type to Canary10Percen130Minutes Use hooks to test the deployment.


E.

Set the deployment preference type to Linear10PefcentEvery10Minutes Use hooks to test the deployment.


Expert Solution
Questions # 11:

A developer received the following error message during an AWS CloudFormation deployment:

Which action should the developer take to resolve this error?

Options:

A.

Contact AWS Support to report an issue with the Auto Scaling Groups (ASG> service.


B.

Add a DependsOn attribute to the ASGInstanceRole12345678 resource in the CloudFormation template. Then delete the stack.


C.

Modify the CloudFormation template to retain the ASGInstanceRolet 2345678 resource. Then manually delete the resource after deployment.


D.

Add a force parameter when calling CloudFormation with the role-am of ASGInstanceRole12345678.


Expert Solution
Questions # 12:

A company notices that credentials that the company uses to connect to an external software as a service (SaaS) vendor are stored in a configuration file as plaintext.

The developer needs to secure the API credentials and enforce automatic credentials rotation on a quarterly basis.

Which solution will meet these requirements MOST securely?

Options:

A.

Use AWS Key Management Service (AWS KMS) to encrypt the configuration file. Decrypt the configuration file when users make API calls to the SaaS vendor. Enable rotation.


B.

Retrieve temporary credentials from AWS Security Token Service (AWS STS) every 15 minutes. Use the temporary credentials when users make API calls to the SaaS vendor.


C.

Store the credentials in AWS Secrets Manager and enable rotation. Configure the API to have Secrets Manager access.


D.

Store the credentials in AWS Systems Manager Parameter Store and enable rotation. Retrieve the credentials when users make API calls to the SaaS vendor.


Expert Solution
Questions # 13:

A company is using Amazon OpenSearch Service to implement an audit monitoring system. A developer needs to create an AWS Cloudformation custom resource that is associated with an AWS Lambda function to configure the OpenSearch Service domain. The Lambda function must access the OpenSearch Service domain by using Open Search Service internal master user credentials.

What is the MOST secure way to pass these credentials to the Lambdas function?

Options:

A.

Use a CloudFormation parameter to pass the master user credentials at deployment to the OpenSearch Service domain's MasterUserOptions and the Lambda function's environment variable. Set the No Echo attenuate to true.


B.

Use a CloudFormation parameter to pass the master user credentials at deployment to the OpenSearch Service domain's MasterUserOptions and to create a parameter. In AWS Systems Manager Parameter Store. Set the No Echo attribute to true. Create an 1AM role that has the ssm GetParameter permission. Assign me role to the Lambda function. Store me parameter name as the Lambda function's environment variable. Resolve the parameter's value at runt


C.

Use a CloudFormation parameter to pass the master uses credentials at deployment to the OpenSearch Service domain's MasterUserOptions and the Lambda function's environment varleWe Encrypt the parameters value by using the AWS Key Management Service (AWS KMS) encrypt command.


D.

Use CloudFoimalion to create an AWS Secrets Manager Secret. Use a CloudFormation dynamic reference to retrieve the secret's value for the OpenSearch Service domain's MasterUserOptions. Create an 1AM role that has the secrets manager. GetSecretvalue permission. Assign the role to the Lambda Function Store the secrets name as the Lambda function's environment variable. Resole the secret's value at runtime.


Expert Solution
Questions # 14:

A developer is testing an AWS Lambda function by using the AWS SAM local CLI. The application that is implemented by the Lambda function makes several AWS API calls by using the AWS SDK. The developer wants to allow the function to make AWS API calls in a test AWS account from the developer’s laptop.

What should the developer do to meet these requirements?

Options:

A.

Edit the template.yml file. Add the AWS_ACCESS_KEY_ID property and the AWS_SECRET_ACCESS_KEY property in the Globals section.


B.

Add a test profile by using the aws configure command with the --profile option. Run AWS SAM by using sam local invoke with the --profile option.


C.

Edit the template.yml file. For the AWS::Serverless::Function resource, set the role to an IAM role in the AWS account.


D.

Run the function by using sam local invoke. Override the AWS_ACCESS_KEY_ID parameter and the AWS_SECRET_ACCESS_KEY parameter by specifying the --parameter-overrides option.


Expert Solution
Questions # 15:

A developer works for a company that only has a single pre-production AWS account with an AWS CloudFormation AWS SAM stack. The developer made changes to an existing AWS Lambda function specified in the AWS SAM template and additional Amazon SNS topics.

The developer wants to do a one-time deployment of the changes to test if the changes are working. The developer does not want to impact the existing pre-production application that is currently being used by other team members as part of the release pipeline.

Which solution will meet these requirements?

Options:

A.

Use the AWS SAM CLI to package and deploy the SAM application to the pre-production AWS account. Specify the debug parameter.


B.

Use the AWS SAM CLI to package and create a change set against the pre-production AWS account. Execute the change set in a new AWS account designated for a development environment.


C.

Use the AWS SAM CLI to package and deploy the SAM application to a new AWS account designated for a development environment.


D.

Update the CloudFormation stack in the pre-production account. Add a separate stage that points to a new AWS account designated for a development environment.


Expert Solution
Viewing page 1 out of 11 pages
Viewing questions 1-15 out of questions