From 18fc16b0b8182182db89658c5b17439af0f26a39 Mon Sep 17 00:00:00 2001 From: ales stibal Date: Mon, 11 Nov 2024 10:23:05 +0100 Subject: [PATCH] ja4 - fix http method for ja4h --- src/inspect/engine/http.cpp | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/src/inspect/engine/http.cpp b/src/inspect/engine/http.cpp index d2288d2..363b0e1 100644 --- a/src/inspect/engine/http.cpp +++ b/src/inspect/engine/http.cpp @@ -539,8 +539,13 @@ namespace sx::engine::http { } } } - if(ja4h.has_value()) + if(ja4h.has_value()) { + auto meth = my_app_data->http_data.method; + if(meth.size() >= 2) + ja4h->cmd = sx::ja4::util::to_lower(meth).substr(0,2); + my_app_data->http_data.ja4h = ja4h->ja4h(); + } detect_app(ctx, side, my_app_data, stream_id, flags, data); if(ctx.origin->opt_kb_enabled) {