]> 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)
committerPhilippe Antoine <pantoine@oisf.net>
Mon, 21 Apr 2025 19:26:55 +0000 (21:26 +0200)
Ticket: 7668

We should set updated_tx when allocating HtpTxUserData

(cherry picked from commit a5b987266b2180e074d8fe5cf444739d9a5bdc91)

src/app-layer-htp.c

index 6df6c3270f50929573919e23f4117d0e25f417af..51754e80159d0aadc84104a44b5e1a4fc6cadc9e 100644 (file)
@@ -2168,9 +2168,8 @@ static int HTPCallbackRequestStart(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_OK);
 }
 
@@ -2210,9 +2209,8 @@ static int HTPCallbackResponseStart(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_OK);
 }