Skip to content

feat: add secret scanning policy - #897

Merged
jeffmendoza merged 2 commits into
ossf:mainfrom
bilaldeveloper4312:feat/secret-scanning-policy
Nov 10, 2026
Merged

jeffmendoza merged 2 commits into
ossf:mainfrom
bilaldeveloper4312:feat/secret-scanning-policy

Conversation

@bilaldeveloper4312

Copy link
Copy Markdown
Contributor

Summary

  • add a GitHub Secret Scanning policy with configuration and registry support
  • distinguish an unavailable API status from disabled Secret Scanning
  • implement the fix action and document the configuration

Validation

  • go test ./...
  • golangci-lint run

Fixes #363

AI-assisted contribution: prepared with AI assistance; validation results are listed above.

@github-actions

github-actions Bot commented Oct 4, 2026

Copy link
Copy Markdown

This pull request has been marked stale because it has been open for 10 days with no activity

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟡 Changes recommended

An unavailable GitHub status incorrectly passes the secret-scanning check, allowing compliance to be reported and existing violation issues to be closed without verifying that scanning is enabled.

1 open issue
What changed in this PR

Adds a Secret Scanning policy to Allstar’s policy framework, addressing #363’s request to monitor and enable GitHub secret scanning across repositories.

Changes:

  • Adds configurable checks that distinguish disabled scanning from unavailable API status.
  • Implements a fix action to enable secret scanning and registers the policy.
  • Adds configuration-precedence and policy tests, plus setup and permission documentation.
File Description
README.md Documents policy configuration, status handling, and required permissions.
pkg/​policies/​secretscanning/​secretscanning.go Implements configuration, status checks, notifications, and the fix action.
pkg/​policies/​secretscanning/​secretscanning_test.go Tests configuration precedence, status outcomes, and enablement requests.
pkg/​policies/​policies.go Registers Secret Scanning with the available policies.

Review effort: Balanced

bilaldeveloper4312 and others added 2 commits November 9, 2026 18:49
Signed-off-by: bilaldeveloper4312 <bilaldeveloper4312@users.noreply.github.com>
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Signed-off-by: Jeff Mendoza <jlm@jlm.name>
@jeffmendoza
jeffmendoza force-pushed the feat/secret-scanning-policy branch from dc25763 to fc7cad3 Compare November 10, 2026 03:02
@jeffmendoza
jeffmendoza merged commit 399d86e into ossf:main Nov 10, 2026
11 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

Monitor/enable GitHub's secret detection feature

3 participants