{"schema":"threatline.record/2","record":{"id":"GHSA-v853-p72q-4cfw","aliases":["GHSA-v853-p72q-4cfw"],"summary":"Quart leaks raw request body (incl. plaintext passwords) to stdout via stray debug print in Body.__await__","details":"### Summary\nQuart 0.23.0 contains a stray debug statement (`print(data)`) inside `Body.__await__` in `quart/wrappers/request.py`. Any request whose body is awaited — `await request.form`, `await request.get_data()`, WTForms `validate_on_submit()`, etc. — has its raw, unparsed body printed to stdout, including plaintext form fields such as passwords and CSRF tokens. Confirmed present in 0.23.0, confirmed absent in 0.22.0.\n\n### Details\nIn `src/quart/wrappers/request.py`, `Body.__await__` accumulates the request body into a bytearray:\n\n​```python\ndata = bytearray()\nwhile not self._queue.empty():\n    data.extend(self._queue.get_nowait())\n    print(data)          # <-- not present in 0.22.0\n    if (\n        self._max_content_length is not None\n        and len(data) > self._max_content_length\n    ):\n        raise RequestEntityTooLarge()\n​```\n\nThis fires for every request that awaits its body — the overwhelming majority of POST/PUT routes in a typical Quart app (form submissions, JSON APIs via `request.get_json()`, file uploads, etc.).\n\n### PoC\n1. `pip install quart==0.23.0` (requires Python 3.13+)\n2. Minimal route:\n​```python\n@app.route(\"/login\", methods=[\"POST\"])\nasync def login():\n    form_data = await request.form\n    ...\n​```\n3. Submit a POST with form data, e.g. a login form with `staff_id`/`password` fields.\n4. Observe stdout: the full raw body is printed as `bytearray(b'csrf_token=...&staff_id=...&password=...')`.\n\nConfirmed via source diff against 0.22.0's `request.py`, where this line does not exist.\n\n### Impact\nAny app that captures stdout in logs (terminal redirect, systemd/journald, Docker logs, cloud log aggregation, etc.) will have every submitted form body — including login credentials — written to logs in plaintext. This affects any Quart 0.23.0 app handling authentication or any sensitive form data, and is trivially triggerable by any user simply submitting a form (no attacker action required beyond normal use).","categories":["Libraries & packages"],"product":"quart","vendor":"","ecosystem":"pip","affected_ranges":[{"source":"GitHub Advisory Database","source_url":"https://github.com/advisories/GHSA-v853-p72q-4cfw","source_modified_at":"2026-10-05T22:49:45Z","fetched_at":"2026-10-23T18:42:43.628194Z","package":{"ecosystem":"pip","name":"quart"},"range":"= 0.23.0"},{"source":"OSV","source_url":"https://osv.dev/vulnerability/GHSA-v853-p72q-4cfw","source_modified_at":"2026-10-05T23:00:06.312824059Z","fetched_at":"2026-10-23T18:45:31.882637Z","package":{"name":"quart","ecosystem":"PyPI","purl":"pkg:pypi/quart"},"ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0.23.0"},{"fixed":"0.23.1"}]}],"versions":["0.23.0"]}],"fixed_versions":[{"source":"GitHub Advisory Database","source_url":"https://github.com/advisories/GHSA-v853-p72q-4cfw","source_modified_at":"2026-10-05T22:49:45Z","fetched_at":"2026-10-23T18:42:43.628194Z","package":{"ecosystem":"pip","name":"quart"},"version":"0.23.1"},{"source":"OSV","source_url":"https://osv.dev/vulnerability/GHSA-v853-p72q-4cfw","source_modified_at":"2026-10-05T23:00:06.312824059Z","fetched_at":"2026-10-23T18:45:31.882637Z","package":{"name":"quart","ecosystem":"PyPI","purl":"pkg:pypi/quart"},"version":"0.23.1"}],"cvss":7.5,"severity":"High","kev":{"listed":false},"epss":{"probability":null,"percentile":null,"score_date":null},"published_at":"2026-10-05T22:49:44Z","modified_at":"2026-10-05T23:00:06.312824059Z","provenance":[{"source":"GitHub Advisory Database","url":"https://github.com/advisories/GHSA-v853-p72q-4cfw","fetched_at":"2026-10-23T18:42:43.628194Z","source_modified_at":"2026-10-05T22:49:45Z"},{"source":"OSV","url":"https://osv.dev/vulnerability/GHSA-v853-p72q-4cfw","fetched_at":"2026-10-23T18:45:31.882637Z","source_modified_at":"2026-10-05T23:00:06.312824059Z"}],"sources":["GitHub Advisory Database","OSV"],"references":[{"url":"https://github.com/pallets/quart/security/advisories/GHSA-v853-p72q-4cfw","source":"GitHub Advisory Database"},{"url":"https://github.com/pallets/quart/commit/e8eb3b8a0cb98e7574bf3841312fc7f96883d055","source":"GitHub Advisory Database"},{"url":"https://github.com/pallets/quart/releases/tag/0.23.1","source":"GitHub Advisory Database"},{"url":"https://github.com/advisories/GHSA-v853-p72q-4cfw","source":"GitHub Advisory Database"}],"locations":[],"motoko_assessment":{"status":"requires_architecture_review","automatic_remediation":false},"classification":{"method":"product-first software-layer rules","rules_version":"2.1","matched_on":"ecosystem","confidence":"heuristic","reviewed":false},"change_timestamp":"2026-10-05T23:00:06.312824059Z","content_hash":"4095fbfb7aa19370adce9d10b8ffc1d8930886909fae70fa1b7c45f78e18cb30"}}
