Repository navigation
fix(deps): Bump idna to 3.20 to fix a DoS from crafted DSN hosts - #148
Merged
Merged
Conversation
armenzg
approved these changes
Nov 6, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Category: vulnerable runtime dependency. I found no open application security issue that isn't already covered. The one candidate left, an org-controlled DSN host that the app POSTs to (SSRF), is already proposed in #89.
Vulnerability.
uv.lockpinsidna3.6, whichrequestsandurllib3pull in. That version has quadratic-timeidna.encode()on crafted non-ASCII hostnames: CVE-2024-3651, and the incomplete fix tracked as CVE-2026-45409 / GHSA-65pc-fj4g-8rjx, fixed in 3.15.How the app reaches it. The DSN comes from the installing org's own
.sentry/sentry_config.ini.GithubClientaccepts any host thatsentry_sdk.utils.Dsnparses. Thenrequests.post(self.sentry_project_url)in_send_enveloperunsurllib3/requestsURL normalization, which callsidna.encode()on a non-ASCII host. The config is cached, but eachworkflow_jobwebhook builds and posts a new envelope, so the cost comes back on every job.Severity: medium (availability). Measured locally with the locked dependencies, preparing the envelope POST for a DSN host of N
"\u0660"characters took:InvalidURL)The image runs one gunicorn worker with 4 threads and
--timeout 0, so a stuck request never gets killed. One org with a large job matrix could keep the instance's CPU and threads busy, and every other installation's webhooks would be delayed or dropped. Cloud Run would also scale out on the load. The attacker needs to install the GitHub App and push a.sentryrepo. My inference that third parties can do this rests on two observations:https://github.com/apps/sentry-github-app-alphareturns 200 without logging in, and production events show envelopes going to non-Sentry DSN hosts. Eventf950db04e5d44c739338508b09c01e09(SENTRY-GITHUB-ACTIONS-APP-8B, 2026-11-05) is a connect timeout to an arbitrary third-party host taken from an org's DSN. I found no sign that anyone has exploited this.Fix.
uv lock --upgrade-package idna(3.6 → 3.20). No code changes. The Docker image installs with--locked, so the patched version ships with the next image.Verification.
uv run pytest: 84 passed.uv run mypy: clean.uv run pre-commit run --all-files: passed.pip-auditon the exported production requirements no longer reportsidna. It still reportsflask(sessionVary: Cookie; the app doesn't use sessions),jinja2(the app doesn't render templates), andwerkzeug(safe_joinon Windows; the app runs on Linux and doesn't serve files). None of these are reachable here, so this PR leaves them alone.via automation
sched_2663accc24a4cb8adfb43de4543ec71e· Run IDsched_2663accc24a4cb8adfb43de4543ec71e:1793968200000.--
View Session [Sentry]