Git Product home page Git Product logo

aws-security-hub-automatic-suppression-rules's Introduction

How to Create Auto-Suppression Rules in AWS Security Hub

This project is for SecurityHub auto supression of findings using the batch_update_findings API call.

Deploy

The following commands shows how to deploy the solution by using the AWS Cloud Development Kit (AWS CDK) (https://aws.amazon.com/cdk/).

First, the CDK will initialize your environment and upload the Lambda assets to S3.

cdk bootstrap

Then, you can deploy the solution to your account.

Specify the generator id or comma separated list of generator ids the suppression rule should apply to.

Specify the account number or comma separated list of account numbers the suppression rule should apply to.

cdk deploy sechub-finding-suppression --parameters GeneratorIds=aws-foundational-security-best-practices/v/1.0.0/EC2.6 --parameters AccountNumbers=123456789123

Testing

Create a VPC that does not have flow logs enabled. We have included a test VPC that you can deploy.

cdk deploy vpc-test-suppression

Verify that the Security Hub finding EC2.6 has been suppressed in the parent account and the target account.

You might need to wait a few minutes for the AWS Config recorder to detect the newly created resource. Then to manually trigger the periodic Config rule securityhub-vpc-flow-logs-enabled-ID-HERE.

After verifying the suppression, delete the test VPC you created to test the suppression rule.

cdk destroy vpc-test-suppression

Creating pydocs

python3 -m pydoc -w sechub_batch_update/sechub_batch_update_stack.py sechub_batch_update/sechub_suppression.py lambda/batch_update.py sechub_batch_update/vpc_test.py 

mv *.html pydocs/

aws-security-hub-automatic-suppression-rules's People

Contributors

0xjjoyy avatar amazon-auto avatar

Stargazers

 avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.