]> git.ipfire.org Git - thirdparty/suricata.git/commitdiff
http1: always mark tx as updated on request/response start
authorPhilippe Antoine <pantoine@oisf.net>
Sat, 19 Apr 2025 19:21:31 +0000 (21:21 +0200)
committerVictor Julien <victor@inliniac.net>
Sun, 20 Apr 2025 02:49:43 +0000 (04:49 +0200)
Ticket: 7668

We should set updated_tx when allocating HtpTxUserData

src/app-layer-htp.c

index 17cda7ea68f0878aa7e848b2eb977d2cdd3c4d44..b6de7baa78d6f619bb3ccfb8f685cf309bdde8c6 100644 (file)
@@ -1703,9 +1703,8 @@ static int HTPCallbackRequestStart(const htp_connp_t *connp, htp_tx_t *tx)
         }
         tx_ud->tx_data.file_tx = STREAM_TOSERVER | STREAM_TOCLIENT; // each http tx may xfer files
         htp_tx_set_user_data(tx, tx_ud);
-    } else {
-        tx_ud->tx_data.updated_ts = true;
     }
+    tx_ud->tx_data.updated_ts = true;
     SCReturnInt(HTP_STATUS_OK);
 }
 
@@ -1745,9 +1744,8 @@ static int HTPCallbackResponseStart(const htp_connp_t *connp, htp_tx_t *tx)
         tx_ud->tx_data.file_tx =
                 STREAM_TOCLIENT; // each http tx may xfer files. Toserver already missed.
         htp_tx_set_user_data(tx, tx_ud);
-    } else {
-        tx_ud->tx_data.updated_tc = true;
     }
+    tx_ud->tx_data.updated_tc = true;
     SCReturnInt(HTP_STATUS_OK);
 }