Sorry for the late response, I’ve been a bit busy with university.
I’m planning to implement this as a manual tool rather than an active scan rule, since race-condition testing generally requires the user to select the requests, configure the number of concurrent executions, and choose the synchronization technique.
Regarding the HTTP/networking APIs, I’m specifically looking for low-level control over how requests are transmitted. For HTTP/2, I’d like to implement a Single-Packet Attack (SPA). This requires preparing multiple HTTP/2 requests on separate streams and controlling the transmission of their frames so that the relevant frames from multiple streams can be sent together in a single TCP packet, allowing the requests to reach the server as closely together as possible.
For HTTP/1.1, I’d like to implement last-byte synchronization. The idea is to establish a separate TCP connection for each request and send each request up to its final byte, while holding the final byte back until all of the connections are ready. The final byte can then be released on each connection as closely together as possible, minimizing the timing difference between the requests reaching the server.
So I’m mainly looking for guidance on whether ZAP exposes APIs that provide sufficient control over HTTP/2 frame transmission and the underlying TCP connections/writes for HTTP/1.1, or whether implementing these synchronization techniques would require working below ZAP’s normal HTTP client/networking abstractions within the add-on.