GitHub runs no CI in an advisory's temporary private fork, and merging from the advisory skips branch protection, so a security fix reached main with nothing having run on it. The incident-response process now records where the fix is verified instead, how the mirror is kept in step with the public branches, and why the mirror must never hold the public registry credentials: pull request CI pushes the full chart tree to an anonymously readable registry, which would publish the fix before the release. Without those credentials a mirror run of any code change is red at the registry login, so the process names the jobs that must pass instead of asking for a green run. It records the main commit the run was based on and asks for a rerun when main has moved before the merge, because a change elsewhere on main can break the fix without a merge conflict. It also records what a sync still starts: a release line carries the workflows it was cut with, so pushing one runs its build there, and a tag cut before the guard runs tags.yaml unguarded, which is why tags are never synced. Signed-off-by: Alexey Artamonov <aleksei.artamonov@aenix.io> Assisted-by: LLM
7.4 KiB
Incident Response
This document is the public summary of how the Cozystack maintainers respond to a confirmed security vulnerability or incident. Detailed operational procedures (contact trees, credential inventories, and step-by-step checklists) are maintained privately by the maintainers; this page describes the process and the mechanisms it relies on so that reporters and users know what to expect.
It complements, and does not replace:
SECURITY.md— how to report a vulnerability, response commitments, and the disclosure timeline.CONTRIBUTOR_LADDER.md— the offboarding procedure, including access revocation and credential rotation.
Roles
For each incident the maintainers designate:
- Incident lead — a maintainer (typically a core maintainer) who coordinates triage, the fix, the release, and disclosure, and keeps the reporter informed.
- Comms owner — responsible for the public advisory and release-notes wording, and for any coordination with upstream projects and CNCF.
- Fix owner(s) — the maintainer(s) developing and reviewing the fix.
One person may hold more than one role on a small incident.
Lifecycle
- Intake. A report arrives through GitHub Private Vulnerability Reporting or
a private maintainer contact (see
SECURITY.md). Receipt is acknowledged within 3 business days. - Triage and severity. The maintainers reproduce the issue and assign a
CVSS v3.1 severity within 7 business days. This drives the remediation
target and disclosure window (see
SECURITY.md→ Disclosure timeline). - Containment. Where an immediate mitigation or workaround exists (a configuration change, a policy, or disabling an affected feature), it is documented and shared with the reporter and, if warranted, with affected adopters under embargo.
- Private fix development. The fix is developed under a GitHub Security Advisory (private fork) so that code and discussion stay confidential until release. CI does not run there, so the fix is verified in the embargo mirror described under Verifying a private fix before it is merged from the advisory.
- Coordinated release. The fix is shipped through the normal patch-release and backport process: the backport batch carries it onto the supported lines, the two latest minor releases, newest first, by the rules in
docs/release/backports.md, which a maintainer can override for a single fix. See the Supported Versions table inSECURITY.md. - Disclosure. A GHSA — and, when applicable, a CVE — is published. Public
disclosure follows the outbound channels: GitHub Releases and release notes,
the changelog, and the GHSA itself. The reporter is credited unless anonymity
is requested. Disclosure happens no later than the coordinated-disclosure
window committed in
SECURITY.md. - Access and credential hygiene. If the incident involved a compromised or
departing maintainer or leaked credential, the access-revocation and
credential-rotation steps in
CONTRIBUTOR_LADDER.mdare executed (GitHub team access, org roles, Actions secrets, registry tokens, and App keys), completed within five business days. - Retrospective. After resolution the maintainers record what happened, the root cause, and any follow-up hardening, and open tracking issues for preventative work.
Verifying a private fix
GitHub runs no CI in an advisory's temporary private fork: status checks do not run on its pull requests and no integration can reach it. Merging from the advisory also skips branch protection, so the required checks on main are not asked for either. The fix is therefore verified in a separate private repository, the embargo mirror, and the run there stands in for the checks the merge skips.
- Sync the mirror right before use, not continuously: push the current
mainand every affectedrelease-X.Ybranch fromcozystack/cozystackto the mirror, so the fix is tested on the same base it will be merged into. Push branches by name and never tags: a pushed tag runstags.yamlas the tagged commit carries it, and a tag cut before the guard below existed carries none, so the mirror would build a release. - Open the pull request inside the mirror from the same fix branch as the advisory's pull request, and wait for its CI.
- Record the run in the advisory: a link to it, the
maincommit the mirror was synced to, and the head commit of the mirror's pull request, which must be the head commit of the advisory's pull request. CI checks out the pull request merged into its base rather than the head itself, and the merge from the advisory creates yet another commit onmain, so the two pull request heads are what to compare. The run as a whole is red by design for any code change, because the mirror holds no registry credentials:Finalize, andBuildorBuild Taloswhen they are selected, fail at the registry login and E2E never starts. What must be green isPlan buildandUnit & controller testsin thePull Requestworkflow, andpre-commitandCommit trailersinPre-Commit Checks. - Merge from the advisory. First compare the recorded
maincommit with the currentmain. Ifmainhas moved, sync and run again before merging, then merge without waiting: a change elsewhere onmaincan break the fix without causing a merge conflict, so a run on an older base proves nothing about the newer one. The merge lands on whatevermainis at that moment, so the CI that runs onmainafter the merge stays the final check.
Every job of a workflow that a push or a schedule starts is guarded to run only in cozystack/cozystack, so syncing main to the mirror does not build, publish, prune or release from it; hack/workflow-repo-guard.bats holds every such workflow to that guard. A push runs the workflows of the branch that was pushed, though, and the guard is on main only: a release line carries the workflows it was cut with, so pushing release-X.Y to the mirror starts that line's build-release.yaml there until the guard reaches the line. With registry credentials kept out of the mirror, as below, that build cannot publish anything and fails at its registry login, but it still occupies a runner.
Pull request workflows still run, which is what the mirror is for. CodeQL needs reading with care: code scanning on a private repository needs a GitHub Code Security license, so without one it fails in the mirror for a reason unrelated to the fix. It is a required check on main, but merging from the advisory skips branch protection, so a red CodeQL in the mirror does not block the merge; it runs on main after the merge.
The mirror must not be given the credentials of the public image registry. Pull request CI pushes every image it builds and the packages artifact, which carries the full chart tree, to that registry, and the registry is anonymously readable, tag listing included, so a run there would publish the fix before the release. Until pull request CI can push to a private registry instead, the mirror verifies only the jobs step 3 lists, and the E2E suite runs after the merge.
Severity and timelines
Severity classification (CVSS v3.1) and the target remediation and disclosure
timelines are defined once, authoritatively, in
SECURITY.md → Disclosure timeline. They are not
duplicated here to avoid drift.