CVE-2026-54135
nicheUnauthenticated DoS via memory exhaustion in AirSane scanner server HTTP parsing
AirSane, a SANE frontend and scanner server that supports Apple's AirScan (eSCL) protocol, contains a flaw in its custom HTTP server: the HttpServer::Request::content function in httpserver.cpp reads the Content-Length header and passes the value directly to std::string::resize() with no upper-bound validation or safe parsing. A remote, unauthenticated attacker can send an HTTP POST with an artificially large Content-Length, forcing the daemon to attempt allocating gigabytes of memory, which raises a std::bad_alloc exception and immediately crashes the process; non-numeric Content-Length values additionally trigger undefined behavior (NaN-to-integer conversion) due to missing parse error handling. The attacker gains denial of service only — the CVSS vector confirms high availability impact with no confidentiality or integrity impact. Anyone running AirSane prior to 0.4.12, typically self-hosted on Linux/Unix machines or NAS-style devices to share scanners over the network, is affected. Exploitation is not currently observed: the issue is not in CISA KEV and no public proof-of-concept is known.
What to do: Upgrade AirSane to version 0.4.12 or later, which adds validation and safe parsing of the Content-Length header. Where upgrading is not immediately possible, restrict access to the AirSane HTTP service with firewall rules to trusted LAN clients only, and configure service monitoring/auto-restart so crashes are quickly recovered. Check deployments for exposed scanner servers by inventorying hosts running the airsane daemon and confirming their installed version.
| AirSane (open-source project) AirSane (SANE frontend / AirScan eSCL scanner server) | All versions prior to 0.4.12; fixed in 0.4.12 |
Order-of-magnitude estimate by the model from install counts, market share and public scan data it knows; verify before quoting.
AirSane is a SANE frontend, and a scanner server that supports Apple's AirScan protocol. Versions prior to 0.4.12 have a vulnerability in the custom HTTP server implementation of AirSane that allows a remote unauthenticated attacker to cause a Denial of Service (DoS) via memory exhaustion (OOM). In httpserver.cpp, the HttpServer::Request::content function reads the Content-Length header and directly passes this value to std::string::resize() without any upper-bound validation or safe parsing. An attacker can send an HTTP POST request with an artificially large Content-Length value. This forces the daemon to attempt allocating gigabytes of memory, resulting in a std::bad_alloc exception and immediately crashing the AirSane process. Additionally, providing non-numeric characters in the Content-Length header leads to undefined behavior (NaN to integer conversion) due to the lack of error handling during header parsing. Version 0.4.12 patches the issue.
- Weakness
- CWE-400, CWE-770
- Vector
- CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H
In the news0 stories
No ingested article mentions this CVE yet.