Skip to main content

router

Function router 

Source
pub fn router(service: Service, auth: Arc<Auth>) -> Router
Expand description

Build the axum router. auth governs per-namespace authorization (ADR 0015); Auth::Disabled serves open. The middleware authenticates every non-probe request (bearer → Principal, or 401) and hands the principal to the handlers, which authorize against the target namespace.