Feature/lab6#2
Open
raaller wants to merge 8 commits into
Open
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Goal
Scan the deliberately vulnerable Terraform, Ansible, and Pulumi IaC samples using Checkov and KICS, triage the findings, compare the tools, and implement a custom Checkov policy requiring RDS resources to have a restricted-data classification tag.
Changes
submissions/lab6.mdlabs/lab6/policies/my-custom-policy.yamlCKV2_CUSTOM_1aws_db_instanceto definetags.DataClassification = "restricted"Testing
Checkov on Terraform
Results:
Top-five rules:
KICS on Ansible
docker run --rm \ -v "$(pwd)/labs/lab6:/path" \ checkmarx/kics:v2.1.20 \ scan \ -p /path/vulnerable-iac/ansible/ \ -o /path/results/kics-ansible/ \ --report-formats json,sarifIndividual findings:
Query-group severity breakdown:
KICS on Pulumi
docker run --rm \ -v "$(pwd)/labs/lab6:/path" \ checkmarx/kics:v2.1.20 \ scan \ -p /path/vulnerable-iac/pulumi/ \ -o /path/results/kics-pulumi/ \ --report-formats json,sarifResults:
Query-group severity breakdown:
Custom Checkov policy
Verification:
CKV2_CUSTOM_1fired on:Both resources are missing the required classification:
Artifacts
submissions/lab6.mdlabs/lab6/policies/my-custom-policy.yamlScanner-generated output under
labs/lab6/results/is intentionally not committed.Checklist
feat(labN): <topic>conventionsubmissions/lab6.md