[DOCS-XXXXX] Add IaC Security custom rules guide - #38546
Draft
valeryjuli wants to merge 1 commit into
Draft
Conversation
Document the IaC Security custom-rule authoring feature: the package datadog / DatadogPolicy Rego contract, result fields, and a step-by-step tutorial for writing a rule from scratch. Cross-link from the IaC Security overview and rules pages.
Contributor
|
Contributor
Preview links (active after the
|
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.
Motivation
IaC Security has a custom-rule authoring feature (Detection Coverage > IaC) with no existing documentation. This adds an overview page and a step-by-step tutorial covering the Rego rule contract (
package datadog/DatadogPolicy contains result) used by both default and custom IaC rules.Fixes DOCS-XXXXX (placeholder — replace with the real ticket before merging)
What's included
content/en/security/code_security/iac_security/custom_rules/_index.md: rule contract, result fields, iteration pattern, testing guidancecontent/en/security/code_security/iac_security/custom_rules/tutorial.md: end-to-end tutorial (Terraform S3 versioning check)config/_default/menus/main.en.yamliac_security/_index.mdandiac_rules/_index.mdAI assistance disclosure
This content was drafted with Claude Code, grounded in verified Rego syntax/examples from the
datadog-iac-scanner-default-rulesrepo and cross-checked against existing docs conventions (SAST custom rules pages, CSM custom rules pages). It has not yet been reviewed against the live Detection Coverage > IaC UI for exact button/field copy — see open items below.Merge instructions
Open items before merging
DOCS-XXXXXwith a real ticket number (title + Fixes line)common_lib, etc.) — guide currently avoids claiming thisyarn startlocally to preview rendering and nav placementTest plan
valepasses on all new/edited files (0 errors)