CVE-2026-22779
JSON

6.3medium

BlackSheep ClientSession is vulnerable to CRLF injection

Severity
6.3medium CVSS:4.0 by GitHub_M
Exploit likelihood
0.37% (higher than 32% of CVEs; EPSS, by FIRST)
Published
Last changed
Assigned by
GitHub_M
Also known as
GHSA-6pw3-h7xf-x4gpPYSEC-2026-1222

Description

BlackSheep is an asynchronous web framework to build event based web applications with Python. Prior to 2.4.6, the HTTP Client implementation in BlackSheep is vulnerable to CRLF injection. Missing headers validation makes it possible for an attacker to modify the HTTP requests (e.g. insert a new header) or even create a new HTTP request. Exploitation requires developers to pass unsanitized user input directly into headers.The server part is not affected because BlackSheep delegates to an underlying ASGI server handling of response headers. This vulnerability is fixed in 2.4.6.

Affected

Product or packageVersionsReported by
Neoteroi BlackSheep< 2.4.6, before 2.4.6CVE List, NVD
blacksheep (PyPI)before 2.4.6GitHub Advisory Database, PyPA Advisory Database

All scores

GitHub_M6.3medium CVSS:4.0CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:N/VC:N/VI:N/VA:N/SC:L/SI:L/SA:N
GitHubmedium CVSS:4.0CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:N/VC:N/VI:N/VA:N/SC:L/SI:L/SA:N
NVD5.3medium CVSS:3.1CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:L/A:N
PyPA Advisory DatabaseNot scored CVSS:4.0CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:N/VC:N/VI:N/VA:N/SC:L/SI:L/SA:N

Classification

CWE-93CWE-113

SSVC (CISA-ADP): exploitation none, automatable yes, technical impact partial.

What each source says

CVE List

BlackSheep is an asynchronous web framework to build event based web applications with Python. Prior to 2.4.6, the HTTP Client implementation in BlackSheep is vulnerable to CRLF injection. Missing headers validation makes it possible for an attacker to modify the HTTP requests (e.g. insert a new header) or even create a new HTTP request. Exploitation requires developers to pass unsanitized user input directly into headers.The server part is not affected because BlackSheep delegates to an underlying ASGI server handling of response headers. This vulnerability is fixed in 2.4.6.

GitHub Advisory Database
Impact

The HTTP Client implementation in BlackSheep is vulnerable to CRLF injection. Missing headers validation makes it possible for an attacker to modify the HTTP requests (e.g. insert a new header) or even create a new HTTP request. Exploitation requires developers to pass unsanitized user input directly into headers. The server part is not affected because BlackSheep delegates to an underlying ASGI server handling of response headers.

Attack vector: Applications using user input in HTTP client requests (method, URL, headers).

Patches

Users who use the HTTP Client in BlackSheep should upgrade to 2.4.6.

Workarounds

If users handle headers from untrusted parties, they might reject values for header names and values that contain carriage returns.

References

https://owasp.org/www-community/vulnerabilities/CRLF_Injection

NVD (es)

BlackSheep es un framework web asíncrono para construir aplicaciones web basadas en eventos con Python. Antes de la versión 2.4.6, la implementación del Cliente HTTP en BlackSheep es vulnerable a la inyección CRLF. La falta de validación de encabezados hace posible que un atacante modifique las solicitudes HTTP (p. ej., insertar un nuevo encabezado) o incluso cree una nueva solicitud HTTP. La explotación requiere que los desarrolladores pasen la entrada de usuario no saneada directamente a los encabezados. La parte del servidor no se ve afectada porque BlackSheep delega a un servidor ASGI subyacente el manejo de los encabezados de respuesta. Esta vulnerabilidad se corrige en la versión 2.4.6.

References

Sources

SourceRecordLicence
CVE ListCVE-2026-22779 changed 2026-01-14CVE Terms of Use
GitHub Advisory DatabaseGHSA-6pw3-h7xf-x4gp changed 2026-07-07CC-BY-4.0
NVDCVE-2026-22779 changed 2026-06-17Public domain
PyPA Advisory DatabasePYSEC-2026-1222 changed 2026-07-07CC-BY-4.0