Git Product home page Git Product logo

terraform-google-security-health-checker's Introduction

terraform-google-security-health-checker

This module will deploy a cloud function that can be used by infrastructure developers or a build pipeline to detect security findings during infrastructure development.

The resources/services/activations/deletions that this module will create/trigger are:

  • A Cloud function to assess the security findings during infrastructure development

Usage

Basic usage of this module is as follows:

module "security_health_checker" {
  source  = "terraform-google-modules/security-health-checker/google"
  version = "~> 0.1"

  project_id  = "<PROJECT ID>"
  org_id = "<Google Cloud Organization ID>"
  identity_running_function ="Google group that will have permission to invoke the cloud function"

}

Then perform the following commands on the root folder:

  • terraform init to get the plugins
  • terraform plan to see the infrastructure plan
  • terraform apply to apply the infrastructure build
  • terraform destroy to destroy the built infrastructure

Functional examples are included in the examples directory.

Inputs

Name Description Type Default Required
activate_apis The list of apis to activate for Cloud Function list(string)
[
"storage.googleapis.com",
"cloudfunctions.googleapis.com",
"securitycenter.googleapis.com",
"cloudbuild.googleapis.com"
]
no
compliance_framework Compliance framework to base security health check on string "pci" no
critical_max Number of critical findings before alerting string "0" no
disable_dependent_services Whether services that are enabled and which depend on this service should also be disabled when this service is destroyed. https://www.terraform.io/docs/providers/google/r/google_project_service.html#disable_dependent_services string "false" no
disable_services_on_destroy Whether project services will be disabled when the resources are destroyed. https://www.terraform.io/docs/providers/google/r/google_project_service.html#disable_on_destroy string "false" no
enable_apis Whether to actually enable the APIs. If false, this module is a no-op. string "true" no
environment Unique environment name to link the deployment together string "scc-health" no
function_entry_point Name of function in python script string "scc_helper_updated" no
high_max Number of high findings before alerting string "10" no
identity_running_function Google group that will have permission to invoke the cloud function string n/a yes
medium_max Number of medium findings before alerting string "20" no
org_id Organization ID to monitor Security Health any n/a yes
project_id Google Cloud Project where Cloud Function will be deployed any n/a yes
region Region where cloud function is deployed string "us-central1" no
runtime Runtime environment for cloud function string "python37" no

Outputs

No output.

Requirements

These sections describe requirements for using this module.

Software

The following dependencies must be available:

Service Account

A service account with the following roles must be used to provision the resources of this module:

  • Storage Admin: roles/storage.admin
  • Cloud Function Admin: roles/cloudfunctions.admin
  • Security Admin: roles/iam.securityAdmin

The Project Factory module and the IAM module may be used in combination to provision a service account with the necessary roles applied.

APIs

A project with the following APIs enabled must be used to host the resources of this module:

  • Cloud Functions JSON API: cloudfunctions.googleapis.com
  • Google Cloud Storage JSON API: storage-api.googleapis.com
  • Security Command Center JSON API: securitycenter.googleapis.com

The Project Factory module can be used to provision a project with the necessary APIs enabled.

Contributing

Refer to the contribution guidelines for information on contributing to this module.

Security Disclosures

Please see our security disclosure process.

terraform-google-security-health-checker's People

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

Forkers

jasonbisson

terraform-google-security-health-checker's Issues

SCC Licence requirements

Hello there,

Looks very useful! Just wanted to check if this required an SCC Premium licence to get all the compliance findings?

Cheers!
Lindy

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.