Skip to content

fix(deps): require certifi 2026.10.19 to drop compromised emSign CAs - #201

Merged
MarTrepodi merged 1 commit into
developfrom
fix/require-patched-certifi
Oct 22, 2026
Merged

MarTrepodi merged 1 commit into
developfrom
fix/require-patched-certifi

Conversation

@MarTrepodi

Copy link
Copy Markdown
Collaborator

Summary

Fixes the critical Dependabot alert for GHSA-6q48-6c7w-9gw2. certifi before 2026.10.18 trusts the emSign ECC Root CA - G3, whose eight intermediates had compromised private keys. httpx verifies every connection against certifi's bundle, so an on-path attacker holding one of those keys could intercept the client's TLS traffic.

certifi was only an indirect dependency (through httpx), so upgrading swgoh-comlink never upgraded it. pip's default only-if-needed strategy leaves an installed dependency alone while it still satisfies the requirements. This PR declares it directly:

 dependencies = [
+    "certifi>=2026.10.19",   # with a comment: not imported; httpx's CA bundle
     "httpx>=0.28",
     "typing-extensions>=4.15.0",
 ]
  • uv.lock: certifi 2026.5.20 → 2026.10.19. 2026.10.19 is the release that restores the emSign roots that weren't affected, so it's the floor rather than 2026.10.18.
  • The revision = 3 → 5 change in uv.lock is the same back-and-forth as earlier hand-made lockfile edits (Dependabot writes 3). CI's unpinned setup-uv reads both.

Evidence

  • Before: uv.lock pins certifi 2026.5.20, inside the vulnerable range >= 2019.03.09, < 2026.10.19, and alert General cleanup and example addition #31 is open.
    After: uv lock --upgrade-package certifi → Updated certifi v2026.5.20 -> v2026.10.19. Locally certifi.__version__ == "2026.10.19", and httpx.create_ssl_context() builds against it. 1556 unit tests pass, and ruff and ty are clean.

Merge Danger

Door: two-way. Dependency metadata only, with no code changes.

Blast Radius: small. Any user with an older certifi gets it upgraded when they upgrade this package. An environment that pins certifi<2026.10.19 (for example a frozen container) will fail to resolve. That's intended: it surfaces the vulnerable pin instead of silently keeping it.

Related Issues

Resolves Dependabot alert #31 once released to main.

Type of Change

  • Bug fix (non-breaking change that fixes an issue)
  • New feature (non-breaking change that adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)
  • Refactor (code change that neither fixes a bug nor adds a feature)
  • Performance improvement
  • Documentation
  • Tests
  • CI / build / dependencies

Checklist

  • This PR targets the develop branch (only release PRs target main)
  • My commits follow the Conventional Commits / Angular convention (feat:, fix:, refactor:, etc.) — they become the changelog
  • I have not edited CHANGELOG.md by hand (it is generated from commit messages)
  • I have added/updated docstrings with type hints for any new or changed public methods
  • I have updated the docs (README.md, docs/, examples/) if user-facing behavior changed
  • I have added unit tests that cover my changes (mocked, not requiring a live comlink service)
  • Tests pass (uv run pytest tests/)
  • Ruff linter and formatter pass (uv run ruff check src/ tests/ and uv run ruff format --check src/ tests/)
  • Type check passes (uv run ty check src/swgoh_comlink/)
  • I have not bundled unrelated changes in this PR

🤖 Generated with Claude Code

certifi releases before 2026.10.18 trust the emSign ECC Root CA - G3,
whose eight intermediates had their private keys compromised and were
revoked (GHSA-6q48-6c7w-9gw2, critical). httpx verifies every
connection against certifi's bundle, so an on-path attacker holding one
of those keys could intercept the client's TLS traffic.

certifi was only a transitive dependency through httpx, so upgrading
swgoh-comlink never moved it: pip's only-if-needed strategy leaves an
installed version alone while it satisfies the requirements. Declare it
directly with a floor of 2026.10.19, the release that restores the
unaffected emSign roots, so an upgrade now brings the fixed bundle. The
lockfile moves to the same version.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@github-actions github-actions Bot added the dependencies Updates to package dependency libraries label Oct 22, 2026
@MarTrepodi
MarTrepodi enabled auto-merge October 22, 2026 16:40
@MarTrepodi
MarTrepodi merged commit a29b574 into develop Oct 22, 2026
16 checks passed
@MarTrepodi
MarTrepodi deleted the fix/require-patched-certifi branch October 22, 2026 16:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

dependencies Updates to package dependency libraries

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant