Index: Makefile =================================================================== RCS file: /cvs/ports/net/snort/Makefile,v retrieving revision 1.124 diff -u -p -r1.124 Makefile --- Makefile 16 Jun 2026 16:15:28 -0000 1.124 +++ Makefile 15 Jul 2026 19:00:02 -0000 @@ -1,5 +1,3 @@ -BROKEN = bpf_timeval vs timeval mix-ups result in failure with llvm22 - COMMENT = highly flexible sniffer/NIDS DISTNAME = snort-2.9.20 Index: patch-src_dynamic-plugins_sf_dynamic_plugins_c =================================================================== RCS file: patch-src_dynamic-plugins_sf_dynamic_plugins_c diff -N patch-src_dynamic-plugins_sf_dynamic_plugins_c --- /dev/null 1 Jan 1970 00:00:00 -0000 +++ patch-src_dynamic-plugins_sf_dynamic_plugins_c 15 Jul 2026 19:00:02 -0000 @@ -0,0 +1,20 @@ +Index: src/dynamic-plugins/sf_dynamic_plugins.c +--- src/dynamic-plugins/sf_dynamic_plugins.c.orig ++++ src/dynamic-plugins/sf_dynamic_plugins.c +@@ -102,6 +102,7 @@ typedef HANDLE PluginHandle; + #include "../dynamic-output/plugins/output.h" + #include "file_api.h" + #include "packet_time.h" ++#include "pcap_pkthdr32.h" + #include "perf_indicators.h" + #include "reload.h" + #include "so_rule_mem_adjust.h" +@@ -1839,7 +1840,7 @@ time_t DynamicPktTime(void) + return packet_time(); + } + +-void DynamicGetPktTimeOfDay(struct timeval *tv) ++void DynamicGetPktTimeOfDay(struct sf_timeval32 *tv) + { + packet_gettimeofday(tv); + } Index: patch-src_packet_time_c =================================================================== RCS file: patch-src_packet_time_c diff -N patch-src_packet_time_c --- /dev/null 1 Jan 1970 00:00:00 -0000 +++ patch-src_packet_time_c 15 Jul 2026 19:00:02 -0000 @@ -0,0 +1,26 @@ +Index: src/packet_time.c +--- src/packet_time.c.orig ++++ src/packet_time.c +@@ -36,10 +36,11 @@ + #endif + + #include "packet_time.h" ++#include "pcap_pkthdr32.h" + +-static struct timeval s_recent_packet = { 0, 0 }; ++static struct sf_timeval32 s_recent_packet = { 0, 0 }; + +-void packet_time_update(const struct timeval *cur_tv) ++void packet_time_update(const struct sf_timeval32 *cur_tv) + { + s_recent_packet = *cur_tv; + } +@@ -49,7 +50,7 @@ time_t packet_time(void) + return s_recent_packet.tv_sec; + } + +-void packet_gettimeofday(struct timeval *tv) ++void packet_gettimeofday(struct sf_timeval32 *tv) + { + *tv = s_recent_packet; + } Index: patch-src_packet_time_h =================================================================== RCS file: patch-src_packet_time_h diff -N patch-src_packet_time_h --- /dev/null 1 Jan 1970 00:00:00 -0000 +++ patch-src_packet_time_h 15 Jul 2026 19:00:02 -0000 @@ -0,0 +1,16 @@ +Index: src/packet_time.h +--- src/packet_time.h.orig ++++ src/packet_time.h +@@ -31,8 +31,10 @@ + #include + #endif + +-void packet_time_update(const struct timeval *cur_tv); ++#include "pcap_pkthdr32.h" ++ ++void packet_time_update(const struct sf_timeval32 *cur_tv); + time_t packet_time(void); +-void packet_gettimeofday(struct timeval *tv); ++void packet_gettimeofday(struct sf_timeval32 *tv); + + #endif /* _PACKET_TIME_H */ Index: patch-src_preprocessors_HttpInspect_include_file_decomp_PDF_h =================================================================== RCS file: patch-src_preprocessors_HttpInspect_include_file_decomp_PDF_h diff -N patch-src_preprocessors_HttpInspect_include_file_decomp_PDF_h --- /dev/null 1 Jan 1970 00:00:00 -0000 +++ patch-src_preprocessors_HttpInspect_include_file_decomp_PDF_h 15 Jul 2026 19:00:02 -0000 @@ -0,0 +1,11 @@ +Index: src/preprocessors/HttpInspect/include/file_decomp_PDF.h +--- src/preprocessors/HttpInspect/include/file_decomp_PDF.h.orig ++++ src/preprocessors/HttpInspect/include/file_decomp_PDF.h +@@ -80,6 +80,6 @@ fd_status_t File_Decomp_Init_PDF( fd_session_p_t Sessi + + fd_status_t File_Decomp_End_PDF( fd_session_p_t SessionPtr ); + +-fd_status_t File_Decomp_PDF(); ++fd_status_t File_Decomp_PDF( fd_session_p_t SessionPtr ); + + #endif /* FILE_DECOMP_PDF_H */ Index: patch-src_preprocessors_Stream6_snort_stream_tcp_c =================================================================== RCS file: patch-src_preprocessors_Stream6_snort_stream_tcp_c diff -N patch-src_preprocessors_Stream6_snort_stream_tcp_c --- /dev/null 1 Jan 1970 00:00:00 -0000 +++ patch-src_preprocessors_Stream6_snort_stream_tcp_c 15 Jul 2026 19:00:02 -0000 @@ -0,0 +1,47 @@ +Index: src/preprocessors/Stream6/snort_stream_tcp.c +--- src/preprocessors/Stream6/snort_stream_tcp.c.orig ++++ src/preprocessors/Stream6/snort_stream_tcp.c +@@ -103,6 +103,7 @@ + #include "sfActionQueue.h" + #include "detection_util.h" + #include "file_api.h" ++#include "pcap_pkthdr32.h" + + #ifdef REG_TEST + #include "reg_test.h" +@@ -354,7 +355,7 @@ typedef struct _StreamSegment + #ifdef DEBUG + int ordinal; + #endif +- struct timeval tv; ++ struct sf_timeval32 tv; + uint32_t caplen; + uint32_t pktlen; + +@@ -6600,7 +6601,7 @@ static inline int SegmentFastTrack(StreamSegment *tail + } + + static inline StreamSegment* SegmentAlloc ( +- Packet* p, const struct timeval* tv, uint32_t caplen, uint32_t pktlen, const uint8_t* pkt) ++ Packet* p, const struct sf_timeval32* tv, uint32_t caplen, uint32_t pktlen, const uint8_t* pkt) + { + StreamSegment* ss; + unsigned size = sizeof(*ss); +@@ -6718,7 +6719,7 @@ static int AddStreamNode(StreamTracker *st, Packet *p, + return STREAM_INSERT_ANOMALY; + } + +- ss = SegmentAlloc(p, &p->pkth->ts, p->pkth->caplen, p->pkth->pktlen, p->pkt); ++ ss = SegmentAlloc(p, (struct sf_timeval32 *) &p->pkth->ts, p->pkth->caplen, p->pkth->pktlen, p->pkt); + if (!ss) + return STREAM_INSERT_ANOMALY; + +@@ -8953,7 +8954,7 @@ static int ProcessTcp(SessionControlBlock *scb, Packet + char src_addr[17]; + char dst_addr[17]; + memset((char *)timestamp, 0, TIMEBUF_SIZE); +- ts_print((struct timeval *) &p->pkth->ts, timestamp); ++ ts_print((struct sf_timeval32 *) &p->pkth->ts, timestamp); + SnortSnprintf(src_addr, 17, "%s", + inet_ntoa(GET_SRC_ADDR(p))); + SnortSnprintf(dst_addr, 17, "%s", Index: patch-src_snort_c =================================================================== RCS file: patch-src_snort_c diff -N patch-src_snort_c --- /dev/null 1 Jan 1970 00:00:00 -0000 +++ patch-src_snort_c 15 Jul 2026 19:00:02 -0000 @@ -0,0 +1,12 @@ +Index: src/snort.c +--- src/snort.c.orig ++++ src/snort.c +@@ -1643,7 +1643,7 @@ static DAQ_Verdict PacketCallback( + CheckForReload(); + + /* Save off the time of each and every packet */ +- packet_time_update(&pkthdr->ts); ++ packet_time_update((struct sf_timeval32 *) &pkthdr->ts); + + #ifdef REG_TEST + if ( snort_conf->pkt_skip && pc.total_from_daq <= snort_conf->pkt_skip ) Index: patches/patch-src_dynamic-plugins_sf_dynamic_plugins_c =================================================================== RCS file: patches/patch-src_dynamic-plugins_sf_dynamic_plugins_c diff -N patches/patch-src_dynamic-plugins_sf_dynamic_plugins_c --- /dev/null 1 Jan 1970 00:00:00 -0000 +++ patches/patch-src_dynamic-plugins_sf_dynamic_plugins_c 15 Jul 2026 19:00:02 -0000 @@ -0,0 +1,14 @@ +sf_dynamic_plugins.c:1844:25: error: incompatible pointer types passing 'struct timeval *' to parameter of type 'struct bpf_timeval *' + +Index: src/dynamic-plugins/sf_dynamic_plugins.c +--- src/dynamic-plugins/sf_dynamic_plugins.c.orig ++++ src/dynamic-plugins/sf_dynamic_plugins.c +@@ -1839,7 +1839,7 @@ time_t DynamicPktTime(void) + return packet_time(); + } + +-void DynamicGetPktTimeOfDay(struct timeval *tv) ++void DynamicGetPktTimeOfDay(struct bpf_timeval *tv) + { + packet_gettimeofday(tv); + } Index: patches/patch-src_packet_time_c =================================================================== RCS file: patches/patch-src_packet_time_c diff -N patches/patch-src_packet_time_c --- /dev/null 1 Jan 1970 00:00:00 -0000 +++ patches/patch-src_packet_time_c 15 Jul 2026 19:00:02 -0000 @@ -0,0 +1,26 @@ +snort.c:1646:24: error: incompatible pointer types passing 'const struct bpf_timeval *' to parameter of type 'const struct timeval *' + +Index: src/packet_time.c +--- src/packet_time.c.orig ++++ src/packet_time.c +@@ -37,9 +37,9 @@ + + #include "packet_time.h" + +-static struct timeval s_recent_packet = { 0, 0 }; ++static struct bpf_timeval s_recent_packet = { 0, 0 }; + +-void packet_time_update(const struct timeval *cur_tv) ++void packet_time_update(const struct bpf_timeval *cur_tv) + { + s_recent_packet = *cur_tv; + } +@@ -49,7 +49,7 @@ time_t packet_time(void) + return s_recent_packet.tv_sec; + } + +-void packet_gettimeofday(struct timeval *tv) ++void packet_gettimeofday(struct bpf_timeval *tv) + { + *tv = s_recent_packet; + } Index: patches/patch-src_packet_time_h =================================================================== RCS file: patches/patch-src_packet_time_h diff -N patches/patch-src_packet_time_h --- /dev/null 1 Jan 1970 00:00:00 -0000 +++ patches/patch-src_packet_time_h 15 Jul 2026 19:00:02 -0000 @@ -0,0 +1,18 @@ +snort.c:1646:24: error: incompatible pointer types passing 'const struct bpf_timeval *' to parameter of type 'const struct timeval *' + +Index: src/packet_time.h +--- src/packet_time.h.orig ++++ src/packet_time.h +@@ -31,8 +31,10 @@ + #include + #endif + +-void packet_time_update(const struct timeval *cur_tv); ++#include ++ ++void packet_time_update(const struct bpf_timeval *cur_tv); + time_t packet_time(void); +-void packet_gettimeofday(struct timeval *tv); ++void packet_gettimeofday(struct bpf_timeval *tv); + + #endif /* _PACKET_TIME_H */ Index: patches/patch-src_preprocessors_Stream6_snort_stream_tcp_c =================================================================== RCS file: /cvs/ports/net/snort/patches/patch-src_preprocessors_Stream6_snort_stream_tcp_c,v retrieving revision 1.16 diff -u -p -r1.16 patch-src_preprocessors_Stream6_snort_stream_tcp_c --- patches/patch-src_preprocessors_Stream6_snort_stream_tcp_c 24 Aug 2022 14:14:57 -0000 1.16 +++ patches/patch-src_preprocessors_Stream6_snort_stream_tcp_c 15 Jul 2026 19:00:02 -0000 @@ -1,6 +1,26 @@ +snort_stream_tcp.c:6721:26: error: incompatible pointer types passing 'const struct bpf_timeval *' to parameter of type 'const struct timeval *' + Index: src/preprocessors/Stream6/snort_stream_tcp.c --- src/preprocessors/Stream6/snort_stream_tcp.c.orig +++ src/preprocessors/Stream6/snort_stream_tcp.c +@@ -354,7 +354,7 @@ typedef struct _StreamSegment + #ifdef DEBUG + int ordinal; + #endif +- struct timeval tv; ++ struct bpf_timeval tv; + uint32_t caplen; + uint32_t pktlen; + +@@ -6600,7 +6600,7 @@ static inline int SegmentFastTrack(StreamSegment *tail + } + + static inline StreamSegment* SegmentAlloc ( +- Packet* p, const struct timeval* tv, uint32_t caplen, uint32_t pktlen, const uint8_t* pkt) ++ Packet* p, const struct bpf_timeval* tv, uint32_t caplen, uint32_t pktlen, const uint8_t* pkt) + { + StreamSegment* ss; + unsigned size = sizeof(*ss); @@ -8953,7 +8953,7 @@ static int ProcessTcp(SessionControlBlock *scb, Packet char src_addr[17]; char dst_addr[17];