Skip to content

[Governance] Remove routine administrator bypass from the central control-plane merge path #1340

Description

@seonghobae

Current governance defect — 2026-09-02

Fresh full-payload reads show two distinct live settings surfaces remain out of the current solo-maintainer contract.

Organization ruleset 18156473 (CWL Central required workflows)

The effective inherited ruleset on Orgmetra develop remains active and default-branch-only, preserves the seven central required workflows plus deletion/non-fast-forward protection, and allows only merge/squash. Its pull-request rule currently has:

  • required_approving_review_count = 1;
  • dismiss_stale_reviews_on_push = true;
  • require_code_owner_review = false;
  • require_last_push_approval = false;
  • required_review_thread_resolution = true;
  • required_reviewers = [];
  • require_extra_approval_for_unattributed_changes = true; and
  • OrganizationAdmin with bypass_mode = always.

The positive generic approval count is structurally unsatisfiable in the current one-human-maintainer fleet. Per #772/#1351, do not manufacture independence with bot/service-account approval, self-approval, broadened reviewer credentials, or administrator bypass.

.github repository ruleset 17921150 (Lock default branch)

The repository-local ruleset already has approval count 0, last-push approval disabled, CODEOWNER review disabled, required reviewers empty, review-thread resolution enabled, and deletion/non-fast-forward protection. It remains out of contract because:

  • it still permits rebase in addition to merge/squash; and
  • it still exposes OrganizationAdmin/always bypass.

Current target contract

For the present one-human-maintainer operating model:

  • required_approving_review_count = 0;
  • require_last_push_approval = false;
  • require_code_owner_review = false while the sole code owner is also the author;
  • no synthetic required_reviewers merely to recreate unavailable human independence;
  • stale-review dismissal and required review-thread resolution remain enabled;
  • exact central required workflows and default-branch-only scope remain enforced;
  • only merge and squash are accepted;
  • deletion and non-fast-forward protection remain enabled; and
  • no routine bypass actor exists. Any emergency repair path must be separately activated, time-bounded, attributable, and auditable.

This does not weaken OpenCode, Noema, Strix, Security/SAST, Dependency Review, coverage/provenance, or repository-specific deterministic gates and does not authorize direct protected-branch writes.

Causal owner and authorized mutation boundary

PR #1176 is the canonical source audit / regression / rollout-documentation writer for this contract. It must not be expanded into a fake settings repair when no authorized settings credential exists.

GitHub's current REST contract provides PUT /orgs/{org}/rulesets/{ruleset_id} for an organization ruleset and requires organization Administration: write. Repository rulesets have their corresponding repository administration endpoint. These are privileged owner-plane mutations, not ordinary pull-request source writes.

The currently connected ChatGPT GitHub surface exposes ruleset reads but no ruleset-settings mutation. Protected .github/main separately contains the repository-metadata reconciliation lane introduced by #1576/#1625, but its CWL_REPOSITORY_METADATA_TOKEN is deliberately scoped to repository description/topics/Pages authority and external provisioning remains open in #1579. Do not silently broaden or reuse that credential for organization rulesets. If automated ruleset reconciliation is adopted, provision a separate least-privilege protected-environment GitHub App/token with exactly the organization/repository Administration authority required for these rulesets, unavailable to pull-request code and model processes.

Primary GitHub reference: REST API endpoints for rules — organization rulesets, including the update endpoint and permission contract: https://docs.github.com/en/rest/orgs/rules

Acceptance

  1. fix(governance): enforce satisfiable solo-maintainer rulesets #1176's then-current exact head reaches terminal deterministic review/security/quality evidence and its final tree remains limited to intended governance source paths relative to protected main.
  2. An authorized owner-plane mutation changes organization ruleset 18156473 to the current target without weakening required workflows, scope, deletion/non-fast-forward protection, stale-review handling, or thread resolution.
  3. An authorized owner-plane mutation removes rebase and routine OrganizationAdmin/always bypass from repository ruleset 17921150 while preserving the remaining controls.
  4. Fresh full-payload reads prove both rulesets match the target. A settings source file, workflow definition, or successful API status alone is insufficient.
  5. An unchanged deterministic-GREEN sole-author canary such as Orgmetra 🛡️ Sentinel: [CRITICAL] CI 게이트 우회 방지를 위한 Python JSON 정규화 강제 적용 #88 can proceed through the ordinary protected merge path without a nonexistent independent human and without administrator bypass.
  6. A negative canary remains blocked by any genuine failed/absent required workflow or unresolved required review thread.
  7. If emergency bypass capability is retained elsewhere, evidence identifies activation authority, exact SHA, reason, bounded window, and post-event review; steady-state always bypass is absent.

Do not direct-push, self-approve, synthesize approval, reuse reviewer/model credentials, broaden CWL_REPOSITORY_METADATA_TOKEN, use current_user_can_bypass=always, or lower deterministic gate requirements to make the control plane pass.

Activity

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    area: ci-cdCI, GitHub Actions, checks, release, or supply chainarea: securitySecurity boundary, hardening, or vulnerability preventionpriority: criticalImmediate blocker, P0, urgent deadlock, or critical incidentstatus: blockedBlocked by conflict, dependency, or required prerequisitetype: maintenanceMaintenance, build, dependency, or operational upkeep

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions