{"id":"CVE-2024-34084","aliases":["CVE-2024-34084","GHSA-9c5w-9q3f-3hv7","GO-2024-2821"],"related":[],"kind":"vulnerability","state":"published","title":"Minder's Github Webhook Handler vulnerable to denial of service from un-validated requests","summary":"Minder's `HandleGithubWebhook` is susceptible to a denial of service attack from an untrusted HTTP request. The vulnerability exists before the request has been validated, and as such the request is still untrusted at the point of failure. This allows an attacker with the ability to send requests to `HandleGithubWebhook` to crash the Minder controlplane and deny other users from using it. This vulnerability is fixed in 0.0.48.","summarySource":"cvelist","descriptions":[{"lang":"en","text":"Minder's `HandleGithubWebhook` is susceptible to a denial of service attack from an untrusted HTTP request. The vulnerability exists before the request has been validated, and as such the request is still untrusted at the point of failure. This allows an attacker with the ability to send requests to `HandleGithubWebhook` to crash the Minder controlplane and deny other users from using it. This vulnerability is fixed in 0.0.48.","source":"cvelist"},{"lang":"en","text":"Minder's `HandleGithubWebhook` is susceptible to a denial of service attack from an untrusted HTTP request. The vulnerability exists before the request has been validated, and as such the request is still untrusted at the point of failure. This allows an attacker with the ability to send requests to `HandleGithubWebhook` to crash the Minder controlplane and deny other users from using it.\n\nOne of the first things that `HandleGithubWebhook` does is to validate the payload signature. This is done by way of the internal helper `validatePayloadSignature`:\n\nhttps://github.com/stacklok/minder/blob/ee66f6c0763212503c898cfefb65ce1450c7f5ac/internal/controlplane/handlers_githubwebhooks.go#L213-L218\n\n`validatePayloadSignature` generates a reader from the incoming request by way of the internal helper `readerFromRequest`:\n\nhttps://github.com/stacklok/minder/blob/ee66f6c0763212503c898cfefb65ce1450c7f5ac/internal/controlplane/handlers_githubwebhooks.go#L337-L342\n\nTo create a reader from the incoming request, `readerFromRequest` first reads the request body entirely into memory on line 368:\n\nhttps://github.com/stacklok/minder/blob/ee66f6c0763212503c898cfefb65ce1450c7f5ac/internal/controlplane/handlers_githubwebhooks.go#L367-L377\n\nThis is a vulnerability, since an HTTP request with a large body can exhaust the memory of the machine running Minder and cause the Go runtime to crash Minder.\n\nNote that this occurs before Minder has validated the request, and as such, the request is still untrusted.\n\nTo test this out, we can use the existing `TestHandleWebHookRepository` unit test and modify the HTTP request body to be large. \n\nTo do that, change these lines:\n\nhttps://github.com/stacklok/minder/blob/ee66f6c0763212503c898cfefb65ce1450c7f5ac/internal/controlplane/handlers_githubwebhooks_test.go#L278-L283\n\n... to these lines:\n```go\n\tpackageJson, err := json.Marshal(event)\n\trequire.NoError(t, err, \"failed to marshal package event\")\n\n        maliciousBody := strings.NewReader(strings.Repeat(\"1337\", 1000000000))\n        maliciousBodyReader := io.MultiReader(maliciousBody, maliciousBody, maliciousBody, maliciousBody, maliciousBody)\n        _ = packageJson\n\n\tclient := &http.Client{}\n\treq, err := http.NewRequest(\"POST\", fmt.Sprintf(\"http://%s\", addr), maliciousBodyReader)\n\trequire.NoError(t, err, \"failed to create request\")\n```\n\nThen run the unit test again. WARNING, SAVE ALL WORK BEFORE DOING THIS.\n\nOn my local machine, this causes the machine to freeze, and Go finally performs a sigkill: \n\n```\nsignal: killed\nFAIL      github.com/stacklok/minder/internal/controlplane          30.759s\nFAIL\n```","format":"markdown","source":"ghsa"},{"lang":"en","text":"HandleGithubWebhook is susceptible to a denial of service attack from an untrusted HTTP request. An untrusted request can cause the server to allocate large amounts of memory resulting in a denial of service.","format":"markdown","source":"go"},{"lang":"es","text":"El `HandleGithubWebhook` de Minder es susceptible a un ataque de denegación de servicio procedente de una solicitud HTTP que no es de confianza. La vulnerabilidad existe antes de que se haya validado la solicitud y, como tal, la solicitud aún no es confiable en el momento del error. Esto permite que un atacante con la capacidad de enviar solicitudes a \"HandleGithubWebhook\" bloquee el plano de control de Minder y niegue a otros usuarios su uso. Esta vulnerabilidad se solucionó en 0.0.48.","source":"nvd"}],"published":"2024-05-07T13:02:42.000Z","modified":"2026-09-10T03:50:13.671Z","severity":{"scorer":"GitHub_M","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H","score":7.5,"rating":"HIGH"},"severities":[{"scorer":"GitHub_M","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H","score":7.5,"rating":"HIGH"},{"scorer":"GitHub","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H","score":7.5,"rating":"HIGH"}],"cwes":["CWE-400"],"affected":[{"ranges":[{"version":"< 0.0.48","status":"affected"}],"vendor":"stacklok","product":"minder","source":"cvelist"},{"ranges":[{"type":"custom","introduced":"0","fixed":"0.0.48","status":"affected"}],"vendor":"stacklok","product":"minder","cpe":"cpe:2.3:a:stacklok:minder:*:*:*:*:*:*:*:*","source":"cvelist"},{"ranges":[{"type":"semver","introduced":"0","status":"affected","fixed":"0.0.48"}],"ecosystem":"Go","package":"github.com/stacklok/minder","purl":"pkg:golang/github.com/stacklok/minder","source":"ghsa"},{"ranges":[{"type":"semver","introduced":"0","status":"affected","fixed":"0.0.48"}],"ecosystem":"Go","package":"github.com/stacklok/minder","purl":"pkg:golang/github.com/stacklok/minder","source":"go"}],"references":[{"url":"https://github.com/stacklok/minder/security/advisories/GHSA-9c5w-9q3f-3hv7","tags":["advisory","web","x-refsource-confirm","x-transferred"],"sources":["cvelist","ghsa","go","nvd"]},{"url":"https://github.com/stacklok/minder/commit/3e5a527d2f1b535159206161d1d519602c75bd0d","tags":["fix","web","x-refsource-misc","x-transferred"],"sources":["cvelist","ghsa","go","nvd"]},{"url":"https://nvd.nist.gov/vuln/detail/CVE-2024-34084","tags":["advisory"],"sources":["ghsa"]},{"url":"https://github.com/stacklok/minder","tags":["package"],"sources":["ghsa"]},{"url":"https://github.com/stacklok/minder/blob/ee66f6c0763212503c898cfefb65ce1450c7f5ac/internal/controlplane/handlers_githubwebhooks.go#L213-L218","tags":["web"],"sources":["ghsa","go"]},{"url":"https://github.com/stacklok/minder/blob/ee66f6c0763212503c898cfefb65ce1450c7f5ac/internal/controlplane/handlers_githubwebhooks.go#L337-L342","tags":["web"],"sources":["ghsa","go"]},{"url":"https://github.com/stacklok/minder/blob/ee66f6c0763212503c898cfefb65ce1450c7f5ac/internal/controlplane/handlers_githubwebhooks.go#L367-L377","tags":["web"],"sources":["ghsa","go"]},{"url":"https://github.com/stacklok/minder/blob/ee66f6c0763212503c898cfefb65ce1450c7f5ac/internal/controlplane/handlers_githubwebhooks_test.go#L278-L283","tags":["web"],"sources":["ghsa","go"]}],"credits":["@AdamKorcz and @DavidKorczynski"],"assigner":"GitHub_M","ssvc":{"scorer":"CISA-ADP","exploitation":"poc","automatable":"yes","technicalImpact":"partial","date":"2024-05-07T18:05:18.956Z"},"sources":[{"source":"cvelist","name":"CVE List","id":"CVE-2024-34084","url":"https://www.cve.org/CVERecord?id=CVE-2024-34084","licence":"CVE Terms of Use","modified":"2024-08-02T02:42:59.894Z"},{"source":"ghsa","name":"GitHub Advisory Database","id":"GHSA-9c5w-9q3f-3hv7","url":"https://github.com/advisories/GHSA-9c5w-9q3f-3hv7","licence":"CC-BY-4.0","modified":"2026-09-10T03:50:13.671Z"},{"source":"go","name":"Go Vulnerability Database","id":"GO-2024-2821","url":"https://pkg.go.dev/vuln/GO-2024-2821","licence":"CC-BY-4.0","modified":"2024-05-20T16:03:47.000Z"},{"source":"nvd","name":"NVD","id":"CVE-2024-34084","url":"https://nvd.nist.gov/vuln/detail/CVE-2024-34084","licence":"Public domain","modified":"2026-06-17T07:32:52.450Z"}],"updatedAt":"2026-11-25T22:58:40.040Z","epss":{"score":0.00872,"percentile":0.56587,"date":"2026-11-30T12:00:22.000Z"}}