A malicious proxy can crash the process by sending a malformed response
Vulnerability Description handle_proxy_read (lines 775-784) calls m_proxy_data->res.consume(input). If headers_ready() is false, it invokes callback(general) and returns—however, m_proxy_data->timer was already canceled at line 761, and m_proxy_data is not reset, leaving connection resources (socket, proxy_data) uncleared and relying on the upper-level init failure path for cleanup. More critically, the internal parsing within res.consume (http/impl/response.hpp) may throw a std::exception (e.g., due to status line parsing failure) when encountering malformed headers, and handle_proxy_read lacks any try/catch block. The exception will propagate up through the Asio handler; if the outer io_service.run() does not catch it, it will lead to process termination (std::terminate). A malicious proxy can trigger this simply by returning a malformed status line.
Exploitation Scenario A malicious proxy returns a malformed HTTP status line (e.g., overly long or containing illegal characters), causing res.consume to throw an exception that escapes the Asio callback. If the user's io_service.run() lacks a try/catch block, the process will crash, resulting in a Remote Denial of Service (DoS).
Fix Suggestion Wrap the res.consume call in handle_proxy_read with a try/catch block, and upon catching the exception, invoke the callback with error::pass_through.
Source: zaphoyd/websocketpp