exam questions

Exam AWS Certified Security - Specialty All Questions

View all questions & answers for the AWS Certified Security - Specialty exam

Exam AWS Certified Security - Specialty topic 1 question 32 discussion

Exam question from Amazon's AWS Certified Security - Specialty
Question #: 32
Topic #: 1
[All AWS Certified Security - Specialty Questions]

During a recent internal investigation, it was discovered that all API logging was disabled in a production account, and the root user had created new API keys that appear to have been used several times.
What could have been done to detect and automatically remediate the incident?

  • A. Using Amazon Inspector, review all of the API calls and configure the inspector agent to leverage SNS topics to notify security of the change to AWS CloudTrail, and revoke the new API keys for the root user.
  • B. Using AWS Config, create a config rule that detects when AWS CloudTrail is disabled, as well as any calls to the root user create-api-key. Then use a Lambda function to re-enable CloudTrail logs and deactivate the root API keys.
  • C. Using Amazon CloudWatch, create a CloudWatch event that detects AWS CloudTrail deactivation and a separate Amazon Trusted Advisor check to automatically detect the creation of root API keys. Then use a Lambda function to enable AWS CloudTrail and deactivate the root API keys.
  • D. Using Amazon CloudTrail, create a new CloudTrail event that detects the deactivation of CloudTrail logs, and a separate CloudTrail event that detects the creation of root API keys. Then use a Lambda function to enable CloudTrail and deactivate the root API keys.
Show Suggested Answer Hide Answer
Suggested Answer: B 🗳️

Comments

Chosen Answer:
This is a voting comment (?). It is better to Upvote an existing comment if you don't have anything to add.
Switch to a voting comment New
Madura
Highly Voted 3 years, 7 months ago
The answer should be B. We can achieve this using AWS Config. https://docs.aws.amazon.com/config/latest/developerguide/cloudtrail-enabled.html https://docs.aws.amazon.com/config/latest/developerguide/iam-root-access-key-check.html
upvoted 44 times
senseikimoji
3 years, 5 months ago
This is correct, only the "calls to create-api-key" part is very ambiguous. Technically Config does not detect the call, but the result of the call.
upvoted 2 times
...
lolcats
3 years, 6 months ago
AFAIK, Config can't trigger a Lambda for remediation, only for rules.
upvoted 3 times
awssecuritynewbie
3 years, 6 months ago
It can...you ever used Aws config ? https://aws.amazon.com/about-aws/whats-new/2018/04/aws-config-adds-support-for-aws-lambda/#:~:text=You%20can%20now%20record%20configuration,timeout%20settings%2C%20and%20concurrency%20settings.
upvoted 3 times
...
...
ideoignus
3 years, 2 months ago
AWS Config cannot be configured to watch API calls. While there are other ways to do parts of each, here with options provided: Answer should be C
upvoted 4 times
...
...
donathon
Highly Voted 3 years, 6 months ago
Hi Guys, answer is C. Based on past experience with AWS exams, AWS really like to based questions on their blogs and article to see how updated you are. Below are 2 article that shows exactly where the answer is found. 80% of the PRO exam are now based on these articles. That's why it's so damn hard. C https://aws.amazon.com/blogs/mt/monitor-changes-and-auto-enable-logging-in-aws-cloudtrail/ https://github.com/aws/Trusted-Advisor-Tools/tree/master/ExposedAccessKeys
upvoted 25 times
graesaunders
3 years, 6 months ago
I like your answer but trusted advisor cannot detect the creation of access keys on the root account only the presence of them in popular code repos. Additionally this alert is only available if you are on a support plan where as Config does allow for this.
upvoted 2 times
...
EricR17
3 years, 4 months ago
This is incorrect. Check Madura's response and links above. Standard use-cases for Config.
upvoted 2 times
...
Reza215r
3 years, 6 months ago
Nope B is correct. AWS wants to use managed services as much as possible. "Cloudtrail-enabled aws managed config rule checks whether AWS CloudTrail is enabled in your AWS account. Optionally, you can specify which S3 bucket, SNS topic, and Amazon CloudWatch Logs ARN to use."
upvoted 6 times
DahMac
3 years, 5 months ago
If CloudTrail is disabled, how can CloudTrail create an event?
upvoted 1 times
...
ideoignus
3 years, 2 months ago
AWS Config cannot be configured to watch API calls. While there are other ways to do parts of each, here with options provided: Answer should be C
upvoted 2 times
...
...
...
Raphaello
Most Recent 1 year, 2 months ago
Selected Answer: B
AWS Config managed rule to check on root access key if they exist. https://docs.aws.amazon.com/config/latest/developerguide/iam-root-access-key-check.html Another AWS Config managed rule to check if CloudTrail is enabled. https://docs.aws.amazon.com/config/latest/developerguide/cloudtrail-enabled.html Option B is correct.
upvoted 1 times
...
brpjp
1 year, 4 months ago
B is incorrect, because you have to create custom config rule to check api call for root user create-api-key.
upvoted 1 times
...
Ciara123456
1 year, 5 months ago
Selected Answer: B
B is correct. C would be better if there was not mentioned AWS trusted advisor, which makes the whole sentence wrong.
upvoted 1 times
...
ZZNZ
1 year, 6 months ago
Selected Answer: B
Answer should be B
upvoted 1 times
...
tonimrz
1 year, 8 months ago
Selected Answer: B
Config can trigger Lambdas for remediation apart from SSM. Also Config is not watching API calls, it should watch for API logging de/activation so the answer is B.
upvoted 1 times
...
rohitkaryan
1 year, 10 months ago
https://docs.aws.amazon.com/prescriptive-guidance/latest/patterns/automatically-re-enable-aws-cloudtrail-by-using-a-custom-remediation-rule-in-aws-config.html
upvoted 1 times
...
Green53
1 year, 10 months ago
Selected Answer: B
I looked into C, there doesn't seem to be a Trusted Advisor check for root API keys: https://docs.aws.amazon.com/awssupport/latest/user/security-checks.html AWS Config is about automated tracking and remediation of uncompliant resources, but I wasn't sure it could track the api key creation. https://docs.aws.amazon.com/config/latest/developerguide/managed-rules-by-aws-config.html Suggests it can. AWS provide two managed rules: iam-root-access-key-check multi-region-cloudtrail-enabled or cloudtrail-security-trail-enabled So this would be my choice.
upvoted 2 times
...
Robert0
1 year, 10 months ago
Selected Answer: B
Answer should be B
upvoted 1 times
...
CloudBourne
1 year, 11 months ago
Selected Answer: B
To ensure that CloudTrail remains enabled in your account, AWS Config provides the cloudtrail-enabled managed rule. If CloudTrail is turned off, the cloudtrail-enabled rule automatically re-enables it by using automatic remediation. Source: https://docs.aws.amazon.com/prescriptive-guidance/latest/patterns/automatically-re-enable-aws-cloudtrail-by-using-a-custom-remediation-rule-in-aws-config.html
upvoted 1 times
...
ITGURU51
1 year, 11 months ago
To detect and automatically remediate the incident, you could use AWS Config to create a config rule that detects when AWS CloudTrail is disabled, as well as any calls to the root user create-api-key. Then use a Lambda function to re-enable CloudTrail logs and deactivate the root API keys. B
upvoted 1 times
...
matrpro
1 year, 12 months ago
B is correct. https://docs.aws.amazon.com/prescriptive-guidance/latest/patterns/automatically-re-enable-aws-cloudtrail-by-using-a-custom-remediation-rule-in-aws-config.html
upvoted 1 times
...
matrpro
1 year, 12 months ago
Selected Answer: B
AWS wants to use managed services. Config can check and remediate if the Cloud trail is stopped and lambda can start it. in B, I do know what can do Trusted advisor to start CT logging. This last service is more to check resource utilization and so on...
upvoted 1 times
...
gvramana
2 years, 1 month ago
Question Keyword is "detect and automatically remediate", of CloudTrail disable & create API keys AWS config with lambda will does all these https://docs.aws.amazon.com/config/latest/developerguide/cloudtrail-enabled.html
upvoted 1 times
...
sp951
2 years, 1 month ago
Selected Answer: B
It would be B bc it says automatically
upvoted 1 times
...
peddyua
2 years, 1 month ago
You can achieve the same thing both ways. B and C both can use lambda import boto3 def lambda_handler(event, context): # Re-enable CloudTrail logs cloudtrail = boto3.client('cloudtrail') cloudtrail.start_logging(Name='my-cloudtrail') # Deactivate root API key iam = boto3.client('iam') iam.update_access_key(UserName='root', AccessKeyId='my-api-key', Status='Inactive')
upvoted 1 times
...
Community vote distribution
A (35%)
C (25%)
B (20%)
Other
Most Voted
A voting comment increases the vote count for the chosen answer by one.

Upvoting a comment with a selected answer will also increase the vote count towards that answer by one. So if you see a comment that you already agree with, you can upvote it instead of posting a new comment.

SaveCancel
Loading ...
exam
Someone Bought Contributor Access for:
SY0-701
London, 1 minute ago