AWS DevOps Pro Certification Blog Post Series: Incident and Event Response
Tags: aws, study, certification
Published: 2019-06-06 15:35:37

---
title: AWS DevOps Pro Certification Blog Post Series: Incident and Event Response
published: true
tags: aws,study,certification
canonical_url: https://booyaa.wtf/2019/aws-devops-pro-certification-incident-and-event-response
cover_image: https://thepracticaldev.s3.amazonaws.com/i/yaiwe9er5wcnrqisgait.png
series: AWS DevOps Pro Certification
---

Photo by Zhen Hu on [Unsplash](https://unsplash.com/photos/Xruf17OrkwM)

## What does the exam guide say?

To pass this domain, you'll need to know the following:

- Troubleshoot issues and determine how to restore operations
- Determine how to automate event management and alerting
- Apply concepts required to implement automated healing
- Apply concepts required to set up event-driven automated actions

This domain is **18%** of the overall mark for the exam.

## What whitepapers are relevant?

According to the [AWS Whitepapers for Security and Compliance](https://aws.amazon.com/whitepapers/#security) we should look at the following documents:

- [AWS Security Incident Response (May 2019)][security_wp1]
- [AWS Security Best Practices  (August 2016)][security_wp2]

Other whitepapers as recommended by product pages:

- [Real-Time Insights on AWS Account Activity][kda_wp1]
- [Real-Time Web Analytics with Kinesis Data Analytics][kda_wp2]
- [Streaming Data Solutions on AWS with Amazon Kinesis (July 2017)][kinesis_wp]

## What services and products covered in this domain?

- [Amazon GuardDuty][guardduty_page] - thread detection
- [Amazon Inspector][inspector_page] - best practice in security
- [Amazon Kinesis][kinesis_page] has separate pages for each sub-product
  - [Kinesis Video Streams][kvs_page] allows you to securely stream video from connected devices for analytics, machine learning and other forms of processing.
  - [Kinesis Data Streams][kds_page] is scalable and durable real-time data stream service
  - [Kinesis Data Firehose][kdf_page] allows you to capture, transform and load data streams into AWS data stores (S3, ) whilst allowing you to perform near real-time analytics with existing Business Intelligence tools
  - [Kinesis Data Analytics][kda_page] is the next tier up when you've outgrown CloudWatch for analytics. Allowing you to process data streams in real time using SQL or Java.

## What about other types of documentation?

If you have the time, by all means, read the User Guides, but they are usually a couple of hundred pages.

- [Amazon GuardDuty][guardduty_guide]
- [Amazon Inspector][inspector_guide]
- Amazon Kinesis
  - [Kinesis Video Streams][kvs_guide]
  - [Kinesis Data Streams][kds_guide]
  - [Kinesis Data Firehose][kdf_guide]
  - [Kinesis Data Analytics][kda_guide]

Alternatively, get familiar with the services using the FAQs:

- [Amazon GuardDuty][guardduty_faq]
- [Amazon Inspector][inspector_faq]
- Amazon Kinesis
  - [Kinesis Video Streams][kvs_faq]
  - [Kinesis Data Streams][kds_faq]
  - [Kinesis Data Firehose][kdf_faq]
  - [Kinesis Data Analytics][kda_faq]

You're all expected to know the APIs

- [Amazon GuardDuty][guardduty_api]
- [Amazon Inspector][inspector_api]
- Amazon Kinesis
  - [Kinesis Video Streams][kvs_api]
  - [Kinesis Data Streams][kds_api]
  - [Kinesis Data Firehose][kdf_api]
  - [Kinesis Data Analytics][kda_api]

Before you panic, you'll start to spot a pattern with the API verbs.

And the CLI commands

- [Amazon GuardDuty][guardduty_cli]
- [Amazon Inspector][inspector_cli]
- Amazon Kinesis
  - Kinesis Video Streams has 3 different subcommands: [kinesis-video-archived-media][kvs_cli1], [kinesis-video-media][kvs_cli2], [kinesisvideo][kvs_cli3]
  - Kinesis Data Streams has no CLI subcommands
  - Kinesis Data Firehose has no CLI subcommands
  - [Kinesis Data Analytics][kda_cli]

As with the API, there are patterns to the commands.

## Please put down your weapon. You have 20 seconds to comply.

_Quote: ED-209, Robocop (1987)_

This is another domain, that probably requires awareness of the products rather than actual use (especially in the case of the Kinesis suite). As we'll see Amazon GuardDuty and Amazon Inspector do have an immediate use for small to medium-sized business if you don't have an Information Security function in your company.

As the title of this section suggests, this is domain focussed on how to responding to incidents and events. Incidents are usually around a security context. whereas events are often related to a data stream.

I'll be covering all the products in this domain within this post since it's a relatively small domain with very little opportunities to provide practical hands-on experience using the AWS CLI.

## What?

**Amazon GuardDuty** is a threat detection service that analyses meta-data generated by your account and network activity found in AWS CloudTrail Events, Amazon VPC Flow Log, and DNS Logs. It can detect:
- Reconnaissance - port scanning, login failures, unusual API activity and access from a known bad IP.
- Instance compromise - malware, outbound denial of service activity, unusually high volumes of traffic, activity from a known bad IP, data exfiltration via DNS
- Account compromise - attempt to disable AWS CloudTrail logging, unusual instance or infrastructure launches (think: GPU instance types for cryptocurrency mining), resources being spun up in regions outside of normal use, activity from a known bad IP.
- Data retention for a GuardDuty-generated finding is 90 days.

**Amazon Inspector** is another automated security assessment service just like GuardDuty, but instead of identifying issues with your account or network activity it primarily focusses on your EC2 instances. It has built-in rules (created and maintained by AWS security researchers) to check for access to your instances from the internet, remote root login being enabled, or vulnerable software versions installed.

**Amazon Kinesis** is a suite of products:
- **Kinesis Video Streams** accepts video streams from devices and allow you to perform analytics, machine learning (Amazon Rekognition Video and Amazon SageMaker) and other forms of processing.
- **Kinesis Data Streams** is a scalable and durable real-time data streaming service that can capture high volumes of data (gigabytes of data per second) from hundreds of thousands of sources. You can then take this data and process it using Kinesis Data Analytics, Spark or code running on an EC2 instance (API) or AWS Lambda.
- **Kinesis Data Firehose** allows you to take your high volumes of streaming data and load them into data stores (S3, Amazon Redshift, Amazon Elasticsearch and a 3rd party tool called Splunk) for analytics.
- **Kinesis Data Analytics** can take data streams from Kinesis Data Firehose and Kinesis Data Streams and perform queries against the data using SQL or Java.

## Why?

**Amazon GuardDuty** provides a comprehensive threat detection service, whilst it does offer reporting through a dashboard, the response workflow does require more work i.e. you're expected to write the tooling (AWS Lambda) around the events (CloudWatch). This is probably why Amazon is touting [partners][guardduty_partners] who can help implement these workflows.

**Amazon Inspector** as with GuardDuty, you get an all-around security assessment tool for your EC2 instances.

The **Amazon Kinesis** suite provides managed services that can handle large amounts of data. Whilst you run your own [Apache Kafka][link_kafka] environment, you would need a large team to support it setup and on-going maintenance. Trivia: Amazon also provides a managed service for Apache Kafka called [Amazon Managed Streaming for Apache Kafka][aws_msk]. The key take away for why Kinesis exists is that it has specialist tooling for Video and High Volume Data streams. Because of tight integration into AWS data services Kinesis Data FireHose can load large volumes of data into their services with a minimal amount of configuration. Kinesis Data Analytics can be used to perform analytics against these data streams or when you've outgrown the likes of CloudWatch for log analysis. Finally, all of these products in this suite can be used together or separately, although Kinesis Data Analytics does require the source to come from Kinesis Data FireHouse or Kinesis Data Streams

[aws_msk]: https://aws.amazon.com/msk/
[link_kafka]: https://kafka.apache.org/

## When?

**Amazon GuardDuty** should be used when you don't want the overhead of managing your own threat detection and response system. To do this yourself you would need to use tools like [Snort][link_snort] or [Tripwire][link_tripwire] and maintain subscriptions to 3rd party threat intelligence sources like [Proofpoint][link_proofpoint] and [CrowdStrike][link_crowdstrike].

**Amazon Inspector** is a complementary tool to Amazon GuardDuty, so the chances are if you're using it (Amazon GuardDuty), you should be using Amazon Inspector.

Some of the use cases for **Amazon Kinesis** are:

- Capturing live video streams of cars, identifying the license plates and then taking action.
- Transform batch loading (and subsequent overnight reporting), into the real-time analysis.
- Collecting telemetry data from a fleet Internet of Things devices and reacting to the data using other AWS services like AWS Lambda.

## How?

**Amazon GuardDuty** provides a [30-day free trial][guardduty_pricing], after that you charged by the volume of events (CloudTrail) and volume of data (Amazon VPC Flow Log and DNS log). The key things (also that form the navigation menu) you need to be aware of in the service page in the AWS Console are:

- Findings are potential security issues discovered by GuardDuty.
- Settings are where:
  - permissions for the service are defined
  - Set the interval that GuardDuty sends events to CloudWatch
  - Preload GuardDuty with sample findings
  - Suspend or disable GuardDuty
- Lists are the list management page where you can upload a list of Trusted IPs or Threat Lists (malicious IP addresses). You can upload have a max of 6 Threat Lists per AWS account per region.
- Accounts - to manage Master (admin) and Member (users) Accounts within the service
- What's New - features announcement (you can also subscribe via [SNS topic][guardduty_guide_sns])
- Free trial - how much time you have left

**Amazon Inspector** provides a [90 day free trial][inspector_pricing] for the first 250 instance assessments. The key things to be aware of are:
  - Agents - can analyse your EC2 instances without the use of it's [agent][inspector_guide_agents], but you will be only limited to [Network Reachability][inspector_guide_net_reach] rules.
  - Assessment target is a collection of EC2 instances group together using AWS tags.
  - Assessment template
  - Finding
  - Rule packages there are two categories: Network and Host assessments. 
    - Important: you can only run the Network assessment rule if you don't have the agent installed.
    - Rules within these categories are
      - Network assessment
        - Network Reachability
      - Host assessment
        - Common Vulnerability and Exposures
        - Centre for Internet Security (CIS) Benchmarks
        - Security Best Practices for Amazon Inspector
        - Runtime Behaviour Analysis
  - Telemetry is data (behaviour, configuration, etc) collected by Amazon Inspector from the EC2 instance when an assessment is run.

**Amazon Kinesis** does require development to utilise the services. The examples provided require quite a bit of setup. It would be nice if you could pre-load the services with sample data much as you can with Amazon GuardDuty or Amazon Inspector.


<!-- What whitepapers are relevant? -->

[security_wp1]: https://d1.awsstatic.com/whitepapers/aws_security_incident_response.pdf
[security_wp2]: https://d1.awsstatic.com/whitepapers/Security/AWS_Security_Best_Practices.pdf
[kinesis_wp]: https://d1.awsstatic.com/whitepapers/whitepaper-streaming-data-solutions-on-aws-with-amazon-kinesis.pdf
[kda_wp1]: https://aws.amazon.com/answers/account-management/real-time-insights-account-activity/
[kda_wp2]: https://aws.amazon.com/answers/web-applications/real-time-web-analytics-with-kinesis/

<!-- What services and products covered in this domain? -->

[guardduty_page]: https://aws.amazon.com/guardduty/
[guardduty_pricing]: https://aws.amazon.com/guardduty/pricing/
[guardduty_faq]: https://aws.amazon.com/guardduty/faqs/
[guardduty_guide]: https://docs.aws.amazon.com/guardduty/latest/ug/what-is-guardduty.html
[guardduty_cli]: https://docs.aws.amazon.com/cli/latest/reference/guardduty/index.html
[guardduty_api]: https://docs.aws.amazon.com/guardduty/latest/ug/guardduty_api_ref.html 

[inspector_page]: https://aws.amazon.com/inspector/
[inspector_pricing]: https://aws.amazon.com/inspector/pricing/
[inspector_faq]: https://aws.amazon.com/inspector/faqs/
[inspector_guide]: https://docs.aws.amazon.com/inspector/latest/userguide/inspector_introduction.html
[inspector_cli]: https://docs.aws.amazon.com/cli/latest/reference/inspector/index.html
[inspector_api]: https://docs.aws.amazon.com/inspector/latest/APIReference/Welcome.html

[kinesis_page]: https://aws.amazon.com/kinesis/
[kvs_page]: https://aws.amazon.com/kinesis/video-streams/
[kvs_pricing]: https://aws.amazon.com/kinesis/video-streams/pricing/?nc=sn&loc=3
[kvs_faq]: https://aws.amazon.com/kinesis/video-streams/faqs/?nc=sn&loc=5
[kvs_guide]: https://docs.aws.amazon.com/kinesisvideostreams/latest/dg/what-is-kinesis-video.html
[kvs_cli1]: https://docs.aws.amazon.com/cli/latest/reference/kinesis-video-archived-media/index.html
[kvs_cli2]: https://docs.aws.amazon.com/cli/latest/reference/kinesis-video-media/index.html
[kvs_cli3]: https://docs.aws.amazon.com/cli/latest/reference/kinesisvideo/index.html
[kvs_api]: https://docs.aws.amazon.com/kinesisvideostreams/latest/dg/API_Reference.html

[kds_page]: https://aws.amazon.com/kinesis/data-streams/
[kds_pricing]: https://aws.amazon.com/kinesis/data-streams/pricing/
[kds_faq]: https://aws.amazon.com/kinesis/data-streams/faqs/
[kds_guide]: http://docs.aws.amazon.com/kinesis/latest/dev/introduction.html
[kds_api]: http://docs.aws.amazon.com/kinesis/latest/APIReference/Welcome.html

[kdf_page]: https://aws.amazon.com/kinesis/data-firehose/
[kdf_pricing]: https://aws.amazon.com/kinesis/data-firehose/pricing/
[kdf_faq]: https://aws.amazon.com/kinesis/data-firehose/faqs/
[kdf_guide]: https://docs.aws.amazon.com/firehose/latest/dev/
[kdf_api]: http://docs.aws.amazon.com/firehose/latest/APIReference/Welcome.html

[kda_page]: https://aws.amazon.com/kinesis/data-analytics/
[kda_pricing]: https://aws.amazon.com/kinesis/data-analytics/pricing/
[kda_faq]: https://aws.amazon.com/kinesis/data-analytics/faqs/
[kda_guide]: https://docs.aws.amazon.com/kinesisanalytics/latest/dev/what-is.html
[kda_cli]: https://docs.aws.amazon.com/cli/latest/reference/kinesisanalytics/index.html
[kda_api]: https://docs.aws.amazon.com/kinesisanalytics/latest/dev/API_Reference.html
[kda_sql]: https://docs.aws.amazon.com/kinesisanalytics/latest/sqlref/analytics-sql-reference.html

<!-- Why -->

[guardduty_partners]: https://aws.amazon.com/guardduty/resources/partners/

<!-- When -->

[link_snort]: https://www.snort.org/
[link_tripwire]: https://github.com/Tripwire/tripwire-open-source
[link_proofpoint]: http://www.proofpoint.com/
[link_crowdstrike]: https://www.crowdstrike.com/

<!-- How -->

[guardduty_pricing]: https://aws.amazon.com/guardduty/pricing/
[guardduty_guide_sns]: https://docs.aws.amazon.com/guardduty/latest/ug/guardduty_sns.html
[inspector_pricing]: https://aws.amazon.com/inspector/pricing/
[inspector_guide_agents]: https://docs.aws.amazon.com/inspector/latest/userguide/inspector_agents.html
[inspector_guide_net_reach]: https://docs.aws.amazon.com/inspector/latest/userguide/inspector_network-reachability.html

Unsplash path (what terms I used to get to the cover image): incident, emergency

_To go to the next part of the series, click on the grey dot below which is next to the current marker (the black dot)._