Skip to content

Add live CA-certificate mitigation tools for COS and GKE - #79

Merged
SergeyKanzhelev merged 1 commit into
GoogleCloudPlatform:masterfrom
chenglongtang1:cos-ca-cert-mitigation
Oct 22, 2026
Merged

SergeyKanzhelev merged 1 commit into
GoogleCloudPlatform:masterfrom
chenglongtang1:cos-ca-cert-mitigation

Conversation

@chenglongtang1

Copy link
Copy Markdown
Contributor

Summary

Adds cos-ca-cert-mitigation/ providing live mitigation tools to distrust the compromised eMudhra (emSign) root CAs and the cross-signing AAA Certificate Services (Comodo_AAA_Services_root.crt) root CA on running Container-Optimized OS (COS) instances and GKE Standard (COS_CONTAINERD) nodes before upgrading to patched OS images.

What's Included

File Description
cos-ca-cert-mitigation/cos/mitigate_cos_ca_certs.sh Standalone, idempotent live-VM mitigation script for COS GCE instances.
cos-ca-cert-mitigation/gke/cos-ca-cert-mitigation.yaml Privileged Kubernetes DaemonSet (kube-system/cos-ca-cert-mitigator) that applies the mitigation across all existing and newly autoscaled COS nodes in a GKE Standard cluster without rebooting nodes or disrupting running pods.
cos-ca-cert-mitigation/README.md Deployment, verification, and cleanup instructions for GKE Standard clusters and standalone COS GCE VMs.

How the Mitigation Works

  1. System CA Store (/etc/ca-certificates.conf & /etc/ssl/certs):
    • Deselects mozilla/emSign_*.crt and mozilla/Comodo_AAA_Services_root.crt in /etc/ca-certificates.conf and runs update-ca-certificates --fresh.
    • Mitigates host OpenSSL/C/C++ consumers (curl, wget, git, oslogin, systemd, chrony), host Python (certifi, urllib3, requests, cloud-init), and Go crypto/x509 CLIs (kubectl, crictl, ctr, docker).
  2. Read-Only /usr Trust Stores (dm-verity):
    • Masks /usr/share/chromeos-ca-certificates/Comodo_AAA_Services_root.pem with /dev/null (mitigating update_engine, libbrillo, and crash_sender).
    • Bind-mounts the regenerated /etc/ssl/certs/ca-certificates.crt over /usr/share/grpc/roots.pem if present.
  3. Built-In Container Utilities (toolbox & cos-extensions):
    • Updates TOOLBOX_DOCKER_TAG="v20261020" in /etc/default/toolbox.
    • Wraps /usr/bin/cos-extensions via /run/cos-mitigation so cos-extensions install gpu defaults to gcr.io/cos-cloud/cos-gpu-installer:v2.7.11.
  4. Active Host Daemons:
    • Restarts active host services (containerd, docker, kubelet, fluent-bit, update-engine, node-problem-detector, google-guest-agent*, google-osconfig-agent, device_policy_manager) so long-running Go and C/C++ processes reload /etc/ssl/certs/ca-certificates.crt in-place.

Testing

Verified end-to-end (pre-mitigation, post-mitigation, idempotency re-run, and post-reboot) across:

  • GCE VMs: cos-117-lts, cos-121-lts, cos-125-lts, cos-129-lts, cos-133-lts, and cos-dev (M138)
  • GKE Standard Cluster: COS_CONTAINERD node pool (verified DaemonSet rollout and zero workload pod restarts)

@chenglongtang1

Copy link
Copy Markdown
Contributor Author

cc @rkolchmeyer @SergeyKanzhelev @chrishenzie for review

@rkolchmeyer

Copy link
Copy Markdown
Contributor

dont think i have approval permission, but -

/lgtm

@zicongmei

Copy link
Copy Markdown
Collaborator

/lgtm

Add `cos-ca-cert-mitigation/` providing live mitigation tools to distrust
compromised eMudhra (`emSign`) root CAs and the cross-signing
`AAA Certificate Services` (`Comodo_AAA_Services_root.crt`) root CA on
running Container-Optimized OS (COS) instances and GKE Standard nodes:

- `cos-ca-cert-mitigation/cos/mitigate_cos_ca_certs.sh`: Standalone live-VM
  mitigation script that updates `/etc/ca-certificates.conf` and
  `/etc/ssl/certs`, masks read-only `/usr` trust stores
  (`chromeos-ca-certificates` and `grpc`), updates default container image
  tags for `toolbox` (`v20261020`) and `cos-extensions`
  (`cos-gpu-installer:v2.7.11`), and restarts active host daemons.
- `cos-ca-cert-mitigation/gke/cos-ca-cert-mitigation.yaml`: Privileged
  Kubernetes DaemonSet (`kube-system/cos-ca-cert-mitigator`) to apply the
  mitigation across all existing and newly autoscaled COS nodes in a GKE
  Standard cluster without rebooting nodes or evicting pods.
- `cos-ca-cert-mitigation/README.md`: Deployment, verification, and cleanup
  instructions for GKE Standard clusters and standalone COS GCE VMs.

Signed-off-by: Chenglong Tang <chenglongtang@google.com>
@SergeyKanzhelev
SergeyKanzhelev merged commit bbe7583 into GoogleCloudPlatform:master Oct 22, 2026
6 checks passed
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.

4 participants