Datasette versions from 0.58 up to but not including 0.65.2_6 contain a vulnerability where AnyIO process-pool workers can block indefinitely due to undrained stderr pipes. The worker redirects stdin and stdout to /dev/null but does not redirect stderr, allowing attacker-influenced stderr output to fill the pipe and cause a deadlock. This affects users running untrusted or faulty code that writes excessive data to stderr. A fix is available in version 0.65.2_6. Closing sys.stderr in the target function can mitigate the issue temporarily.
AnyIO versions from 0.58 up to but not including 0.65.2_6 have a vulnerability in TLSStream where the use of IDNA 2003 host name encoding can enable TLS certificate spoofing. This affects services using internationalized domain names (non-ASCII). An attacker who hijacks and redirects a TLS connection can present a legitimate certificate encoded with IDNA 2003, causing the client to accept a spoofed certificate. The issue is patched in version 0.65.2_6. A workaround is to encode host names using the 'idna' package before connecting.
The python-multipart library's parse_form() function did not validate the Content-Length header for negative values before reading the request body. A negative Content-Length caused the function to read the entire request body into memory at once instead of in chunks. This vulnerability only affects code that directly calls parse_form() with attacker-controlled negative Content-Length headers without normalization. Common frameworks like Starlette, FastAPI, and Werkzeug are not affected. The issue can degrade availability by increasing memory usage under concurrent requests but does not cause complete denial of service. The vulnerability is fixed in version 0.65.2_5 and later.
A vulnerability in python-multipart's QuerystringParser causes quadratic-time parsing of application/x-www-form-urlencoded bodies using semicolon separators, leading to excessive CPU consumption. An attacker can craft a small request body with repeated semicolons to cause denial of service by exhausting worker processes. This affects versions of the datasette product from 0.47.3 up to but not including 0.65.2_5. The issue is fixed in version 0.65.2_5 by treating only '&' as a field separator, making parsing linear in time.
The python-multipart library's QuerystringParser incorrectly treats the semicolon (';') as a separator for form fields in application/x-www-form-urlencoded bodies, in addition to the ampersand ('&'). This behavior deviates from the WHATWG URL standard and modern browser parsing, which only use '&' as a separator. This discrepancy allows an attacker to smuggle additional or overriding form parameters past upstream components that follow the standard, potentially altering backend application behavior. The issue is fixed in python-multipart version 0.65.2_5 and later.
A vulnerability in python-multipart allows an attacker to smuggle Content-Disposition parameters using RFC 2231/5987 extended parameter syntax, which is forbidden by RFC 7578 for multipart/form-data. This causes a discrepancy between what an upstream inspector sees and what the backend application processes, potentially bypassing field name or filename-based controls. The issue is fixed in python-multipart version 0.65.2_5 and later.
A denial of service vulnerability exists in python-multipart's multipart part header parsing, allowing an attacker to cause excessive CPU usage by sending multipart/form-data requests with either many repeated headers or a single very large header value. This affects applications using python-multipart versions from 0.47.3 up to but not including 0.65.2_3. The issue is fixed in version 0.65.2_3. Applications using frameworks like Starlette or FastAPI that rely on python-multipart may experience worker or event-loop delays when processing malicious requests.
A denial of service vulnerability in Datasette's python-multipart parser allows attackers to send crafted multipart/form-data requests with large preamble or epilogue sections. This causes excessive CPU consumption during request parsing, degrading availability but not typically causing a full application outage. The issue is fixed in version 0.65.2_2.
Datasette's Python-Multipart library has a path traversal vulnerability when configured with UPLOAD_DIR set and UPLOAD_KEEP_FILENAME=True. This allows an attacker to write uploaded files to arbitrary filesystem locations by using filenames starting with a slash. The vulnerability only affects configurations where uploaded files exceed MAX_MEMORY_FILE_SIZE, triggering a disk flush. The default configuration is not vulnerable. A fix is available in version 0.65.2_1.
CVE-2025-27516 is a medium severity vulnerability in Datasette's use of the Jinja2 templating engine. It allows an attacker who can control template content to bypass the Jinja sandbox via the |attr filter to access the string format method and execute arbitrary Python code. This vulnerability affects Datasette versions from 0.47.1 up to but not including 0.65.1_2. The issue is fixed in version 0.65.1_2 by preventing the |attr filter from bypassing the sandbox's attribute lookup.
A denial of service (DoS) vulnerability exists in Datasette due to the way the python-multipart library parses multipart/form-data boundaries. Excessive logging triggered by malformed boundaries can cause high CPU usage and stall processing threads, potentially blocking other requests in ASGI applications. This affects Datasette versions from 0.47.3 up to but not including 0.65.1. A fix is available in version 0.65.1.
CVE-2024-24762 is a Regular Expression Denial of Service (ReDoS) vulnerability in the python-multipart library used by Datasette and frameworks like FastAPI when parsing HTTP Content-Type headers with form data. An attacker can craft a malicious Content-Type header that causes the regex parser to consume excessive CPU resources, stalling the server's main event loop and causing denial of service. This affects applications that parse form data using python-multipart but not JSON payloads. The issue is fixed in python-multipart version 0.64.6_2.
Datasette versions 0.65.1 and below, as well as 1.0a0 through 1.0a19, contain an open redirect vulnerability. This flaw allows URLs with a double slash prefix (//) to redirect users to an external site, potentially enabling phishing or redirect attacks. The issue has been fixed in Datasette version 0.65.2 and 1.0a21. A temporary mitigation involves configuring a proxy to rewrite URLs by replacing // with /.