Skip to content

feat: add more policies for better compliance posture for SOC2#9

Open
gusfcarvalho wants to merge 12 commits intomainfrom
gc-feat-more-policies
Open

feat: add more policies for better compliance posture for SOC2#9
gusfcarvalho wants to merge 12 commits intomainfrom
gc-feat-more-policies

Conversation

@gusfcarvalho
Copy link
Copy Markdown
Contributor

@gusfcarvalho gusfcarvalho commented May 5, 2026

Adds GitHub organization compliance policies for SOC2 posture, including SSO enforcement, IP allow-list coverage, web commit sign-off, team-based access, member repository creation permission, default repository permissions, and owner-count limits.

Also updates the Dependabot alerts and secret scanning policies to evaluate GitHub's default code security configurations format, with example org data and tests covering the new input shape.

fix: support new format for dependabot and secret scanning policies
Signed-off-by: Gustavo Carvalho <gustavo.carvalho@container-solutions.com>
Copilot AI review requested due to automatic review settings May 5, 2026 12:52
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Adds several new GitHub organization compliance policies (aimed at improving SOC2 posture) and updates existing secret scanning / Dependabot policies to evaluate GitHub’s newer “default code security configurations” format.

Changes:

  • Added new org-level policies (with tests) for SSO, IP allow-list, web commit sign-off, team-based access, repo creation restrictions, default repo permissions, and owner count.
  • Updated secret scanning + Dependabot “enabled by default” policies (and tests) to read from default_security_configs and emit richer violation descriptions.
  • Extended example org JSON inputs with additional org data (members/SSO/IP allow-list).

Reviewed changes

Copilot reviewed 20 out of 20 changed files in this pull request and generated 8 comments.

Show a summary per file
File Description
policies/gh_org_web_commit_signoff.rego New policy enforcing required web commit sign-off setting.
policies/gh_org_web_commit_signoff_test.rego Tests for web commit sign-off policy.
policies/gh_org_team_based_access.rego New policy requiring at least one org team (RBAC baseline).
policies/gh_org_team_based_access_test.rego Tests for team-based access policy.
policies/gh_org_sso_enabled.rego New policy checking org SAML SSO enabled.
policies/gh_org_sso_enabled_test.rego Tests for SSO-enabled policy.
policies/gh_org_secret_scanning_enabled.rego Updated to evaluate default code security configurations for secret scanning defaults.
policies/gh_org_secret_scanning_enabled_test.rego Updated tests for new secret scanning input shape.
policies/gh_org_secret_dependabot_alerts.rego Updated to evaluate default code security configurations for Dependabot alert defaults.
policies/gh_org_secret_dependabot_alerts_test.rego Updated tests for new Dependabot input shape.
policies/gh_org_members_can_create_repos.rego New policy restricting member repository creation.
policies/gh_org_members_can_create_repos_test.rego Tests for repo creation restriction policy.
policies/gh_org_ip_allowlist_enabled.rego New policy ensuring at least one active IP allow-list entry.
policies/gh_org_ip_allowlist_enabled_test.rego Tests for IP allow-list policy.
policies/gh_org_default_repo_permission.rego New policy enforcing non-permissive default repo permission.
policies/gh_org_default_repo_permission_test.rego Tests for default repo permission policy.
policies/gh_org_admin_count.rego New policy limiting org owner/admin count.
policies/gh_org_admin_count_test.rego Tests for owner/admin count policy.
example-data/testorg.json Example org input updated with members/SSO/IP allow-list data.
example-data/testorg-unremediated.json Unremediated example org input updated with members/SSO/IP allow-list data.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread policies/gh_org_secret_scanning_enabled.rego
Comment thread policies/gh_org_secret_dependabot_alerts.rego
Comment thread policies/gh_org_team_based_access.rego Outdated
Comment thread policies/gh_org_members_can_create_repos.rego Outdated
Comment thread policies/gh_org_sso_enabled.rego
Comment thread policies/gh_org_admin_count.rego Outdated
Comment thread example-data/testorg.json
Comment thread example-data/testorg-unremediated.json
Signed-off-by: Gustavo Carvalho <gustavo.carvalho@container-solutions.com>
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Copilot reviewed 20 out of 20 changed files in this pull request and generated 3 comments.


💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread policies/gh_org_sso_enabled.rego
Comment thread policies/gh_org_sso_enabled_test.rego
Comment thread policies/gh_org_ip_allowlist_enabled_test.rego
Signed-off-by: Gustavo Carvalho <gustavo.carvalho@container-solutions.com>
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Copilot reviewed 20 out of 20 changed files in this pull request and generated 1 comment.


💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread example-data/testorg.json
Signed-off-by: Gustavo Carvalho <gustavo.carvalho@container-solutions.com>
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Copilot reviewed 20 out of 20 changed files in this pull request and generated 2 comments.


💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread policies/gh_org_sso_enabled.rego Outdated
Comment thread policies/gh_org_web_commit_signoff.rego Outdated
Signed-off-by: Gustavo Carvalho <gustavo.carvalho@container-solutions.com>
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Copilot reviewed 20 out of 20 changed files in this pull request and generated 4 comments.


💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread policies/gh_org_admin_count.rego Outdated
Comment thread policies/gh_org_web_commit_signoff.rego Outdated
Comment thread policies/gh_org_members_can_create_repos.rego Outdated
Comment thread policies/gh_org_default_repo_permission.rego Outdated
Signed-off-by: Gustavo Carvalho <gustavo.carvalho@container-solutions.com>
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Copilot reviewed 20 out of 20 changed files in this pull request and generated 1 comment.


💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread policies/gh_org_admin_count.rego
Signed-off-by: Gustavo Carvalho <gustavo.carvalho@container-solutions.com>
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Copilot reviewed 20 out of 20 changed files in this pull request and generated 4 comments.


💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread policies/gh_org_secret_scanning_enabled.rego Outdated
Comment thread policies/gh_org_secret_dependabot_alerts.rego Outdated
Comment thread policies/gh_org_secret_scanning_enabled.rego Outdated
Comment thread policies/gh_org_secret_dependabot_alerts.rego Outdated
Signed-off-by: Gustavo Carvalho <gustavo.carvalho@container-solutions.com>
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Copilot reviewed 20 out of 20 changed files in this pull request and generated 2 comments.

Comment thread policies/gh_org_admin_count.rego Outdated
Comment thread policies/gh_org_admin_count.rego
Signed-off-by: Gustavo Carvalho <gustavo.carvalho@container-solutions.com>
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Copilot reviewed 18 out of 18 changed files in this pull request and generated 1 comment.

Comment thread example-data/testorg.json
Signed-off-by: Gustavo Carvalho <gustavo.carvalho@container-solutions.com>
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Copilot reviewed 20 out of 20 changed files in this pull request and generated 1 comment.

Comment thread example-data/testorg.json
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Copilot reviewed 20 out of 20 changed files in this pull request and generated 2 comments.

Comment thread policies/gh_org_secret_scanning_enabled.rego
Comment thread policies/gh_org_secret_dependabot_alerts.rego
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Copilot reviewed 20 out of 20 changed files in this pull request and generated 1 comment.

Comment thread policies/gh_org_owner_count.rego Outdated
Signed-off-by: Gustavo Carvalho <gustavo.carvalho@container-solutions.com>
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Copilot reviewed 20 out of 20 changed files in this pull request and generated 2 comments.

Comment thread policies/gh_org_owner_count.rego Outdated
Comment thread policies/gh_org_secret_scanning_enabled_test.rego
@gusfcarvalho gusfcarvalho requested a review from Copilot May 6, 2026 09:27
Signed-off-by: Gustavo Carvalho <gustavo.carvalho@container-solutions.com>
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Copilot reviewed 20 out of 20 changed files in this pull request and generated no new comments.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants