Skip to main content

audit_requests

Function audit_requests 

Source
pub async fn audit_requests(
    __arg0: State<Arc<ServerState>>,
    request: Request,
    next: Next,
) -> Response
Expand description

Router middleware: emit one event::AuditEvent per audited request once its response is known. Layered outside the request timeout, so timed-out requests are recorded too. Requests that matched no route (404) or no method (405) are not audited — nothing was attempted.