{"id":"CVE-2019-16785","aliases":["CVE-2019-16785","GHSA-pg36-wpm5-g57p","PYSEC-2019-136"],"related":[],"kind":"vulnerability","state":"published","title":"HTTP Request Smuggling: LF vs CRLF handling in Waitress","summary":"Waitress through version 1.3.1 implemented a \"MAY\" part of the RFC7230 which states: \"Although the line terminator for the start-line and header fields is the sequence CRLF, a recipient MAY recognize a single LF as a line terminator and ignore any preceding CR.\" Unfortunately if a front-end server does not parse header fields with an LF the same way as it does those with a CRLF it can lead to the front-end and the back-end server parsing the same HTTP message in two different ways. This can lead to a potential for HTTP request smuggling/splitting whereby Waitress may see two requests while the front-end server only sees a single HTTP message. This issue is fixed in Waitress 1.4.0.","summarySource":"cvelist","descriptions":[{"lang":"en","text":"Waitress through version 1.3.1 implemented a \"MAY\" part of the RFC7230 which states: \"Although the line terminator for the start-line and header fields is the sequence CRLF, a recipient MAY recognize a single LF as a line terminator and ignore any preceding CR.\" Unfortunately if a front-end server does not parse header fields with an LF the same way as it does those with a CRLF it can lead to the front-end and the back-end server parsing the same HTTP message in two different ways. This can lead to a potential for HTTP request smuggling/splitting whereby Waitress may see two requests while the front-end server only sees a single HTTP message. This issue is fixed in Waitress 1.4.0.","source":"cvelist"},{"lang":"en","text":"### Impact\n\nWaitress implemented a &amp;quot;MAY&amp;quot; part of the RFC7230 (https://tools.ietf.org/html/rfc7230#section-3.5) which states:\n\n      Although the line terminator for the start-line and header fields is\n      the sequence CRLF, a recipient MAY recognize a single LF as a line\n      terminator and ignore any preceding CR.\n\nUnfortunately if a front-end server does not parse header fields with an LF the same way as it does those with a CRLF it can lead to the front-end and the back-end server parsing the same HTTP message in two different ways. This can lead to a potential for HTTP request smuggling/splitting whereby Waitress may see two requests while the front-end server only sees a single HTTP message.\n\nExample:\n\n```\nContent-Length: 100[CRLF]\nX-Header: x[LF]Content-Length: 0[CRLF]\n```\n\nWould get treated by Waitress as if it were:\n\n```\nContent-Length: 100\nX-Header: x\nContent-Length: 0\n```\n\nThis could potentially get used by attackers to split the HTTP request and smuggle a second request in the body of the first.\n\n\n### Patches\n\nThis issue is fixed in Waitress 1.4.0. This brings a range of changes to harden Waitress against potential HTTP request confusions, and may change the behaviour of Waitress behind non-conformist proxies. \n\nWaitress no longer implements the MAY part of the specification and instead requires that all lines are terminated correctly with CRLF. If any lines are found with a bare CR or LF a 400 Bad Request is sent back to the requesting entity.\n\nThe Pylons Project recommends upgrading as soon as possible, while validating that the changes in Waitress don&amp;#39;t cause any changes in behavior.\n\n### Workarounds\n\nVarious reverse proxies may have protections against sending potentially bad HTTP requests to the backend, and or hardening against potential issues like this. If the reverse proxy doesn&amp;#39;t use HTTP/1.1 for connecting to the backend issues are also somewhat mitigated, as HTTP pipelining does not exist in HTTP/1.0 and Waitress will close the connection after every single request (unless the Keep Alive header is explicitly sent... so this is not a fool proof security method)\n\n### Issues/more security issues:\n\n* open an issue at https://github.com/Pylons/waitress/issues (if not sensitive or security related)\n* email the Pylons Security mailing list: pylons-project-security@googlegroups.com (if security related)","format":"markdown","source":"ghsa"},{"lang":"es","text":"Waitress versión hasta 1.3.1, implementó una parte \"MAY\" del RFC7230 que declara: \"Aunque el terminador de línea para los campos de línea de inicio y encabezado es la secuencia CRLF, un receptor PUEDE reconocer un LF único como un terminador de línea e ignorar cualquier CR anterior\". Desafortunadamente, si un servidor front-end no analiza los campos de encabezado con un LF de igual forma que los que tienen un CRLF, puede conllevar a que el servidor front-end y el back-end analice el mismo mensaje HTTP de dos maneras diferentes. Esto puede conllevar a un posible tráfico no autorizado y una división de peticiones HTTP, por lo que Waitress puede visualizar dos peticiones mientras que el servidor front-end solo visualiza un solo mensaje HTTP. Este problema fue corregido en Waitress versión 1.4.0.","source":"nvd"}],"published":"2019-12-20T23:00:25.000Z","modified":"2026-09-10T03:49:24.779Z","severity":{"scorer":"GitHub_M","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:H/PR:L/UI:N/S:C/C:H/I:L/A:N","score":7.1,"rating":"HIGH"},"severities":[{"scorer":"GitHub_M","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:H/PR:L/UI:N/S:C/C:H/I:L/A:N","score":7.1,"rating":"HIGH"},{"scorer":"GitHub","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:H/PR:L/UI:N/S:C/C:H/I:L/A:N","score":7.1,"rating":"MEDIUM"},{"scorer":"GitHub","scheme":"CVSS:4.0","vector":"CVSS:4.0/AV:N/AC:L/AT:P/PR:L/UI:N/VC:N/VI:N/VA:N/SC:H/SI:L/SA:N","rating":"MEDIUM"},{"scorer":"NVD","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:H/A:N","score":7.5,"rating":"HIGH"},{"scorer":"NVD","scheme":"CVSS:2.0","vector":"AV:N/AC:L/Au:N/C:N/I:P/A:N","score":5,"rating":"MEDIUM"}],"cwes":["CWE-444"],"affected":[{"ranges":[{"type":"custom","introduced":"<= 1.3.1","lastAffected":"1.3.1","status":"affected"}],"vendor":"Pylons","product":"Waitress","source":"cvelist"},{"ranges":[{"type":"ecosystem","introduced":"0","status":"affected","fixed":"1.4.0"}],"ecosystem":"PyPI","package":"waitress","purl":"pkg:pypi/waitress","source":"ghsa"},{"ranges":[{"status":"affected","lastAffected":"1.3.1"}],"vendor":"agendaless","product":"waitress","cpe":"cpe:2.3:a:agendaless:waitress:*:*:*:*:*:*:*:*","source":"nvd"},{"ranges":[{"status":"affected","version":"1.10.0"}],"vendor":"oracle","product":"communications_cloud_native_core_network_function_cloud_native_environment","cpe":"cpe:2.3:a:oracle:communications_cloud_native_core_network_function_cloud_native_environment:1.10.0:*:*:*:*:*:*:*","source":"nvd"},{"ranges":[{"status":"affected","version":"9.0"}],"vendor":"debian","product":"debian_linux","cpe":"cpe:2.3:o:debian:debian_linux:9.0:*:*:*:*:*:*:*","source":"nvd"},{"ranges":[{"status":"affected","version":"30"},{"status":"affected","version":"31"}],"vendor":"fedoraproject","product":"fedora","cpe":"cpe:2.3:o:fedoraproject:fedora:30:*:*:*:*:*:*:*","source":"nvd"},{"ranges":[{"status":"affected","version":"15"}],"vendor":"redhat","product":"openstack","cpe":"cpe:2.3:a:redhat:openstack:15:*:*:*:*:*:*:*","source":"nvd"},{"ranges":[{"type":"git","introduced":"0","status":"affected","fixed":"8eba394ad75deaf9e5cd15b78a3d16b12e6b0eba"},{"type":"ecosystem","introduced":"0","status":"affected","fixed":"1.4.0"}],"ecosystem":"PyPI","package":"waitress","purl":"pkg:pypi/waitress","repo":"https://github.com/Pylons/waitress","source":"pysec"}],"references":[{"url":"https://lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/message/GVDHR2DNKCNQ7YQXISJ45NT4IQDX3LJ7/","tags":["vendor-advisory","x-refsource-fedora","x-transferred"],"sources":["cvelist","nvd"]},{"url":"https://lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/message/LYEOTGWJZVKPRXX2HBNVIYWCX73QYPM5/","tags":["vendor-advisory","x-refsource-fedora","x-transferred"],"sources":["cvelist","nvd"]},{"url":"https://access.redhat.com/errata/RHSA-2020:0720","tags":["advisory","third-party-advisory","vendor-advisory","web","x-refsource-redhat","x-transferred"],"sources":["cvelist","ghsa","nvd","pysec"]},{"url":"https://www.oracle.com/security-alerts/cpuapr2022.html","tags":["patch","third-party-advisory","web","x-refsource-misc","x-transferred"],"sources":["cvelist","ghsa","nvd"]},{"url":"https://docs.pylonsproject.org/projects/waitress/en/latest/#security-fixes","tags":["vendor-advisory","web","x-refsource-misc","x-transferred"],"sources":["cvelist","ghsa","nvd","pysec"]},{"url":"https://github.com/Pylons/waitress/security/advisories/GHSA-pg36-wpm5-g57p","tags":["advisory","exploit","third-party-advisory","web","x-refsource-confirm","x-transferred"],"sources":["cvelist","ghsa","nvd","pysec"]},{"url":"https://github.com/Pylons/waitress/commit/8eba394ad75deaf9e5cd15b78a3d16b12e6b0eba","tags":["fix","patch","third-party-advisory","web","x-refsource-misc","x-transferred"],"sources":["cvelist","ghsa","nvd","pysec"]},{"url":"https://lists.debian.org/debian-lts-announce/2022/05/msg00011.html","tags":["mailing-list","third-party-advisory","web","x-refsource-mlist","x-transferred"],"sources":["cvelist","ghsa","nvd"]},{"url":"https://nvd.nist.gov/vuln/detail/CVE-2019-16785","tags":["advisory"],"sources":["ghsa"]},{"url":"https://github.com/Pylons/waitress","tags":["package"],"sources":["ghsa"]},{"url":"https://github.com/pypa/advisory-database/tree/main/vulns/waitress/PYSEC-2019-136.yaml","tags":["web"],"sources":["ghsa"]},{"url":"https://lists.fedoraproject.org/archives/list/package-announce@lists.fedoraproject.org/message/GVDHR2DNKCNQ7YQXISJ45NT4IQDX3LJ7","tags":["web"],"sources":["ghsa"]},{"url":"https://lists.fedoraproject.org/archives/list/package-announce@lists.fedoraproject.org/message/LYEOTGWJZVKPRXX2HBNVIYWCX73QYPM5","tags":["web"],"sources":["ghsa"]},{"url":"https://lists.fedoraproject.org/archives/list/package-announce@lists.fedoraproject.org/message/GVDHR2DNKCNQ7YQXISJ45NT4IQDX3LJ7/","tags":["web"],"sources":["pysec"]},{"url":"https://lists.fedoraproject.org/archives/list/package-announce@lists.fedoraproject.org/message/LYEOTGWJZVKPRXX2HBNVIYWCX73QYPM5/","tags":["web"],"sources":["pysec"]}],"credits":[],"assigner":"GitHub_M","sources":[{"source":"cvelist","name":"CVE List","id":"CVE-2019-16785","url":"https://www.cve.org/CVERecord?id=CVE-2019-16785","licence":"CVE Terms of Use","modified":"2024-08-05T01:24:47.876Z"},{"source":"ghsa","name":"GitHub Advisory Database","id":"GHSA-pg36-wpm5-g57p","url":"https://github.com/advisories/GHSA-pg36-wpm5-g57p","licence":"CC-BY-4.0","modified":"2026-09-10T03:49:24.779Z"},{"source":"nvd","name":"NVD","id":"CVE-2019-16785","url":"https://nvd.nist.gov/vuln/detail/CVE-2019-16785","licence":"Public domain","modified":"2026-06-17T02:22:48.017Z"},{"source":"pysec","name":"PyPA Advisory Database","id":"PYSEC-2019-136","url":"https://osv.dev/vulnerability/PYSEC-2019-136","licence":"CC-BY-4.0","modified":"2023-11-08T04:01:21.641Z"}],"updatedAt":"2026-11-25T22:57:49.001Z","epss":{"score":0.02537,"percentile":0.85387,"date":"2026-12-01T12:00:22.000Z"}}