Browse Source

Merge upstream version 4.5.2

Christoph Biedl 16 hours ago
parent
commit
1b8ab6a2e8
100 changed files with 16065 additions and 10659 deletions
  1. 1 0
      Makefile.am
  2. 37 21
      Makefile.in
  3. 239 0
      README.md
  4. 312 135
      aclocal.m4
  5. 11 3
      config/ar-lib
  6. 7 4
      config/compile
  7. 959 624
      config/config.guess
  8. 1860 1307
      config/config.sub
  9. 8 7
      config/depcomp
  10. 7 7
      config/install-sh
  11. 912 640
      config/ltmain.sh
  12. 48 27
      config/missing
  13. 10607 6727
      configure
  14. 18 8
      configure.ac
  15. 24 1
      docs/CHANGELOG
  16. 7 0
      docs/CREDIT
  17. 21 6
      docs/Makefile.in
  18. 29 15
      lib/Makefile.in
  19. 1 4
      lib/queue.h
  20. 1 1
      lib/strlcpy.h
  21. 35 27
      libopts/Makefile.in
  22. 392 273
      m4/libtool.m4
  23. 69 39
      m4/ltoptions.m4
  24. 1 1
      m4/ltsugar.m4
  25. 7 6
      m4/ltversion.m4
  26. 2 2
      m4/lt~obsolete.m4
  27. 21 6
      scripts/Makefile.in
  28. 1 1
      src/Makefile.am
  29. 38 31
      src/Makefile.in
  30. 1 1
      src/bridge.c
  31. 1 1
      src/bridge.h
  32. 1 1
      src/common.h
  33. 30 16
      src/common/Makefile.in
  34. 1 1
      src/common/cache.c
  35. 1 1
      src/common/cache.h
  36. 1 2
      src/common/cidr.c
  37. 1 1
      src/common/cidr.h
  38. 1 1
      src/common/err.c
  39. 1 1
      src/common/err.h
  40. 1 1
      src/common/fakepcap.c
  41. 1 1
      src/common/fakepcap.h
  42. 1 1
      src/common/fakepcapnav.c
  43. 1 1
      src/common/fakepcapnav.h
  44. 2 2
      src/common/flows.c
  45. 1 1
      src/common/flows.h
  46. 5 3
      src/common/get.c
  47. 1 1
      src/common/get.h
  48. 1 1
      src/common/git_version.c
  49. 1 1
      src/common/interface.c
  50. 1 1
      src/common/interface.h
  51. 1 1
      src/common/list.c
  52. 1 1
      src/common/list.h
  53. 1 1
      src/common/mac.c
  54. 1 1
      src/common/mac.h
  55. 1 1
      src/common/pcap_dlt.h
  56. 7 2
      src/common/sendpacket.c
  57. 10 3
      src/common/sendpacket.h
  58. 1 1
      src/common/services.c
  59. 1 1
      src/common/services.h
  60. 1 1
      src/common/tcpdump.c
  61. 1 1
      src/common/tcpdump.h
  62. 1 1
      src/common/timer.c
  63. 1 1
      src/common/timer.h
  64. 5 2
      src/common/txring.c
  65. 2 2
      src/common/txring.h
  66. 1 1
      src/common/utils.c
  67. 1 1
      src/common/utils.h
  68. 5 1
      src/common/xX.c
  69. 1 1
      src/common/xX.h
  70. 119 107
      src/config.h.in
  71. 0 408
      src/defines.h
  72. 5 1
      src/defines.h.in
  73. 29 15
      src/fragroute/Makefile.in
  74. 10 18
      src/fragroute/bget.c
  75. 13 23
      src/fragroute/bget.h
  76. 1 1
      src/fragroute/fragroute.c
  77. 1 1
      src/fragroute/fragroute.h
  78. 1 1
      src/fragroute/mod.c
  79. 1 1
      src/fragroute/pkt.h
  80. 1 1
      src/replay.c
  81. 1 1
      src/replay.h
  82. 1 1
      src/send_packets.c
  83. 1 1
      src/send_packets.h
  84. 1 1
      src/signal_handler.c
  85. 1 1
      src/signal_handler.h
  86. 1 1
      src/sleep.c
  87. 1 1
      src/sleep.h
  88. 3 3
      src/tcpbridge.1
  89. 1 1
      src/tcpbridge.c
  90. 1 1
      src/tcpbridge.h
  91. 4 4
      src/tcpbridge_opts.c
  92. 4 4
      src/tcpbridge_opts.def
  93. 1 1
      src/tcpbridge_opts.h
  94. 1 1
      src/tcpcapinfo.1
  95. 1 1
      src/tcpcapinfo.c
  96. 1 1
      src/tcpcapinfo_opts.c
  97. 2 2
      src/tcpcapinfo_opts.def
  98. 82 68
      src/tcpedit/Makefile.in
  99. 3 1
      src/tcpedit/checksum.c
  100. 0 0
      src/tcpedit/checksum.h

+ 1 - 0
Makefile.am

@@ -12,6 +12,7 @@ DIST_SUBDIRS = scripts lib libopts src docs test
 
 
 dist-hook: version manpages
+	rm $(distdir)/src/defines.h
 
 DOCS_DIR = $(top_builddir)/docs
 

+ 37 - 21
Makefile.in

@@ -1,7 +1,7 @@
-# Makefile.in generated by automake 1.16.3 from Makefile.am.
+# Makefile.in generated by automake 1.17 from Makefile.am.
 # @configure_input@
 
-# Copyright (C) 1994-2020 Free Software Foundation, Inc.
+# Copyright (C) 1994-2024 Free Software Foundation, Inc.
 
 # This Makefile.in is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -69,6 +69,8 @@ am__make_running_with_option = \
   test $$has_opt = yes
 am__make_dryrun = (target_option=n; $(am__make_running_with_option))
 am__make_keepgoing = (target_option=k; $(am__make_running_with_option))
+am__rm_f = rm -f $(am__rm_f_notfound)
+am__rm_rf = rm -rf $(am__rm_f_notfound)
 pkgdatadir = $(datadir)/@PACKAGE@
 pkgincludedir = $(includedir)/@PACKAGE@
 pkglibdir = $(libdir)/@PACKAGE@
@@ -158,24 +160,22 @@ am__define_uniq_tagged_files = \
   unique=`for i in $$list; do \
     if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
   done | $(am__uniquify_input)`
-ETAGS = etags
-CTAGS = ctags
-CSCOPE = cscope
 am__DIST_COMMON = $(srcdir)/Makefile.in $(srcdir)/doxygen.cfg.in \
 	$(top_srcdir)/config/ar-lib $(top_srcdir)/config/compile \
 	$(top_srcdir)/config/config.guess \
 	$(top_srcdir)/config/config.sub \
 	$(top_srcdir)/config/install-sh $(top_srcdir)/config/ltmain.sh \
-	$(top_srcdir)/config/missing config/ar-lib config/compile \
-	config/config.guess config/config.sub config/depcomp \
-	config/install-sh config/ltmain.sh config/missing
+	$(top_srcdir)/config/missing README.md config/ar-lib \
+	config/compile config/config.guess config/config.sub \
+	config/depcomp config/install-sh config/ltmain.sh \
+	config/missing
 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
 distdir = $(PACKAGE)-$(VERSION)
 top_distdir = $(distdir)
 am__remove_distdir = \
   if test -d "$(distdir)"; then \
-    find "$(distdir)" -type d ! -perm -200 -exec chmod u+w {} ';' \
-      && rm -rf "$(distdir)" \
+    find "$(distdir)" -type d ! -perm -700 -exec chmod u+rwx {} ';' \
+      ; rm -rf "$(distdir)" \
       || { sleep 5 && rm -rf "$(distdir)"; }; \
   else :; fi
 am__post_remove_distdir = $(am__remove_distdir)
@@ -205,14 +205,16 @@ am__relativize = \
   done; \
   reldir="$$dir2"
 DIST_ARCHIVES = $(distdir).tar.gz
-GZIP_ENV = --best
+GZIP_ENV = -9
 DIST_TARGETS = dist-gzip
 # Exists only to be overridden by the user if desired.
 AM_DISTCHECK_DVI_TARGET = dvi
 distuninstallcheck_listfiles = find . -type f -print
 am__distuninstallcheck_listfiles = $(distuninstallcheck_listfiles) \
   | sed 's|^\./|$(prefix)/|' | grep -v '$(infodir)/dir$$'
-distcleancheck_listfiles = find . -type f -print
+distcleancheck_listfiles = \
+  find . \( -type f -a \! \
+            \( -name .nfs* -o -name .smb* -o -name .__afs* \) \) -print
 ACLOCAL = @ACLOCAL@
 AMTAR = @AMTAR@
 AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
@@ -229,6 +231,8 @@ CPP = @CPP@
 CPPFLAGS = @CPPFLAGS@
 CROSS_ARCH = @CROSS_ARCH@
 CROSS_LD = @CROSS_LD@
+CSCOPE = @CSCOPE@
+CTAGS = @CTAGS@
 CUT = @CUT@
 CXX = @CXX@
 CXXCPP = @CXXCPP@
@@ -246,8 +250,10 @@ ECHO_C = @ECHO_C@
 ECHO_N = @ECHO_N@
 ECHO_T = @ECHO_T@
 EGREP = @EGREP@
+ETAGS = @ETAGS@
 EXEEXT = @EXEEXT@
 FGREP = @FGREP@
+FILECMD = @FILECMD@
 GREP = @GREP@
 GROFF = @GROFF@
 INSTALL = @INSTALL@
@@ -320,8 +326,10 @@ ac_ct_DUMPBIN = @ac_ct_DUMPBIN@
 am__include = @am__include@
 am__leading_dot = @am__leading_dot@
 am__quote = @am__quote@
+am__rm_f_notfound = @am__rm_f_notfound@
 am__tar = @am__tar@
 am__untar = @am__untar@
+am__xargs_n = @am__xargs_n@
 bindir = @bindir@
 build = @build@
 build_alias = @build_alias@
@@ -376,6 +384,7 @@ target_cpu = @target_cpu@
 target_os = @target_os@
 target_vendor = @target_vendor@
 tcpdump_path = @tcpdump_path@
+test_hexdump = @test_hexdump@
 timestamp_trace_flag = @timestamp_trace_flag@
 top_build_prefix = @top_build_prefix@
 top_builddir = @top_builddir@
@@ -548,13 +557,12 @@ cscopelist-am: $(am__tagged_files)
 distclean-tags:
 	-rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
 	-rm -f cscope.out cscope.in.out cscope.po.out cscope.files
-
 distdir: $(BUILT_SOURCES)
 	$(MAKE) $(AM_MAKEFLAGS) distdir-am
 
 distdir-am: $(DISTFILES)
 	$(am__remove_distdir)
-	test -d "$(distdir)" || mkdir "$(distdir)"
+	$(AM_V_at)$(MKDIR_P) "$(distdir)"
 	@srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
 	topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
 	list='$(DISTFILES)'; \
@@ -668,7 +676,7 @@ dist dist-all:
 distcheck: dist
 	case '$(DIST_ARCHIVES)' in \
 	*.tar.gz*) \
-	  eval GZIP= gzip $(GZIP_ENV) -dc $(distdir).tar.gz | $(am__untar) ;;\
+	  eval GZIP= gzip -dc $(distdir).tar.gz | $(am__untar) ;;\
 	*.tar.bz2*) \
 	  bzip2 -dc $(distdir).tar.bz2 | $(am__untar) ;;\
 	*.tar.lz*) \
@@ -678,7 +686,7 @@ distcheck: dist
 	*.tar.Z*) \
 	  uncompress -c $(distdir).tar.Z | $(am__untar) ;;\
 	*.shar.gz*) \
-	  eval GZIP= gzip $(GZIP_ENV) -dc $(distdir).shar.gz | unshar ;;\
+	  eval GZIP= gzip -dc $(distdir).shar.gz | unshar ;;\
 	*.zip*) \
 	  unzip $(distdir).zip ;;\
 	*.tar.zst*) \
@@ -774,19 +782,19 @@ install-strip:
 	    "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \
 	fi
 mostlyclean-generic:
-	-test -z "$(MOSTLYCLEANFILES)" || rm -f $(MOSTLYCLEANFILES)
+	-$(am__rm_f) $(MOSTLYCLEANFILES)
 
 clean-generic:
 
 distclean-generic:
-	-test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
-	-test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES)
-	-test -z "$(DISTCLEANFILES)" || rm -f $(DISTCLEANFILES)
+	-$(am__rm_f) $(CONFIG_CLEAN_FILES)
+	-test . = "$(srcdir)" || $(am__rm_f) $(CONFIG_CLEAN_VPATH_FILES)
+	-$(am__rm_f) $(DISTCLEANFILES)
 
 maintainer-clean-generic:
 	@echo "This command is intended for maintainers to use"
 	@echo "it deletes files that may require special tools to rebuild."
-	-test -z "$(MAINTAINERCLEANFILES)" || rm -f $(MAINTAINERCLEANFILES)
+	-$(am__rm_f) $(MAINTAINERCLEANFILES)
 clean: clean-recursive
 
 clean-am: clean-generic clean-libtool mostlyclean-am
@@ -881,6 +889,7 @@ uninstall-am:
 .PHONY: manpages docs test man2html
 
 dist-hook: version manpages
+	rm $(distdir)/src/defines.h
 
 manpages:
 	cd src && make manpages
@@ -921,3 +930,10 @@ ncc:
 # Tell versions [3.59,3.63) of GNU make to not export all variables.
 # Otherwise a system limit (for SysV at least) may be exceeded.
 .NOEXPORT:
+
+# Tell GNU make to disable its built-in pattern rules.
+%:: %,v
+%:: RCS/%,v
+%:: RCS/%
+%:: s.%
+%:: SCCS/s.%

+ 239 - 0
README.md

@@ -0,0 +1,239 @@
+Tcpreplay
+=========
+[![Build Status](https://travis-ci.org/appneta/tcpreplay.svg?branch=master)](https://travis-ci.org/appneta/tcpreplay)
+[![Test Status](https://github.com/appneta/tcpreplay/actions/workflows/github-actions-ci.yml/badge.svg)](https://github.com/appneta/tcpreplay/actions/workflows/github-actions-ci.yml)
+[![Coverity Scan Build Status](https://scan.coverity.com/projects/12017/badge.svg)](https://scan.coverity.com/projects/12017)
+[![Website](https://img.shields.io/website-up-down-green-red/http/shields.io.svg)](http://tcpreplay.appneta.com)
+[![CodeQL](https://github.com/appneta/tcpreplay/actions/workflows/codeql.yml/badge.svg)](https://github.com/appneta/tcpreplay/actions/workflows/codeql.yml)
+[![cpp-linter](https://github.com/appneta/tcpreplay/actions/workflows/c-linter.yml/badge.svg)](https://github.com/appneta/tcpreplay/actions/workflows/c-linter.yml)
+
+Tcpreplay is a suite of [GPLv3] licensed utilities for UNIX (and Win32 under
+[Cygwin]) operating systems for editing and replaying network traffic which
+was previously captured by tools like [tcpdump] and [Wireshark]. 
+It allows you to classify traffic as client or server, rewrite Layer 2, 3 and 4 
+packets and finally replay the traffic back onto the network and through other
+devices such as switches, routers, firewalls, NIDS and IPS's. Tcpreplay supports
+both single and dual NIC modes for testing both sniffing and in-line devices.
+
+Tcpreplay is used by numerous firewall, IDS, IPS, NetFlow and other networking
+vendors, enterprises, universities, labs and open source projects. If your
+organization uses Tcpreplay, please let us know who you are and what you use
+it for so that I can continue to add features which are useful.
+
+Tcpreplay is designed to work with network hardware and normally does not
+penetrate deeper than Layer 2. Yazan Siam with sponsorship from [Cisco] developed
+*tcpliveplay* to replay TCP pcap files directly to servers. Use this utility
+if you want to test the entire network stack and into the application.
+
+As of version 4.0, Tcpreplay has been enhanced to address the complexities of
+testing and tuning [IP Flow][flow]/[NetFlow] hardware. Enhancements include:
+
+* Support for [netmap] modified network drivers for 10GigE wire-speed performance
+* Increased accuracy for playback speed
+* Increased accuracy of results reporting
+* Flow statistics including Flows Per Second (fps)
+* Flow analysis for analysis and fine tuning of flow expiry timeouts
+* Hundreds of thousands of flows per second (dependent flow sizes in pcap file) 
+
+Version 4.0 is the first version delivered by Fred Klassen and sponsored by 
+[AppNeta]. Many thanks to the author of Tcpreplay, Aaron Turner who has supplied
+the world with a a solid and full-featured test product thus far. The new author
+strives to take Tcprelay performance to levels normally only seen in commercial
+network test equipment.
+
+Downloads
+=========
+* [![Releases](https://img.shields.io/github/downloads/appneta/tcpreplay/total.svg)](https://github.com/appneta/tcpreplay/releases) [GitHub](https://github.com/appneta/tcpreplay/releases)
+* [![SourceForge](https://img.shields.io/sourceforge/dt/tcpreplay.svg)](https://sourceforge.net/projects/tcpreplay) [SourceForge](https://sourceforge.net/projects/tcpreplay) 
+
+Products
+========
+[![Releases](https://img.shields.io/github/release/appneta/tcpreplay.svg)](https://github.com/appneta/tcpreplay/releases)
+
+The Tcpreplay suite includes the following tools:
+
+Network playback products:
+--------------------------
+* **tcpreplay** - replays pcap files at arbitrary speeds onto the network with an
+option to replay with random IP addresses
+* **tcpreplay-edit** - replays pcap files at arbitrary speeds onto the network with
+numerous options to modify packets packets on the fly
+* **tcpliveplay** - replays TCP network traffic stored in a pcap file on live
+networks in a manner that a remote server will respond to
+
+Pcap file editors and utilities:
+--------------------------------
+* **tcpprep** - multi-pass pcap file pre-processor which determines packets as
+client or server and splits them into creates output files for use by tcpreplay and tcprewrite
+* **tcprewrite** - pcap file editor which rewrites TCP/IP and Layer 2 packet headers
+* **tcpbridge** - bridge two network segments with the power of tcprewrite
+* **tcpcapinfo** - raw pcap file decoder and debugger
+
+Install package
+===============
+Please visit our [downloads](http://tcpreplay.appneta.com/wiki/installation.html#downloads)
+page on our [wiki](http://tcpreplay.appneta.com) 
+for detailed download and installation instructions.
+
+
+Simple directions for Unix users:
+---------------------------------
+```
+./configure 
+make
+sudo make install
+```
+
+Build netmap feature
+--------------------
+This feature will detect [netmap](http://info.iet.unipi.it/~luigi/netmap/)
+capable network drivers on Linux and BSD 
+systems. If detected, the network driver is bypassed for the execution 
+duration of tcpreplay and tcpreplay-edit, and network buffers will be 
+written to directly. This will allow you to achieve full line rates on 
+commodity network adapters, similar to rates achieved by commercial network 
+traffic generators.
+
+**Note** that bypassing the network driver will disrupt other applications connected
+through the test interface. Don't test on the same interface you ssh'ed into.
+
+Download latest and install netmap from <http://info.iet.unipi.it/~luigi/netmap/>
+If you extracted netmap into **/usr/src/** or **/usr/local/src** you can build normally. Otherwise you 
+will have to specify the netmap source directory, for example:
+```
+./configure --with-netmap=/home/fklassen/git/netmap
+make
+sudo make install
+```
+
+You can also find netmap source [here](http://code.google.com/p/netmap/).
+
+Detailed installation instructions are available in the INSTALL document in the tar ball.
+
+Install Tcpreplay from source code
+------------------------
+Download the [tar ball](https://github.com/appneta/tcpreplay/tarball/master) or 
+[zip](https://github.com/appneta/tcpreplay/zipball/master) file. Optionally clone the git
+repository:
+
+```
+git clone git@github.com:appneta/tcpreplay.git
+```
+
+Support
+=======
+If you have a question or think you are experiencing a bug, submit them 
+[here](https://github.com/appneta/tcpreplay/issues). It is important
+that you provide enough information for us to help you.
+
+If your problem has to do with COMPILING tcpreplay:
+* Version of tcpreplay you are trying to compile
+* Platform (Red Hat Linux 9 on x86, Solaris 7 on SPARC, OS X on PPC, etc)
+* Contents of config.status
+* Output from **configure** and **make**
+* Any additional information you think that would be useful.
+
+If your problem has to do with RUNNING tcpreplay or one of the sub-tools:
+* Version information (output of -V)
+* Command line used (options and arguments)
+* Platform (Red Hat Linux 9 on Intel, Solaris 7 on SPARC, etc)
+* Make & model of the network card(s) and driver(s) version
+* Error message (if available) and/or description of problem
+* If possible, attach the pcap file used (compressed with bzip2 or gzip preferred)
+* The core dump or backtrace if available
+* Detailed description of your problem or what you are trying to accomplish
+
+Note: The author of tcpreplay primarily uses OS X and Linux; hence, if you're reporting
+an issue on another platform, it is important that you give very detailed
+information as I may not be able to reproduce your issue.
+
+You are also strongly encouraged to read the extensive documentation (man
+pages, FAQ, documents in /docs and email list archives) BEFORE posting to the
+tcpreplay-users email list:
+
+http://lists.sourceforge.net/lists/listinfo/tcpreplay-users
+
+If you have a bug to report you can submit it here:
+
+https://github.com/appneta/tcpreplay/issues
+
+If you want to help with development, visit our developers wiki:
+
+https://github.com/appneta/tcpreplay/wiki
+
+Lastly, please don't email the authors directly with your questions.  Doing so
+prevents others from potentially helping you and your question/answer from
+showing up in the list archives.
+
+License
+=======
+Tcpreplay 3.5 is GPLv3 and includes software developed by the University of
+California, Berkeley, Lawrence Berkeley Laboratory and its contributors.
+
+Authors and Contributors
+========================
+Tcpreplay is authored by Aaron Turner. In 2013 Fred Klassen, Founder and VP Network Technology,
+[AppNeta](http://appneta.com) added performance features and enhancements,
+and ultimately took over the maintenance of Tcpreplay.
+
+The source code repository has moved to GitHub. You can get a working copy of the repository 
+by installing [git] and executing:
+
+```
+git clone https://github.com/appneta/tcpreplay.git
+```
+
+How To Contribute
+=================
+It's easy. Basically you...
+
+* [Set up git][git]
+* [Fork]
+* Edit (we create a branch per issue)
+* [Send a PR][pr]
+
+<br />
+
+Details:
+--------
+You will find that you will not be able to contribute to the Tcpreplay project directly if you
+use clone the appneta/tcpreplay repo. If you believe that you may someday contribute to the
+repository, GitHub provides an innovative approach. Forking the @appneta/tcpreplay repository
+allows you to work on your own copy of the repository and submit code changes without first
+asking permission from the authors. Forking is also considered to be a compliment so fork away:
+   
+* if you haven't already done so, get yourself a free [GitHub](https://github.com) ID and visit @appneta/tcpreplay
+* click the **Fork** button to get your own private copy of the repository
+* on your build system clone your private repository:
+
+```
+git clone git@github.com:<your ID>/tcpreplay.git
+```
+
+* we like to keep the **master** branch available for projection ready code so we recommend that you make a 
+branch for each feature or bug fix
+* when you are happy with your work, push it to your GitHub repository
+* on your GitHub repository select your new branch and submit a **Pull Request** to **master**
+* optionally monitor the status of your submission [here](https://github.com/appneta/tcpreplay/network)
+
+We will review and possibly discuss the changes with you through GitHub services. 
+If we accept the submission, it will instantly be applied to the production **master** branch.
+
+Additional Information
+======================
+Please visit our [wiki](http://tcpreplay.appneta.com).
+
+or visit our [developers wiki](https://github.com/appneta/tcpreplay/wiki)
+
+[GPLv3]:    http://www.gnu.org/licenses/gpl-3.0.html
+[netmap]:   http://info.iet.unipi.it/~luigi/netmap/
+[flow]:     http://en.wikipedia.org/wiki/Traffic_flow_%28computer_networking%29
+[NetFlow]:  http://www.cisco.com/go/netflow
+[Cygwin]:   http://www.cygwin.com/
+[Wireshark]: https://www.wireshark.org
+[tcpdump]:  http://www.tcpdump.org
+[Cisco]:    http://www.cisco.com
+[AppNeta]:  http://www.appneta.com
+[git]:      https://help.github.com/articles/set-up-git
+[Fork]:     https://help.github.com/articles/fork-a-repo
+[pr]:       https://help.github.com/articles/using-pull-requests

+ 312 - 135
aclocal.m4

@@ -1,6 +1,6 @@
-# generated automatically by aclocal 1.16.3 -*- Autoconf -*-
+# generated automatically by aclocal 1.17 -*- Autoconf -*-
 
-# Copyright (C) 1996-2020 Free Software Foundation, Inc.
+# Copyright (C) 1996-2024 Free Software Foundation, Inc.
 
 # This file is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -14,13 +14,13 @@
 m4_ifndef([AC_CONFIG_MACRO_DIRS], [m4_defun([_AM_CONFIG_MACRO_DIRS], [])m4_defun([AC_CONFIG_MACRO_DIRS], [_AM_CONFIG_MACRO_DIRS($@)])])
 m4_ifndef([AC_AUTOCONF_VERSION],
   [m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl
-m4_if(m4_defn([AC_AUTOCONF_VERSION]), [2.69],,
-[m4_warning([this file was generated for autoconf 2.69.
+m4_if(m4_defn([AC_AUTOCONF_VERSION]), [2.72],,
+[m4_warning([this file was generated for autoconf 2.72.
 You have another version of autoconf.  It may work, but is not guaranteed to.
 If you have problems, you may need to regenerate the build system entirely.
 To do so, use the procedure documented by the package, typically 'autoreconf'.])])
 
-# Copyright (C) 2002-2020 Free Software Foundation, Inc.
+# Copyright (C) 2002-2024 Free Software Foundation, Inc.
 #
 # This file is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -32,10 +32,10 @@ To do so, use the procedure documented by the package, typically 'autoreconf'.])
 # generated from the m4 files accompanying Automake X.Y.
 # (This private macro should not be called outside this file.)
 AC_DEFUN([AM_AUTOMAKE_VERSION],
-[am__api_version='1.16'
+[am__api_version='1.17'
 dnl Some users find AM_AUTOMAKE_VERSION and mistake it for a way to
 dnl require some minimum version.  Point them to the right macro.
-m4_if([$1], [1.16.3], [],
+m4_if([$1], [1.17], [],
       [AC_FATAL([Do not call $0, use AM_INIT_AUTOMAKE([$1]).])])dnl
 ])
 
@@ -51,12 +51,12 @@ m4_define([_AM_AUTOCONF_VERSION], [])
 # Call AM_AUTOMAKE_VERSION and AM_AUTOMAKE_VERSION so they can be traced.
 # This function is AC_REQUIREd by AM_INIT_AUTOMAKE.
 AC_DEFUN([AM_SET_CURRENT_AUTOMAKE_VERSION],
-[AM_AUTOMAKE_VERSION([1.16.3])dnl
+[AM_AUTOMAKE_VERSION([1.17])dnl
 m4_ifndef([AC_AUTOCONF_VERSION],
   [m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl
 _AM_AUTOCONF_VERSION(m4_defn([AC_AUTOCONF_VERSION]))])
 
-# Copyright (C) 2011-2020 Free Software Foundation, Inc.
+# Copyright (C) 2011-2024 Free Software Foundation, Inc.
 #
 # This file is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -70,16 +70,18 @@ _AM_AUTOCONF_VERSION(m4_defn([AC_AUTOCONF_VERSION]))])
 AC_DEFUN([AM_PROG_AR],
 [AC_BEFORE([$0], [LT_INIT])dnl
 AC_BEFORE([$0], [AC_PROG_LIBTOOL])dnl
+AC_BEFORE([$0], [AC_PROG_AR])dnl
 AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl
 AC_REQUIRE_AUX_FILE([ar-lib])dnl
 AC_CHECK_TOOLS([AR], [ar lib "link -lib"], [false])
 : ${AR=ar}
+: ${ARFLAGS=cr}
 
 AC_CACHE_CHECK([the archiver ($AR) interface], [am_cv_ar_interface],
   [AC_LANG_PUSH([C])
    am_cv_ar_interface=ar
    AC_COMPILE_IFELSE([AC_LANG_SOURCE([[int some_variable = 0;]])],
-     [am_ar_try='$AR cru libconftest.a conftest.$ac_objext >&AS_MESSAGE_LOG_FD'
+     [am_ar_try='$AR $ARFLAGS libconftest.a conftest.$ac_objext >&AS_MESSAGE_LOG_FD'
       AC_TRY_EVAL([am_ar_try])
       if test "$ac_status" -eq 0; then
         am_cv_ar_interface=ar
@@ -118,7 +120,7 @@ AC_SUBST([AR])dnl
 
 # AM_AUX_DIR_EXPAND                                         -*- Autoconf -*-
 
-# Copyright (C) 2001-2020 Free Software Foundation, Inc.
+# Copyright (C) 2001-2024 Free Software Foundation, Inc.
 #
 # This file is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -170,7 +172,7 @@ am_aux_dir=`cd "$ac_aux_dir" && pwd`
 
 # AM_CONDITIONAL                                            -*- Autoconf -*-
 
-# Copyright (C) 1997-2020 Free Software Foundation, Inc.
+# Copyright (C) 1997-2024 Free Software Foundation, Inc.
 #
 # This file is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -201,7 +203,7 @@ AC_CONFIG_COMMANDS_PRE(
 Usually this means the macro was only invoked conditionally.]])
 fi])])
 
-# Copyright (C) 1999-2020 Free Software Foundation, Inc.
+# Copyright (C) 1999-2024 Free Software Foundation, Inc.
 #
 # This file is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -333,7 +335,7 @@ AC_CACHE_CHECK([dependency style of $depcc],
       # icc doesn't choke on unknown options, it will just issue warnings
       # or remarks (even with -Werror).  So we grep stderr for any message
       # that says an option was ignored or not supported.
-      # When given -MP, icc 7.0 and 7.1 complain thusly:
+      # When given -MP, icc 7.0 and 7.1 complain thus:
       #   icc: Command line warning: ignoring option '-M'; no argument required
       # The diagnosis changed in icc 8.0:
       #   icc: Command line remark: option '-MP' not supported
@@ -392,7 +394,7 @@ _AM_SUBST_NOTMAKE([am__nodep])dnl
 
 # Generate code to set up dependency tracking.              -*- Autoconf -*-
 
-# Copyright (C) 1999-2020 Free Software Foundation, Inc.
+# Copyright (C) 1999-2024 Free Software Foundation, Inc.
 #
 # This file is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -459,7 +461,7 @@ AC_DEFUN([AM_OUTPUT_DEPENDENCY_COMMANDS],
      [AMDEP_TRUE="$AMDEP_TRUE" MAKE="${MAKE-make}"])])
 
 
-# Copyright (C) 1996-2020 Free Software Foundation, Inc.
+# Copyright (C) 1996-2024 Free Software Foundation, Inc.
 #
 # This file is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -483,7 +485,7 @@ fi], [AC_MSG_RESULT([no])])
 
 # Do all the work for Automake.                             -*- Autoconf -*-
 
-# Copyright (C) 1996-2020 Free Software Foundation, Inc.
+# Copyright (C) 1996-2024 Free Software Foundation, Inc.
 #
 # This file is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -511,6 +513,10 @@ m4_defn([AC_PROG_CC])
 # release and drop the old call support.
 AC_DEFUN([AM_INIT_AUTOMAKE],
 [AC_PREREQ([2.65])dnl
+m4_ifdef([_$0_ALREADY_INIT],
+  [m4_fatal([$0 expanded multiple times
+]m4_defn([_$0_ALREADY_INIT]))],
+  [m4_define([_$0_ALREADY_INIT], m4_expansion_stack)])dnl
 dnl Autoconf wants to disallow AM_ names.  We explicitly allow
 dnl the ones we care about.
 m4_pattern_allow([^AM_[A-Z]+FLAGS$])dnl
@@ -547,7 +553,7 @@ m4_ifval([$3], [_AM_SET_OPTION([no-define])])dnl
 [_AM_SET_OPTIONS([$1])dnl
 dnl Diagnose old-style AC_INIT with new-style AM_AUTOMAKE_INIT.
 m4_if(
-  m4_ifdef([AC_PACKAGE_NAME], [ok]):m4_ifdef([AC_PACKAGE_VERSION], [ok]),
+  m4_ifset([AC_PACKAGE_NAME], [ok]):m4_ifset([AC_PACKAGE_VERSION], [ok]),
   [ok:ok],,
   [m4_fatal([AC_INIT should be called with package and version arguments])])dnl
  AC_SUBST([PACKAGE], ['AC_PACKAGE_TARNAME'])dnl
@@ -599,7 +605,21 @@ AC_PROVIDE_IFELSE([AC_PROG_OBJCXX],
 		  [m4_define([AC_PROG_OBJCXX],
 			     m4_defn([AC_PROG_OBJCXX])[_AM_DEPENDENCIES([OBJCXX])])])dnl
 ])
-AC_REQUIRE([AM_SILENT_RULES])dnl
+# Variables for tags utilities; see am/tags.am
+if test -z "$CTAGS"; then
+  CTAGS=ctags
+fi
+AC_SUBST([CTAGS])
+if test -z "$ETAGS"; then
+  ETAGS=etags
+fi
+AC_SUBST([ETAGS])
+if test -z "$CSCOPE"; then
+  CSCOPE=cscope
+fi
+AC_SUBST([CSCOPE])
+
+AC_REQUIRE([_AM_SILENT_RULES])dnl
 dnl The testsuite driver may need to know about EXEEXT, so add the
 dnl 'am__EXEEXT' conditional if _AM_COMPILER_EXEEXT was seen.  This
 dnl macro is hooked onto _AC_COMPILER_EXEEXT early, see below.
@@ -607,47 +627,9 @@ AC_CONFIG_COMMANDS_PRE(dnl
 [m4_provide_if([_AM_COMPILER_EXEEXT],
   [AM_CONDITIONAL([am__EXEEXT], [test -n "$EXEEXT"])])])dnl
 
-# POSIX will say in a future version that running "rm -f" with no argument
-# is OK; and we want to be able to make that assumption in our Makefile
-# recipes.  So use an aggressive probe to check that the usage we want is
-# actually supported "in the wild" to an acceptable degree.
-# See automake bug#10828.
-# To make any issue more visible, cause the running configure to be aborted
-# by default if the 'rm' program in use doesn't match our expectations; the
-# user can still override this though.
-if rm -f && rm -fr && rm -rf; then : OK; else
-  cat >&2 <<'END'
-Oops!
-
-Your 'rm' program seems unable to run without file operands specified
-on the command line, even when the '-f' option is present.  This is contrary
-to the behaviour of most rm programs out there, and not conforming with
-the upcoming POSIX standard: <http://austingroupbugs.net/view.php?id=542>
-
-Please tell bug-automake@gnu.org about your system, including the value
-of your $PATH and any error possibly output before this message.  This
-can help us improve future automake versions.
+AC_REQUIRE([_AM_PROG_RM_F])
+AC_REQUIRE([_AM_PROG_XARGS_N])
 
-END
-  if test x"$ACCEPT_INFERIOR_RM_PROGRAM" = x"yes"; then
-    echo 'Configuration will proceed anyway, since you have set the' >&2
-    echo 'ACCEPT_INFERIOR_RM_PROGRAM variable to "yes"' >&2
-    echo >&2
-  else
-    cat >&2 <<'END'
-Aborting the configuration process, to ensure you take notice of the issue.
-
-You can download and install GNU coreutils to get an 'rm' implementation
-that behaves properly: <https://www.gnu.org/software/coreutils/>.
-
-If you want to complete the configuration process using your problematic
-'rm' anyway, export the environment variable ACCEPT_INFERIOR_RM_PROGRAM
-to "yes", and re-run configure.
-
-END
-    AC_MSG_ERROR([Your 'rm' program is bad, sorry.])
-  fi
-fi
 dnl The trailing newline in this macro's definition is deliberate, for
 dnl backward compatibility and to allow trailing 'dnl'-style comments
 dnl after the AM_INIT_AUTOMAKE invocation. See automake bug#16841.
@@ -680,7 +662,7 @@ for _am_header in $config_headers :; do
 done
 echo "timestamp for $_am_arg" >`AS_DIRNAME(["$_am_arg"])`/stamp-h[]$_am_stamp_count])
 
-# Copyright (C) 2001-2020 Free Software Foundation, Inc.
+# Copyright (C) 2001-2024 Free Software Foundation, Inc.
 #
 # This file is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -701,7 +683,7 @@ if test x"${install_sh+set}" != xset; then
 fi
 AC_SUBST([install_sh])])
 
-# Copyright (C) 2003-2020 Free Software Foundation, Inc.
+# Copyright (C) 2003-2024 Free Software Foundation, Inc.
 #
 # This file is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -723,7 +705,7 @@ AC_SUBST([am__leading_dot])])
 # Add --enable-maintainer-mode option to configure.         -*- Autoconf -*-
 # From Jim Meyering
 
-# Copyright (C) 1996-2020 Free Software Foundation, Inc.
+# Copyright (C) 1996-2024 Free Software Foundation, Inc.
 #
 # This file is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -758,7 +740,7 @@ AC_MSG_CHECKING([whether to enable maintainer-specific portions of Makefiles])
 
 # Check to see how 'make' treats includes.	            -*- Autoconf -*-
 
-# Copyright (C) 2001-2020 Free Software Foundation, Inc.
+# Copyright (C) 2001-2024 Free Software Foundation, Inc.
 #
 # This file is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -801,7 +783,7 @@ AC_SUBST([am__quote])])
 
 # Fake the existence of programs that GNU maintainers use.  -*- Autoconf -*-
 
-# Copyright (C) 1997-2020 Free Software Foundation, Inc.
+# Copyright (C) 1997-2024 Free Software Foundation, Inc.
 #
 # This file is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -835,7 +817,7 @@ fi
 
 # Helper functions for option handling.                     -*- Autoconf -*-
 
-# Copyright (C) 2001-2020 Free Software Foundation, Inc.
+# Copyright (C) 2001-2024 Free Software Foundation, Inc.
 #
 # This file is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -864,7 +846,7 @@ AC_DEFUN([_AM_SET_OPTIONS],
 AC_DEFUN([_AM_IF_OPTION],
 [m4_ifset(_AM_MANGLE_OPTION([$1]), [$2], [$3])])
 
-# Copyright (C) 1999-2020 Free Software Foundation, Inc.
+# Copyright (C) 1999-2024 Free Software Foundation, Inc.
 #
 # This file is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -911,7 +893,23 @@ AC_LANG_POP([C])])
 # For backward compatibility.
 AC_DEFUN_ONCE([AM_PROG_CC_C_O], [AC_REQUIRE([AC_PROG_CC])])
 
-# Copyright (C) 2001-2020 Free Software Foundation, Inc.
+# Copyright (C) 2022-2024 Free Software Foundation, Inc.
+#
+# This file is free software; the Free Software Foundation
+# gives unlimited permission to copy and/or distribute it,
+# with or without modifications, as long as this notice is preserved.
+
+# _AM_PROG_RM_F
+# ---------------
+# Check whether 'rm -f' without any arguments works.
+# https://bugs.gnu.org/10828
+AC_DEFUN([_AM_PROG_RM_F],
+[am__rm_f_notfound=
+AS_IF([(rm -f && rm -fr && rm -rf) 2>/dev/null], [], [am__rm_f_notfound='""'])
+AC_SUBST(am__rm_f_notfound)
+])
+
+# Copyright (C) 2001-2024 Free Software Foundation, Inc.
 #
 # This file is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -930,16 +928,169 @@ AC_DEFUN([AM_RUN_LOG],
 
 # Check to make sure that the build environment is sane.    -*- Autoconf -*-
 
-# Copyright (C) 1996-2020 Free Software Foundation, Inc.
+# Copyright (C) 1996-2024 Free Software Foundation, Inc.
 #
 # This file is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
 # with or without modifications, as long as this notice is preserved.
 
+# _AM_SLEEP_FRACTIONAL_SECONDS
+# ----------------------------
+AC_DEFUN([_AM_SLEEP_FRACTIONAL_SECONDS], [dnl
+AC_CACHE_CHECK([whether sleep supports fractional seconds],
+               am_cv_sleep_fractional_seconds, [dnl
+AS_IF([sleep 0.001 2>/dev/null], [am_cv_sleep_fractional_seconds=yes],
+                                 [am_cv_sleep_fractional_seconds=no])
+])])
+
+# _AM_FILESYSTEM_TIMESTAMP_RESOLUTION
+# -----------------------------------
+# Determine the filesystem's resolution for file modification
+# timestamps.  The coarsest we know of is FAT, with a resolution
+# of only two seconds, even with the most recent "exFAT" extensions.
+# The finest (e.g. ext4 with large inodes, XFS, ZFS) is one
+# nanosecond, matching clock_gettime.  However, it is probably not
+# possible to delay execution of a shell script for less than one
+# millisecond, due to process creation overhead and scheduling
+# granularity, so we don't check for anything finer than that. (See below.)
+AC_DEFUN([_AM_FILESYSTEM_TIMESTAMP_RESOLUTION], [dnl
+AC_REQUIRE([_AM_SLEEP_FRACTIONAL_SECONDS])
+AC_CACHE_CHECK([filesystem timestamp resolution],
+               am_cv_filesystem_timestamp_resolution, [dnl
+# Default to the worst case.
+am_cv_filesystem_timestamp_resolution=2
+
+# Only try to go finer than 1 sec if sleep can do it.
+# Don't try 1 sec, because if 0.01 sec and 0.1 sec don't work,
+# - 1 sec is not much of a win compared to 2 sec, and
+# - it takes 2 seconds to perform the test whether 1 sec works.
+# 
+# Instead, just use the default 2s on platforms that have 1s resolution,
+# accept the extra 1s delay when using $sleep in the Automake tests, in
+# exchange for not incurring the 2s delay for running the test for all
+# packages.
+#
+am_try_resolutions=
+if test "$am_cv_sleep_fractional_seconds" = yes; then
+  # Even a millisecond often causes a bunch of false positives,
+  # so just try a hundredth of a second. The time saved between .001 and
+  # .01 is not terribly consequential.
+  am_try_resolutions="0.01 0.1 $am_try_resolutions"
+fi
+
+# In order to catch current-generation FAT out, we must *modify* files
+# that already exist; the *creation* timestamp is finer.  Use names
+# that make ls -t sort them differently when they have equal
+# timestamps than when they have distinct timestamps, keeping
+# in mind that ls -t prints the *newest* file first.
+rm -f conftest.ts?
+: > conftest.ts1
+: > conftest.ts2
+: > conftest.ts3
+
+# Make sure ls -t actually works.  Do 'set' in a subshell so we don't
+# clobber the current shell's arguments. (Outer-level square brackets
+# are removed by m4; they're present so that m4 does not expand
+# <dollar><star>; be careful, easy to get confused.)
+if (
+     set X `[ls -t conftest.ts[12]]` &&
+     {
+       test "$[]*" != "X conftest.ts1 conftest.ts2" ||
+       test "$[]*" != "X conftest.ts2 conftest.ts1";
+     }
+); then :; else
+  # If neither matched, then we have a broken ls.  This can happen
+  # if, for instance, CONFIG_SHELL is bash and it inherits a
+  # broken ls alias from the environment.  This has actually
+  # happened.  Such a system could not be considered "sane".
+  _AS_ECHO_UNQUOTED(
+    ["Bad output from ls -t: \"`[ls -t conftest.ts[12]]`\""],
+    [AS_MESSAGE_LOG_FD])
+  AC_MSG_FAILURE([ls -t produces unexpected output.
+Make sure there is not a broken ls alias in your environment.])
+fi
+
+for am_try_res in $am_try_resolutions; do
+  # Any one fine-grained sleep might happen to cross the boundary
+  # between two values of a coarser actual resolution, but if we do
+  # two fine-grained sleeps in a row, at least one of them will fall
+  # entirely within a coarse interval.
+  echo alpha > conftest.ts1
+  sleep $am_try_res
+  echo beta > conftest.ts2
+  sleep $am_try_res
+  echo gamma > conftest.ts3
+
+  # We assume that 'ls -t' will make use of high-resolution
+  # timestamps if the operating system supports them at all.
+  if (set X `ls -t conftest.ts?` &&
+      test "$[]2" = conftest.ts3 &&
+      test "$[]3" = conftest.ts2 &&
+      test "$[]4" = conftest.ts1); then
+    #
+    # Ok, ls -t worked. If we're at a resolution of 1 second, we're done,
+    # because we don't need to test make.
+    make_ok=true
+    if test $am_try_res != 1; then
+      # But if we've succeeded so far with a subsecond resolution, we
+      # have one more thing to check: make. It can happen that
+      # everything else supports the subsecond mtimes, but make doesn't;
+      # notably on macOS, which ships make 3.81 from 2006 (the last one
+      # released under GPLv2). https://bugs.gnu.org/68808
+      # 
+      # We test $MAKE if it is defined in the environment, else "make".
+      # It might get overridden later, but our hope is that in practice
+      # it does not matter: it is the system "make" which is (by far)
+      # the most likely to be broken, whereas if the user overrides it,
+      # probably they did so with a better, or at least not worse, make.
+      # https://lists.gnu.org/archive/html/automake/2024-06/msg00051.html
+      #
+      # Create a Makefile (real tab character here):
+      rm -f conftest.mk
+      echo 'conftest.ts1: conftest.ts2' >conftest.mk
+      echo '	touch conftest.ts2' >>conftest.mk
+      #
+      # Now, running
+      #   touch conftest.ts1; touch conftest.ts2; make
+      # should touch ts1 because ts2 is newer. This could happen by luck,
+      # but most often, it will fail if make's support is insufficient. So
+      # test for several consecutive successes.
+      #
+      # (We reuse conftest.ts[12] because we still want to modify existing
+      # files, not create new ones, per above.)
+      n=0
+      make=${MAKE-make}
+      until test $n -eq 3; do
+        echo one > conftest.ts1
+        sleep $am_try_res
+        echo two > conftest.ts2 # ts2 should now be newer than ts1
+        if $make -f conftest.mk | grep 'up to date' >/dev/null; then
+          make_ok=false
+          break # out of $n loop
+        fi
+        n=`expr $n + 1`
+      done
+    fi
+    #
+    if $make_ok; then
+      # Everything we know to check worked out, so call this resolution good.
+      am_cv_filesystem_timestamp_resolution=$am_try_res
+      break # out of $am_try_res loop
+    fi
+    # Otherwise, we'll go on to check the next resolution.
+  fi
+done
+rm -f conftest.ts?
+# (end _am_filesystem_timestamp_resolution)
+])])
+
 # AM_SANITY_CHECK
 # ---------------
 AC_DEFUN([AM_SANITY_CHECK],
-[AC_MSG_CHECKING([whether build environment is sane])
+[AC_REQUIRE([_AM_FILESYSTEM_TIMESTAMP_RESOLUTION])
+# This check should not be cached, as it may vary across builds of
+# different projects.
+AC_MSG_CHECKING([whether build environment is sane])
 # Reject unsafe characters in $srcdir or the absolute working directory
 # name.  Accept space and tab only in the latter.
 am_lf='
@@ -958,49 +1109,40 @@ esac
 # symlink; some systems play weird games with the mod time of symlinks
 # (eg FreeBSD returns the mod time of the symlink's containing
 # directory).
-if (
-   am_has_slept=no
-   for am_try in 1 2; do
-     echo "timestamp, slept: $am_has_slept" > conftest.file
-     set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null`
-     if test "$[*]" = "X"; then
-	# -L didn't work.
-	set X `ls -t "$srcdir/configure" conftest.file`
-     fi
-     if test "$[*]" != "X $srcdir/configure conftest.file" \
-	&& test "$[*]" != "X conftest.file $srcdir/configure"; then
-
-	# If neither matched, then we have a broken ls.  This can happen
-	# if, for instance, CONFIG_SHELL is bash and it inherits a
-	# broken ls alias from the environment.  This has actually
-	# happened.  Such a system could not be considered "sane".
-	AC_MSG_ERROR([ls -t appears to fail.  Make sure there is not a broken
-  alias in your environment])
-     fi
-     if test "$[2]" = conftest.file || test $am_try -eq 2; then
-       break
-     fi
-     # Just in case.
-     sleep 1
-     am_has_slept=yes
-   done
-   test "$[2]" = conftest.file
-   )
-then
-   # Ok.
-   :
-else
-   AC_MSG_ERROR([newly created file is older than distributed files!
+am_build_env_is_sane=no
+am_has_slept=no
+rm -f conftest.file
+for am_try in 1 2; do
+  echo "timestamp, slept: $am_has_slept" > conftest.file
+  if (
+    set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null`
+    if test "$[]*" = "X"; then
+      # -L didn't work.
+      set X `ls -t "$srcdir/configure" conftest.file`
+    fi
+    test "$[]2" = conftest.file
+  ); then
+    am_build_env_is_sane=yes
+    break
+  fi
+  # Just in case.
+  sleep "$am_cv_filesystem_timestamp_resolution"
+  am_has_slept=yes
+done
+
+AC_MSG_RESULT([$am_build_env_is_sane])
+if test "$am_build_env_is_sane" = no; then
+  AC_MSG_ERROR([newly created file is older than distributed files!
 Check your system clock])
 fi
-AC_MSG_RESULT([yes])
+
 # If we didn't sleep, we still need to ensure time stamps of config.status and
 # generated files are strictly newer.
 am_sleep_pid=
-if grep 'slept: no' conftest.file >/dev/null 2>&1; then
-  ( sleep 1 ) &
+AS_IF([test -e conftest.file || grep 'slept: no' conftest.file >/dev/null 2>&1],, [dnl
+  ( sleep "$am_cv_filesystem_timestamp_resolution" ) &
   am_sleep_pid=$!
-fi
+])
 AC_CONFIG_COMMANDS_PRE(
   [AC_MSG_CHECKING([that generated files are newer than configure])
    if test -n "$am_sleep_pid"; then
@@ -1011,18 +1153,18 @@ AC_CONFIG_COMMANDS_PRE(
 rm -f conftest.file
 ])
 
-# Copyright (C) 2009-2020 Free Software Foundation, Inc.
+# Copyright (C) 2009-2024 Free Software Foundation, Inc.
 #
 # This file is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
 # with or without modifications, as long as this notice is preserved.
 
-# AM_SILENT_RULES([DEFAULT])
-# --------------------------
-# Enable less verbose build rules; with the default set to DEFAULT
-# ("yes" being less verbose, "no" or empty being verbose).
-AC_DEFUN([AM_SILENT_RULES],
-[AC_ARG_ENABLE([silent-rules], [dnl
+# _AM_SILENT_RULES
+# ----------------
+# Enable less verbose build rules support.
+AC_DEFUN([_AM_SILENT_RULES],
+[AM_DEFAULT_VERBOSITY=1
+AC_ARG_ENABLE([silent-rules], [dnl
 AS_HELP_STRING(
   [--enable-silent-rules],
   [less verbose build output (undo: "make V=1")])
@@ -1030,11 +1172,6 @@ AS_HELP_STRING(
   [--disable-silent-rules],
   [verbose build output (undo: "make V=0")])dnl
 ])
-case $enable_silent_rules in @%:@ (((
-  yes) AM_DEFAULT_VERBOSITY=0;;
-   no) AM_DEFAULT_VERBOSITY=1;;
-    *) AM_DEFAULT_VERBOSITY=m4_if([$1], [yes], [0], [1]);;
-esac
 dnl
 dnl A few 'make' implementations (e.g., NonStop OS and NextStep)
 dnl do not support nested variable expansions.
@@ -1053,14 +1190,6 @@ am__doit:
 else
   am_cv_make_support_nested_variables=no
 fi])
-if test $am_cv_make_support_nested_variables = yes; then
-  dnl Using '$V' instead of '$(V)' breaks IRIX make.
-  AM_V='$(V)'
-  AM_DEFAULT_V='$(AM_DEFAULT_VERBOSITY)'
-else
-  AM_V=$AM_DEFAULT_VERBOSITY
-  AM_DEFAULT_V=$AM_DEFAULT_VERBOSITY
-fi
 AC_SUBST([AM_V])dnl
 AM_SUBST_NOTMAKE([AM_V])dnl
 AC_SUBST([AM_DEFAULT_V])dnl
@@ -1069,9 +1198,33 @@ AC_SUBST([AM_DEFAULT_VERBOSITY])dnl
 AM_BACKSLASH='\'
 AC_SUBST([AM_BACKSLASH])dnl
 _AM_SUBST_NOTMAKE([AM_BACKSLASH])dnl
+dnl Delay evaluation of AM_DEFAULT_VERBOSITY to the end to allow multiple calls
+dnl to AM_SILENT_RULES to change the default value.
+AC_CONFIG_COMMANDS_PRE([dnl
+case $enable_silent_rules in @%:@ (((
+  yes) AM_DEFAULT_VERBOSITY=0;;
+   no) AM_DEFAULT_VERBOSITY=1;;
+esac
+if test $am_cv_make_support_nested_variables = yes; then
+  dnl Using '$V' instead of '$(V)' breaks IRIX make.
+  AM_V='$(V)'
+  AM_DEFAULT_V='$(AM_DEFAULT_VERBOSITY)'
+else
+  AM_V=$AM_DEFAULT_VERBOSITY
+  AM_DEFAULT_V=$AM_DEFAULT_VERBOSITY
+fi
+])dnl
 ])
 
-# Copyright (C) 2001-2020 Free Software Foundation, Inc.
+# AM_SILENT_RULES([DEFAULT])
+# --------------------------
+# Set the default verbosity level to DEFAULT ("yes" being less verbose, "no" or
+# empty being verbose).
+AC_DEFUN([AM_SILENT_RULES],
+[AC_REQUIRE([_AM_SILENT_RULES])
+AM_DEFAULT_VERBOSITY=m4_if([$1], [yes], [0], [1])])
+
+# Copyright (C) 2001-2024 Free Software Foundation, Inc.
 #
 # This file is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -1099,7 +1252,7 @@ fi
 INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s"
 AC_SUBST([INSTALL_STRIP_PROGRAM])])
 
-# Copyright (C) 2006-2020 Free Software Foundation, Inc.
+# Copyright (C) 2006-2024 Free Software Foundation, Inc.
 #
 # This file is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -1118,7 +1271,7 @@ AC_DEFUN([AM_SUBST_NOTMAKE], [_AM_SUBST_NOTMAKE($@)])
 
 # Check how to create a tarball.                            -*- Autoconf -*-
 
-# Copyright (C) 2004-2020 Free Software Foundation, Inc.
+# Copyright (C) 2004-2024 Free Software Foundation, Inc.
 #
 # This file is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -1164,15 +1317,19 @@ m4_if([$1], [v7],
       am_uid=`id -u || echo unknown`
       am_gid=`id -g || echo unknown`
       AC_MSG_CHECKING([whether UID '$am_uid' is supported by ustar format])
-      if test $am_uid -le $am_max_uid; then
-         AC_MSG_RESULT([yes])
+      if test x$am_uid = xunknown; then
+        AC_MSG_WARN([ancient id detected; assuming current UID is ok, but dist-ustar might not work])
+      elif test $am_uid -le $am_max_uid; then
+        AC_MSG_RESULT([yes])
       else
-         AC_MSG_RESULT([no])
-         _am_tools=none
+        AC_MSG_RESULT([no])
+        _am_tools=none
       fi
       AC_MSG_CHECKING([whether GID '$am_gid' is supported by ustar format])
-      if test $am_gid -le $am_max_gid; then
-         AC_MSG_RESULT([yes])
+      if test x$gm_gid = xunknown; then
+        AC_MSG_WARN([ancient id detected; assuming current GID is ok, but dist-ustar might not work])
+      elif test $am_gid -le $am_max_gid; then
+        AC_MSG_RESULT([yes])
       else
         AC_MSG_RESULT([no])
         _am_tools=none
@@ -1249,6 +1406,26 @@ AC_SUBST([am__tar])
 AC_SUBST([am__untar])
 ]) # _AM_PROG_TAR
 
+# Copyright (C) 2022-2024 Free Software Foundation, Inc.
+#
+# This file is free software; the Free Software Foundation
+# gives unlimited permission to copy and/or distribute it,
+# with or without modifications, as long as this notice is preserved.
+
+# _AM_PROG_XARGS_N
+# ----------------
+# Check whether 'xargs -n' works.  It should work everywhere, so the fallback
+# is not optimized at all as we never expect to use it.
+AC_DEFUN([_AM_PROG_XARGS_N],
+[AC_CACHE_CHECK([xargs -n works], am_cv_xargs_n_works, [dnl
+AS_IF([test "`echo 1 2 3 | xargs -n2 echo`" = "1 2
+3"], [am_cv_xargs_n_works=yes], [am_cv_xargs_n_works=no])])
+AS_IF([test "$am_cv_xargs_n_works" = yes], [am__xargs_n='xargs -n'], [dnl
+  am__xargs_n='am__xargs_n () { shift; sed "s/ /\\n/g" | while read am__xargs_n_arg; do "$@" "$am__xargs_n_arg"; done; }'
+])dnl
+AC_SUBST(am__xargs_n)
+])
+
 m4_include([m4/libopts.m4])
 m4_include([m4/libtool.m4])
 m4_include([m4/ltoptions.m4])

+ 11 - 3
config/ar-lib

@@ -2,9 +2,9 @@
 # Wrapper for Microsoft lib.exe
 
 me=ar-lib
-scriptversion=2019-07-04.01; # UTC
+scriptversion=2024-06-19.01; # UTC
 
-# Copyright (C) 2010-2020 Free Software Foundation, Inc.
+# Copyright (C) 2010-2024 Free Software Foundation, Inc.
 # Written by Peter Rosin <peda@lysator.liu.se>.
 #
 # This program is free software; you can redistribute it and/or modify
@@ -105,11 +105,15 @@ case $1 in
 Usage: $me [--help] [--version] PROGRAM ACTION ARCHIVE [MEMBER...]
 
 Members may be specified in a file named with @FILE.
+
+Report bugs to <bug-automake@gnu.org>.
+GNU Automake home page: <https://www.gnu.org/software/automake/>.
+General help using GNU software: <https://www.gnu.org/gethelp/>.
 EOF
     exit $?
     ;;
   -v | --v*)
-    echo "$me, version $scriptversion"
+    echo "$me (GNU Automake) $scriptversion"
     exit $?
     ;;
 esac
@@ -135,6 +139,10 @@ do
       AR="$AR $1"
       shift
       ;;
+    -nologo | -NOLOGO)
+      # We always invoke AR with -nologo, so don't need to add it again.
+      shift
+      ;;
     *)
       action=$1
       shift

+ 7 - 4
config/compile

@@ -1,9 +1,9 @@
 #! /bin/sh
 # Wrapper for compilers which do not understand '-c -o'.
 
-scriptversion=2018-03-07.03; # UTC
+scriptversion=2024-06-19.01; # UTC
 
-# Copyright (C) 1999-2020 Free Software Foundation, Inc.
+# Copyright (C) 1999-2024 Free Software Foundation, Inc.
 # Written by Tom Tromey <tromey@cygnus.com>.
 #
 # This program is free software; you can redistribute it and/or modify
@@ -143,7 +143,7 @@ func_cl_wrapper ()
 	  # configure might choose to run compile as 'compile cc -o foo foo.c'.
 	  eat=1
 	  case $2 in
-	    *.o | *.[oO][bB][jJ])
+	    *.o | *.lo | *.[oO][bB][jJ])
 	      func_file_conv "$2"
 	      set x "$@" -Fo"$file"
 	      shift
@@ -248,14 +248,17 @@ If you are trying to build a whole package this is not the
 right script to run: please start by reading the file 'INSTALL'.
 
 Report bugs to <bug-automake@gnu.org>.
+GNU Automake home page: <https://www.gnu.org/software/automake/>.
+General help using GNU software: <https://www.gnu.org/gethelp/>.
 EOF
     exit $?
     ;;
   -v | --v*)
-    echo "compile $scriptversion"
+    echo "compile (GNU Automake) $scriptversion"
     exit $?
     ;;
   cl | *[/\\]cl | cl.exe | *[/\\]cl.exe | \
+  clang-cl | *[/\\]clang-cl | clang-cl.exe | *[/\\]clang-cl.exe | \
   icl | *[/\\]icl | icl.exe | *[/\\]icl.exe )
     func_cl_wrapper "$@"      # Doesn't return...
     ;;

File diff suppressed because it is too large
+ 959 - 624
config/config.guess


File diff suppressed because it is too large
+ 1860 - 1307
config/config.sub


+ 8 - 7
config/depcomp

@@ -1,9 +1,9 @@
 #! /bin/sh
 # depcomp - compile a program generating dependencies as side-effects
 
-scriptversion=2018-03-07.03; # UTC
+scriptversion=2024-06-19.01; # UTC
 
-# Copyright (C) 1999-2020 Free Software Foundation, Inc.
+# Copyright (C) 1999-2024 Free Software Foundation, Inc.
 
 # This program is free software; you can redistribute it and/or modify
 # it under the terms of the GNU General Public License as published by
@@ -47,11 +47,13 @@ Environment variables:
   libtool     Whether libtool is used (yes/no).
 
 Report bugs to <bug-automake@gnu.org>.
+GNU Automake home page: <https://www.gnu.org/software/automake/>.
+General help using GNU software: <https://www.gnu.org/gethelp/>.
 EOF
     exit $?
     ;;
   -v | --v*)
-    echo "depcomp $scriptversion"
+    echo "depcomp (GNU Automake) $scriptversion"
     exit $?
     ;;
 esac
@@ -113,7 +115,6 @@ nl='
 # These definitions help.
 upper=ABCDEFGHIJKLMNOPQRSTUVWXYZ
 lower=abcdefghijklmnopqrstuvwxyz
-digits=0123456789
 alpha=${upper}${lower}
 
 if test -z "$depmode" || test -z "$source" || test -z "$object"; then
@@ -128,7 +129,7 @@ tmpdepfile=${tmpdepfile-`echo "$depfile" | sed 's/\.\([^.]*\)$/.T\1/'`}
 
 rm -f "$tmpdepfile"
 
-# Avoid interferences from the environment.
+# Avoid interference from the environment.
 gccflag= dashmflag=
 
 # Some modes work just like other modes, but use different flags.  We
@@ -198,8 +199,8 @@ gcc3)
   ;;
 
 gcc)
-## Note that this doesn't just cater to obsosete pre-3.x GCC compilers.
-## but also to in-use compilers like IMB xlc/xlC and the HP C compiler.
+## Note that this doesn't just cater to obsolete pre-3.x GCC compilers.
+## but also to in-use compilers like IBM xlc/xlC and the HP C compiler.
 ## (see the conditional assignment to $gccflag above).
 ## There are various ways to get dependency output from gcc.  Here's
 ## why we pick this rather obscure method:

+ 7 - 7
config/install-sh

@@ -1,7 +1,7 @@
 #!/bin/sh
 # install - install a program, script, or datafile
 
-scriptversion=2020-11-14.01; # UTC
+scriptversion=2024-06-19.01; # UTC
 
 # This originates from X11R5 (mit/util/scripts/install.sh), which was
 # later released in X11R6 (xc/config/util/install.sh) with the
@@ -124,9 +124,9 @@ it's up to you to specify -f if you want it.
 
 If -S is not specified, no backups are attempted.
 
-Email bug reports to bug-automake@gnu.org.
-Automake home page: https://www.gnu.org/software/automake/
-"
+Report bugs to <bug-automake@gnu.org>.
+GNU Automake home page: <https://www.gnu.org/software/automake/>.
+General help using GNU software: <https://www.gnu.org/gethelp/>."
 
 while test $# -ne 0; do
   case $1 in
@@ -170,7 +170,7 @@ while test $# -ne 0; do
 
     -T) is_target_a_directory=never;;
 
-    --version) echo "$0 $scriptversion"; exit $?;;
+    --version) echo "$0 (GNU Automake) $scriptversion"; exit $?;;
 
     --) shift
         break;;
@@ -345,7 +345,7 @@ do
 	' 0
 
 	# Because "mkdir -p" follows existing symlinks and we likely work
-	# directly in world-writeable /tmp, make sure that the '$tmpdir'
+	# directly in world-writable /tmp, make sure that the '$tmpdir'
 	# directory is successfully created first before we actually test
 	# 'mkdir -p'.
 	if (umask $mkdir_umask &&
@@ -353,7 +353,7 @@ do
 	    exec $mkdirprog $mkdir_mode -p -- "$tmpdir/a/b") >/dev/null 2>&1
 	then
 	  if test -z "$dir_arg" || {
-	       # Check for POSIX incompatibilities with -m.
+	       # Check for POSIX incompatibility with -m.
 	       # HP-UX 11.23 and IRIX 6.5 mkdir -m -p sets group- or
 	       # other-writable bit of parent directory when it shouldn't.
 	       # FreeBSD 6.1 mkdir -m -p sets mode of existing directory.

File diff suppressed because it is too large
+ 912 - 640
config/ltmain.sh


+ 48 - 27
config/missing

@@ -1,9 +1,11 @@
 #! /bin/sh
-# Common wrapper for a few potentially missing GNU programs.
+# Common wrapper for a few potentially missing GNU and other programs.
 
-scriptversion=2018-03-07.03; # UTC
+scriptversion=2024-06-07.14; # UTC
 
-# Copyright (C) 1996-2020 Free Software Foundation, Inc.
+# shellcheck disable=SC2006,SC2268 # we must support pre-POSIX shells
+
+# Copyright (C) 1996-2024 Free Software Foundation, Inc.
 # Originally written by Fran,cois Pinard <pinard@iro.umontreal.ca>, 1996.
 
 # This program is free software; you can redistribute it and/or modify
@@ -54,18 +56,20 @@ Options:
   -v, --version   output version information and exit
 
 Supported PROGRAM values:
-  aclocal   autoconf  autoheader   autom4te  automake  makeinfo
-  bison     yacc      flex         lex       help2man
+aclocal autoconf autogen  autoheader autom4te automake autoreconf
+bison   flex     help2man lex        makeinfo perl     yacc
 
 Version suffixes to PROGRAM as well as the prefixes 'gnu-', 'gnu', and
 'g' are ignored when checking the name.
 
-Send bug reports to <bug-automake@gnu.org>."
+Report bugs to <bug-automake@gnu.org>.
+GNU Automake home page: <https://www.gnu.org/software/automake/>.
+General help using GNU software: <https://www.gnu.org/gethelp/>."
     exit $?
     ;;
 
   -v|--v|--ve|--ver|--vers|--versi|--versio|--version)
-    echo "missing $scriptversion (GNU Automake)"
+    echo "missing (GNU Automake) $scriptversion"
     exit $?
     ;;
 
@@ -108,7 +112,7 @@ gnu_software_URL=https://www.gnu.org/software
 program_details ()
 {
   case $1 in
-    aclocal|automake)
+    aclocal|automake|autoreconf)
       echo "The '$1' program is part of the GNU Automake package:"
       echo "<$gnu_software_URL/automake>"
       echo "It also requires GNU Autoconf, GNU m4 and Perl in order to run:"
@@ -123,6 +127,9 @@ program_details ()
       echo "<$gnu_software_URL/m4/>"
       echo "<$perl_URL>"
       ;;
+    *)
+      :
+      ;;
   esac
 }
 
@@ -137,48 +144,55 @@ give_advice ()
   printf '%s\n' "'$1' is $msg."
 
   configure_deps="'configure.ac' or m4 files included by 'configure.ac'"
+  autoheader_deps="'acconfig.h'"
+  automake_deps="'Makefile.am'"
+  aclocal_deps="'acinclude.m4'"
   case $normalized_program in
+    aclocal*)
+      echo "You should only need it if you modified $aclocal_deps or"
+      echo "$configure_deps."
+      ;;
     autoconf*)
-      echo "You should only need it if you modified 'configure.ac',"
-      echo "or m4 files included by it."
-      program_details 'autoconf'
+      echo "You should only need it if you modified $configure_deps."
+      ;;
+    autogen*)
+      echo "You should only need it if you modified a '.def' or '.tpl' file."
+      echo "You may want to install the GNU AutoGen package:"
+      echo "<$gnu_software_URL/autogen/>"
       ;;
     autoheader*)
-      echo "You should only need it if you modified 'acconfig.h' or"
+      echo "You should only need it if you modified $autoheader_deps or"
       echo "$configure_deps."
-      program_details 'autoheader'
       ;;
     automake*)
-      echo "You should only need it if you modified 'Makefile.am' or"
-      echo "$configure_deps."
-      program_details 'automake'
-      ;;
-    aclocal*)
-      echo "You should only need it if you modified 'acinclude.m4' or"
+      echo "You should only need it if you modified $automake_deps or"
       echo "$configure_deps."
-      program_details 'aclocal'
       ;;
-   autom4te*)
+    autom4te*)
       echo "You might have modified some maintainer files that require"
       echo "the 'autom4te' program to be rebuilt."
-      program_details 'autom4te'
+      ;;
+    autoreconf*)
+      echo "You should only need it if you modified $aclocal_deps or"
+      echo "$automake_deps or $autoheader_deps or $automake_deps or"
+      echo "$configure_deps."
       ;;
     bison*|yacc*)
       echo "You should only need it if you modified a '.y' file."
       echo "You may want to install the GNU Bison package:"
       echo "<$gnu_software_URL/bison/>"
       ;;
-    lex*|flex*)
-      echo "You should only need it if you modified a '.l' file."
-      echo "You may want to install the Fast Lexical Analyzer package:"
-      echo "<$flex_URL>"
-      ;;
     help2man*)
       echo "You should only need it if you modified a dependency" \
            "of a man page."
       echo "You may want to install the GNU Help2man package:"
       echo "<$gnu_software_URL/help2man/>"
     ;;
+    lex*|flex*)
+      echo "You should only need it if you modified a '.l' file."
+      echo "You may want to install the Fast Lexical Analyzer package:"
+      echo "<$flex_URL>"
+      ;;
     makeinfo*)
       echo "You should only need it if you modified a '.texi' file, or"
       echo "any other file indirectly affecting the aspect of the manual."
@@ -189,6 +203,12 @@ give_advice ()
       echo "want to install GNU make:"
       echo "<$gnu_software_URL/make/>"
       ;;
+    perl*)
+      echo "You should only need it to run GNU Autoconf, GNU Automake, "
+      echo "  assorted other tools, or if you modified a Perl source file."
+      echo "You may want to install the Perl 5 language interpreter:"
+      echo "<$perl_URL>"
+      ;;
     *)
       echo "You might have modified some files without having the proper"
       echo "tools for further handling them.  Check the 'README' file, it"
@@ -197,6 +217,7 @@ give_advice ()
       echo "case some other package contains this missing '$1' program."
       ;;
   esac
+  program_details "$normalized_program"
 }
 
 give_advice "$1" | sed -e '1s/^/WARNING: /' \

File diff suppressed because it is too large
+ 10607 - 6727
configure


+ 18 - 8
configure.ac

@@ -4,7 +4,7 @@ dnl $Id$
 AC_PREREQ([2.69])
 
 dnl Set version info here!
-AC_INIT([tcpreplay],[4.5.1],[https://github.com/appneta/tcpreplay/issues],[tcpreplay],[http://tcpreplay.sourceforge.net/])
+AC_INIT([tcpreplay],[4.5.2],[https://github.com/appneta/tcpreplay/issues],[tcpreplay],[http://tcpreplay.sourceforge.net/])
 AC_CONFIG_SRCDIR([src/tcpreplay.c])
 AC_CONFIG_HEADERS([src/config.h])
 AC_CONFIG_AUX_DIR(config)
@@ -273,10 +273,16 @@ AC_FUNC_FSEEKO
 
 dnl Check for types.
 AC_CHECK_TYPE(u_int8_t, uint8_t)
+AC_CHECK_TYPE(u_char, uint8_t)
 AC_CHECK_TYPE(u_int16_t, uint16_t)
+AC_CHECK_TYPE(u_short, uint16_t)
+AC_CHECK_TYPE(u_int, uint32_t)
 AC_CHECK_TYPE(u_int32_t, uint32_t)
 AC_CHECK_TYPE(u_int64_t, uint64_t)
 
+# required by C23 standard
+CFLAGS="-D_DEFAULT_SOURCE $CFLAGS"
+
 dnl OS X SDK 10.11 throws lots of unnecessary macro warnings
 wno_format=""
 wno_macro_redefined=""
@@ -710,13 +716,9 @@ AC_ARG_WITH(libpcap,
                         LPCAP_LD_LIBRARY_PATH="$(dirname ${sharefile})"
                         LPCAPLIB="-L$LPCAP_LD_LIBRARY_PATH -lpcap"
                         foundpcap=$testdir
-                        break
+                        break 2
                     fi
                 done
-
-                if ! test $foundpcap = no; then
-                    break
-                fi
             done
         else
             dnl
@@ -728,10 +730,9 @@ AC_ARG_WITH(libpcap,
                     if test -n "${staticfile}"; then
                         LPCAPLIB="${staticfile}"
                         foundpcap=${testdir}
-                        break
+                        break 2
                     fi
                 done
-
             done
         fi
 
@@ -1934,6 +1935,15 @@ case $host in
     ;;
 esac])
 
+AC_ARG_ENABLE([test_hexdump],
+    AS_HELP_STRING([--enable-test-hexdump],[Enable hexdump pcap on test failure]))
+if test "x$enable_test_hexdump" = "xyes"; then
+        test_hexdump=yes
+else
+        test_hexdump=no
+fi
+AC_SUBST(test_hexdump)
+
 dnl There's a bug in OS X which causes pcap_findalldevs() to make the wifi NIC to disassociate
 dnl so under OSX we disable the interface list feature
 disable_pcap_findalldevs=no

+ 24 - 1
docs/CHANGELOG

@@ -1,3 +1,26 @@
+08/26/2025 Version 4.5.2
+    - C23 standard support (#977)
+    - --fixlen use-after-free (#970)
+    - gcc 15 out-of-tree build failure (#967)
+    - better error handling for XDP send errors (#956)
+    - stdbool.h not detected correctly (#947)
+    - AF_XDP memory leaks (#935)
+    - GitHub Actions CI failure (#933)
+    - heap address leak in xX.c (#928)
+    - TX_RING compile errors (#924)
+    - continue on get_l2len_protcol() is zero (#911)
+    - --infile and --outfile cannot be the same file (#914)
+    - fix building on OpenBSD (#907)
+    - fixup the libpcap search loops (#905)
+    - tcprewrite crash on Juniper crafted packet (#902 #926)
+    - support for IPv6 fragment checksums (#897)
+    - AF_XDP sends at near full speed (#896)
+    - TX_RING link errors on some platforms (#731 #904)
+    - IPv6 header version check incorrect for flow stats (#899)
+    - tcprewrite --portmap syntax error causes crash (#894)
+    - gcc 4.4.4 fails build on FreeBSD (#809)
+    - MAC address sometimes corruptly altered on tcprewrite --seed option (#794 #901)
+
 07/12/2024 Version 4.5.1
     - NULL Pointer Dereference in parse_endpoints (#888)
     - tcpreplay --include / --exclude to control which packets are replayed (#884)
@@ -17,7 +40,7 @@
     - improved 802.3 (Ethernet I) handling and warning messages (#835)
     - handle IPv6 fragment extension header (#832 #837)
     - Linux tap interfaces fail intermittently (#828)
-    - Infinite loop in tcprewrite at get.c (#827 #842)
+    - CVE-2024-22654 CVE-2024-3024Infinite loop in tcprewrite at get.c (#827 #842)
     - SLL incorrect size and protocol when converted to Ethernet (#826)
     - CVE-2023-43279 add check for empty CIDR (#824 #843)
     - AF_XDP socket extension (#822 #823)

+ 7 - 0
docs/CREDIT

@@ -137,6 +137,13 @@ Chen Qi <GitHub ChenQi1989>
 
 Denis Ovsienko <GitHub infrastation>
     - Haiku support
+    - libpcap search fix
 
 Jason Lue <GitHub jasonlue>
     - tcpreplay -w option
+
+Brad Smith <GitHub brad0>
+    - fix build on OpenBSD
+
+Mark Yang <GitHub markyang92>
+    - TX_RING compile issue

+ 21 - 6
docs/Makefile.in

@@ -1,7 +1,7 @@
-# Makefile.in generated by automake 1.16.3 from Makefile.am.
+# Makefile.in generated by automake 1.17 from Makefile.am.
 # @configure_input@
 
-# Copyright (C) 1994-2020 Free Software Foundation, Inc.
+# Copyright (C) 1994-2024 Free Software Foundation, Inc.
 
 # This Makefile.in is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -69,6 +69,8 @@ am__make_running_with_option = \
   test $$has_opt = yes
 am__make_dryrun = (target_option=n; $(am__make_running_with_option))
 am__make_keepgoing = (target_option=k; $(am__make_running_with_option))
+am__rm_f = rm -f $(am__rm_f_notfound)
+am__rm_rf = rm -rf $(am__rm_f_notfound)
 pkgdatadir = $(datadir)/@PACKAGE@
 pkgincludedir = $(includedir)/@PACKAGE@
 pkglibdir = $(libdir)/@PACKAGE@
@@ -141,6 +143,8 @@ CPP = @CPP@
 CPPFLAGS = @CPPFLAGS@
 CROSS_ARCH = @CROSS_ARCH@
 CROSS_LD = @CROSS_LD@
+CSCOPE = @CSCOPE@
+CTAGS = @CTAGS@
 CUT = @CUT@
 CXX = @CXX@
 CXXCPP = @CXXCPP@
@@ -158,8 +162,10 @@ ECHO_C = @ECHO_C@
 ECHO_N = @ECHO_N@
 ECHO_T = @ECHO_T@
 EGREP = @EGREP@
+ETAGS = @ETAGS@
 EXEEXT = @EXEEXT@
 FGREP = @FGREP@
+FILECMD = @FILECMD@
 GREP = @GREP@
 GROFF = @GROFF@
 INSTALL = @INSTALL@
@@ -232,8 +238,10 @@ ac_ct_DUMPBIN = @ac_ct_DUMPBIN@
 am__include = @am__include@
 am__leading_dot = @am__leading_dot@
 am__quote = @am__quote@
+am__rm_f_notfound = @am__rm_f_notfound@
 am__tar = @am__tar@
 am__untar = @am__untar@
+am__xargs_n = @am__xargs_n@
 bindir = @bindir@
 build = @build@
 build_alias = @build_alias@
@@ -288,6 +296,7 @@ target_cpu = @target_cpu@
 target_os = @target_os@
 target_vendor = @target_vendor@
 tcpdump_path = @tcpdump_path@
+test_hexdump = @test_hexdump@
 timestamp_trace_flag = @timestamp_trace_flag@
 top_build_prefix = @top_build_prefix@
 top_builddir = @top_builddir@
@@ -339,7 +348,6 @@ ctags CTAGS:
 
 cscope cscopelist:
 
-
 distdir: $(BUILT_SOURCES)
 	$(MAKE) $(AM_MAKEFLAGS) distdir-am
 
@@ -401,13 +409,13 @@ mostlyclean-generic:
 clean-generic:
 
 distclean-generic:
-	-test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
-	-test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES)
+	-$(am__rm_f) $(CONFIG_CLEAN_FILES)
+	-test . = "$(srcdir)" || $(am__rm_f) $(CONFIG_CLEAN_VPATH_FILES)
 
 maintainer-clean-generic:
 	@echo "This command is intended for maintainers to use"
 	@echo "it deletes files that may require special tools to rebuild."
-	-test -z "$(MAINTAINERCLEANFILES)" || rm -f $(MAINTAINERCLEANFILES)
+	-$(am__rm_f) $(MAINTAINERCLEANFILES)
 clean: clean-am
 
 clean-am: clean-generic clean-libtool mostlyclean-am
@@ -537,3 +545,10 @@ maintainer-clean-local: clean-docs
 # Tell versions [3.59,3.63) of GNU make to not export all variables.
 # Otherwise a system limit (for SysV at least) may be exceeded.
 .NOEXPORT:
+
+# Tell GNU make to disable its built-in pattern rules.
+%:: %,v
+%:: RCS/%,v
+%:: RCS/%
+%:: s.%
+%:: SCCS/s.%

+ 29 - 15
lib/Makefile.in

@@ -1,7 +1,7 @@
-# Makefile.in generated by automake 1.16.3 from Makefile.am.
+# Makefile.in generated by automake 1.17 from Makefile.am.
 # @configure_input@
 
-# Copyright (C) 1994-2020 Free Software Foundation, Inc.
+# Copyright (C) 1994-2024 Free Software Foundation, Inc.
 
 # This Makefile.in is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -71,6 +71,8 @@ am__make_running_with_option = \
   test $$has_opt = yes
 am__make_dryrun = (target_option=n; $(am__make_running_with_option))
 am__make_keepgoing = (target_option=k; $(am__make_running_with_option))
+am__rm_f = rm -f $(am__rm_f_notfound)
+am__rm_rf = rm -rf $(am__rm_f_notfound)
 pkgdatadir = $(datadir)/@PACKAGE@
 pkgincludedir = $(includedir)/@PACKAGE@
 pkglibdir = $(libdir)/@PACKAGE@
@@ -107,12 +109,13 @@ CONFIG_HEADER = $(top_builddir)/src/config.h
 CONFIG_CLEAN_FILES =
 CONFIG_CLEAN_VPATH_FILES =
 LIBRARIES = $(noinst_LIBRARIES)
-ARFLAGS = cru
+ARFLAGS = cr
 AM_V_AR = $(am__v_AR_@AM_V@)
 am__v_AR_ = $(am__v_AR_@AM_DEFAULT_V@)
 am__v_AR_0 = @echo "  AR      " $@;
 am__v_AR_1 = 
 libstrl_a_AR = $(AR) $(ARFLAGS)
+libstrl_a_RANLIB = $(RANLIB)
 libstrl_a_LIBADD =
 am__libstrl_a_SOURCES_DIST = strlcat.c strlcpy.c
 @SYSTEM_STRLCPY_FALSE@am_libstrl_a_OBJECTS = strlcat.$(OBJEXT) \
@@ -182,8 +185,6 @@ am__define_uniq_tagged_files = \
   unique=`for i in $$list; do \
     if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
   done | $(am__uniquify_input)`
-ETAGS = etags
-CTAGS = ctags
 am__DIST_COMMON = $(srcdir)/Makefile.in $(top_srcdir)/config/depcomp
 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
 ACLOCAL = @ACLOCAL@
@@ -202,6 +203,8 @@ CPP = @CPP@
 CPPFLAGS = @CPPFLAGS@
 CROSS_ARCH = @CROSS_ARCH@
 CROSS_LD = @CROSS_LD@
+CSCOPE = @CSCOPE@
+CTAGS = @CTAGS@
 CUT = @CUT@
 CXX = @CXX@
 CXXCPP = @CXXCPP@
@@ -219,8 +222,10 @@ ECHO_C = @ECHO_C@
 ECHO_N = @ECHO_N@
 ECHO_T = @ECHO_T@
 EGREP = @EGREP@
+ETAGS = @ETAGS@
 EXEEXT = @EXEEXT@
 FGREP = @FGREP@
+FILECMD = @FILECMD@
 GREP = @GREP@
 GROFF = @GROFF@
 INSTALL = @INSTALL@
@@ -293,8 +298,10 @@ ac_ct_DUMPBIN = @ac_ct_DUMPBIN@
 am__include = @am__include@
 am__leading_dot = @am__leading_dot@
 am__quote = @am__quote@
+am__rm_f_notfound = @am__rm_f_notfound@
 am__tar = @am__tar@
 am__untar = @am__untar@
+am__xargs_n = @am__xargs_n@
 bindir = @bindir@
 build = @build@
 build_alias = @build_alias@
@@ -349,6 +356,7 @@ target_cpu = @target_cpu@
 target_os = @target_os@
 target_vendor = @target_vendor@
 tcpdump_path = @tcpdump_path@
+test_hexdump = @test_hexdump@
 timestamp_trace_flag = @timestamp_trace_flag@
 top_build_prefix = @top_build_prefix@
 top_builddir = @top_builddir@
@@ -393,12 +401,12 @@ $(ACLOCAL_M4): @MAINTAINER_MODE_TRUE@ $(am__aclocal_m4_deps)
 $(am__aclocal_m4_deps):
 
 clean-noinstLIBRARIES:
-	-test -z "$(noinst_LIBRARIES)" || rm -f $(noinst_LIBRARIES)
+	-$(am__rm_f) $(noinst_LIBRARIES)
 
 libstrl.a: $(libstrl_a_OBJECTS) $(libstrl_a_DEPENDENCIES) $(EXTRA_libstrl_a_DEPENDENCIES) 
 	$(AM_V_at)-rm -f libstrl.a
 	$(AM_V_AR)$(libstrl_a_AR) libstrl.a $(libstrl_a_OBJECTS) $(libstrl_a_LIBADD)
-	$(AM_V_at)$(RANLIB) libstrl.a
+	$(AM_V_at)$(libstrl_a_RANLIB) libstrl.a
 
 mostlyclean-compile:
 	-rm -f *.$(OBJEXT)
@@ -411,7 +419,7 @@ distclean-compile:
 
 $(am__depfiles_remade):
 	@$(MKDIR_P) $(@D)
-	@echo '# dummy' >$@-t && $(am__mv) $@-t $@
+	@: >>$@
 
 am--depfiles: $(am__depfiles_remade)
 
@@ -496,7 +504,6 @@ cscopelist-am: $(am__tagged_files)
 
 distclean-tags:
 	-rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
-
 distdir: $(BUILT_SOURCES)
 	$(MAKE) $(AM_MAKEFLAGS) distdir-am
 
@@ -554,25 +561,25 @@ install-strip:
 	    "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \
 	fi
 mostlyclean-generic:
-	-test -z "$(MOSTLYCLEANFILES)" || rm -f $(MOSTLYCLEANFILES)
+	-$(am__rm_f) $(MOSTLYCLEANFILES)
 
 clean-generic:
 
 distclean-generic:
-	-test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
-	-test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES)
+	-$(am__rm_f) $(CONFIG_CLEAN_FILES)
+	-test . = "$(srcdir)" || $(am__rm_f) $(CONFIG_CLEAN_VPATH_FILES)
 
 maintainer-clean-generic:
 	@echo "This command is intended for maintainers to use"
 	@echo "it deletes files that may require special tools to rebuild."
-	-test -z "$(MAINTAINERCLEANFILES)" || rm -f $(MAINTAINERCLEANFILES)
+	-$(am__rm_f) $(MAINTAINERCLEANFILES)
 clean: clean-am
 
 clean-am: clean-generic clean-libtool clean-noinstLIBRARIES \
 	mostlyclean-am
 
 distclean: distclean-am
-		-rm -f ./$(DEPDIR)/strlcat.Po
+	-rm -f ./$(DEPDIR)/strlcat.Po
 	-rm -f ./$(DEPDIR)/strlcpy.Po
 	-rm -f Makefile
 distclean-am: clean-am distclean-compile distclean-generic \
@@ -619,7 +626,7 @@ install-ps-am:
 installcheck-am:
 
 maintainer-clean: maintainer-clean-am
-		-rm -f ./$(DEPDIR)/strlcat.Po
+	-rm -f ./$(DEPDIR)/strlcat.Po
 	-rm -f ./$(DEPDIR)/strlcpy.Po
 	-rm -f Makefile
 maintainer-clean-am: distclean-am maintainer-clean-generic
@@ -661,3 +668,10 @@ uninstall-am:
 # Tell versions [3.59,3.63) of GNU make to not export all variables.
 # Otherwise a system limit (for SysV at least) may be exceeded.
 .NOEXPORT:
+
+# Tell GNU make to disable its built-in pattern rules.
+%:: %,v
+%:: RCS/%,v
+%:: RCS/%
+%:: s.%
+%:: SCCS/s.%

+ 1 - 4
lib/queue.h

@@ -36,8 +36,7 @@
  *	@(#)queue.h	8.5 (Berkeley) 8/20/94
  */
 
-#ifndef	_SYS_QUEUE_H_
-#define	_SYS_QUEUE_H_
+#pragma once
 
 /*
  * This file defines five types of data structures: singly-linked lists, 
@@ -507,5 +506,3 @@ struct {								\
 	else								\
 		(elm2)->field.cqe_prev->field.cqe_next = (elm2);	\
 } while (0)
-
-#endif /* !_SYS_QUEUE_H_ */

+ 1 - 1
lib/strlcpy.h

@@ -1,6 +1,6 @@
 /*
  *   Copyright (c) 2001-2010 Aaron Turner <aturner at synfin dot net>
- *   Copyright (c) 2013-2024 Fred Klassen <tcpreplay at appneta dot com> - AppNeta
+ *   Copyright (c) 2013-2025 Fred Klassen <tcpreplay at appneta dot com> - AppNeta
  *
  *   The Tcpreplay Suite of tools is free software: you can redistribute it 
  *   and/or modify it under the terms of the GNU General Public License as 

+ 35 - 27
libopts/Makefile.in

@@ -1,7 +1,7 @@
-# Makefile.in generated by automake 1.16.3 from Makefile.am.
+# Makefile.in generated by automake 1.17 from Makefile.am.
 # @configure_input@
 
-# Copyright (C) 1994-2020 Free Software Foundation, Inc.
+# Copyright (C) 1994-2024 Free Software Foundation, Inc.
 
 # This Makefile.in is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -70,6 +70,8 @@ am__make_running_with_option = \
   test $$has_opt = yes
 am__make_dryrun = (target_option=n; $(am__make_running_with_option))
 am__make_keepgoing = (target_option=k; $(am__make_running_with_option))
+am__rm_f = rm -f $(am__rm_f_notfound)
+am__rm_rf = rm -rf $(am__rm_f_notfound)
 pkgdatadir = $(datadir)/@PACKAGE@
 pkgincludedir = $(includedir)/@PACKAGE@
 pkglibdir = $(libdir)/@PACKAGE@
@@ -126,10 +128,9 @@ am__base_list = \
   sed '$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;s/\n/ /g' | \
   sed '$$!N;$$!N;$$!N;$$!N;s/\n/ /g'
 am__uninstall_files_from_dir = { \
-  test -z "$$files" \
-    || { test ! -d "$$dir" && test ! -f "$$dir" && test ! -r "$$dir"; } \
-    || { echo " ( cd '$$dir' && rm -f" $$files ")"; \
-         $(am__cd) "$$dir" && rm -f $$files; }; \
+  { test ! -d "$$dir" && test ! -f "$$dir" && test ! -r "$$dir"; } \
+  || { echo " ( cd '$$dir' && rm -f" $$files ")"; \
+       $(am__cd) "$$dir" && echo $$files | $(am__xargs_n) 40 $(am__rm_f); }; \
   }
 am__installdirs = "$(DESTDIR)$(libdir)"
 LTLIBRARIES = $(lib_LTLIBRARIES) $(noinst_LTLIBRARIES)
@@ -204,8 +205,6 @@ am__define_uniq_tagged_files = \
   unique=`for i in $$list; do \
     if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
   done | $(am__uniquify_input)`
-ETAGS = etags
-CTAGS = ctags
 am__DIST_COMMON = $(srcdir)/Makefile.in $(top_srcdir)/config/depcomp \
 	README
 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
@@ -225,6 +224,8 @@ CPP = @CPP@
 CPPFLAGS = @CPPFLAGS@
 CROSS_ARCH = @CROSS_ARCH@
 CROSS_LD = @CROSS_LD@
+CSCOPE = @CSCOPE@
+CTAGS = @CTAGS@
 CUT = @CUT@
 CXX = @CXX@
 CXXCPP = @CXXCPP@
@@ -242,8 +243,10 @@ ECHO_C = @ECHO_C@
 ECHO_N = @ECHO_N@
 ECHO_T = @ECHO_T@
 EGREP = @EGREP@
+ETAGS = @ETAGS@
 EXEEXT = @EXEEXT@
 FGREP = @FGREP@
+FILECMD = @FILECMD@
 GREP = @GREP@
 GROFF = @GROFF@
 INSTALL = @INSTALL@
@@ -316,8 +319,10 @@ ac_ct_DUMPBIN = @ac_ct_DUMPBIN@
 am__include = @am__include@
 am__leading_dot = @am__leading_dot@
 am__quote = @am__quote@
+am__rm_f_notfound = @am__rm_f_notfound@
 am__tar = @am__tar@
 am__untar = @am__untar@
+am__xargs_n = @am__xargs_n@
 bindir = @bindir@
 build = @build@
 build_alias = @build_alias@
@@ -372,6 +377,7 @@ target_cpu = @target_cpu@
 target_os = @target_os@
 target_vendor = @target_vendor@
 tcpdump_path = @tcpdump_path@
+test_hexdump = @test_hexdump@
 timestamp_trace_flag = @timestamp_trace_flag@
 top_build_prefix = @top_build_prefix@
 top_builddir = @top_builddir@
@@ -463,26 +469,22 @@ uninstall-libLTLIBRARIES:
 	done
 
 clean-libLTLIBRARIES:
-	-test -z "$(lib_LTLIBRARIES)" || rm -f $(lib_LTLIBRARIES)
+	-$(am__rm_f) $(lib_LTLIBRARIES)
 	@list='$(lib_LTLIBRARIES)'; \
 	locs=`for p in $$list; do echo $$p; done | \
 	      sed 's|^[^/]*$$|.|; s|/[^/]*$$||; s|$$|/so_locations|' | \
 	      sort -u`; \
-	test -z "$$locs" || { \
-	  echo rm -f $${locs}; \
-	  rm -f $${locs}; \
-	}
+	echo rm -f $${locs}; \
+	$(am__rm_f) $${locs}
 
 clean-noinstLTLIBRARIES:
-	-test -z "$(noinst_LTLIBRARIES)" || rm -f $(noinst_LTLIBRARIES)
+	-$(am__rm_f) $(noinst_LTLIBRARIES)
 	@list='$(noinst_LTLIBRARIES)'; \
 	locs=`for p in $$list; do echo $$p; done | \
 	      sed 's|^[^/]*$$|.|; s|/[^/]*$$||; s|$$|/so_locations|' | \
 	      sort -u`; \
-	test -z "$$locs" || { \
-	  echo rm -f $${locs}; \
-	  rm -f $${locs}; \
-	}
+	echo rm -f $${locs}; \
+	$(am__rm_f) $${locs}
 
 libopts.la: $(libopts_la_OBJECTS) $(libopts_la_DEPENDENCIES) $(EXTRA_libopts_la_DEPENDENCIES) 
 	$(AM_V_CCLD)$(libopts_la_LINK) $(am_libopts_la_rpath) $(libopts_la_OBJECTS) $(libopts_la_LIBADD) $(LIBS)
@@ -497,7 +499,7 @@ distclean-compile:
 
 $(am__depfiles_remade):
 	@$(MKDIR_P) $(@D)
-	@echo '# dummy' >$@-t && $(am__mv) $@-t $@
+	@: >>$@
 
 am--depfiles: $(am__depfiles_remade)
 
@@ -589,7 +591,6 @@ cscopelist-am: $(am__tagged_files)
 
 distclean-tags:
 	-rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
-
 distdir: $(BUILT_SOURCES)
 	$(MAKE) $(AM_MAKEFLAGS) distdir-am
 
@@ -653,26 +654,26 @@ install-strip:
 	    "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \
 	fi
 mostlyclean-generic:
-	-test -z "$(MOSTLYCLEANFILES)" || rm -f $(MOSTLYCLEANFILES)
+	-$(am__rm_f) $(MOSTLYCLEANFILES)
 
 clean-generic:
 
 distclean-generic:
-	-test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
-	-test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES)
+	-$(am__rm_f) $(CONFIG_CLEAN_FILES)
+	-test . = "$(srcdir)" || $(am__rm_f) $(CONFIG_CLEAN_VPATH_FILES)
 
 maintainer-clean-generic:
 	@echo "This command is intended for maintainers to use"
 	@echo "it deletes files that may require special tools to rebuild."
-	-test -z "$(BUILT_SOURCES)" || rm -f $(BUILT_SOURCES)
-	-test -z "$(MAINTAINERCLEANFILES)" || rm -f $(MAINTAINERCLEANFILES)
+	-$(am__rm_f) $(BUILT_SOURCES)
+	-$(am__rm_f) $(MAINTAINERCLEANFILES)
 clean: clean-am
 
 clean-am: clean-generic clean-libLTLIBRARIES clean-libtool \
 	clean-noinstLTLIBRARIES mostlyclean-am
 
 distclean: distclean-am
-		-rm -f ./$(DEPDIR)/libopts_la-libopts.Plo
+	-rm -f ./$(DEPDIR)/libopts_la-libopts.Plo
 	-rm -f Makefile
 distclean-am: clean-am distclean-compile distclean-generic \
 	distclean-tags
@@ -718,7 +719,7 @@ install-ps-am:
 installcheck-am:
 
 maintainer-clean: maintainer-clean-am
-		-rm -f ./$(DEPDIR)/libopts_la-libopts.Plo
+	-rm -f ./$(DEPDIR)/libopts_la-libopts.Plo
 	-rm -f Makefile
 maintainer-clean-am: distclean-am maintainer-clean-generic
 
@@ -772,3 +773,10 @@ libopts.c:		$(BUILT_SOURCES)
 # Tell versions [3.59,3.63) of GNU make to not export all variables.
 # Otherwise a system limit (for SysV at least) may be exceeded.
 .NOEXPORT:
+
+# Tell GNU make to disable its built-in pattern rules.
+%:: %,v
+%:: RCS/%,v
+%:: RCS/%
+%:: s.%
+%:: SCCS/s.%

File diff suppressed because it is too large
+ 392 - 273
m4/libtool.m4


+ 69 - 39
m4/ltoptions.m4

@@ -1,14 +1,14 @@
 # Helper functions for option handling.                    -*- Autoconf -*-
 #
-#   Copyright (C) 2004-2005, 2007-2009, 2011-2015 Free Software
-#   Foundation, Inc.
+#   Copyright (C) 2004-2005, 2007-2009, 2011-2019, 2021-2024 Free
+#   Software Foundation, Inc.
 #   Written by Gary V. Vaughan, 2004
 #
 # This file is free software; the Free Software Foundation gives
 # unlimited permission to copy and/or distribute it, with or without
 # modifications, as long as this notice is preserved.
 
-# serial 8 ltoptions.m4
+# serial 10 ltoptions.m4
 
 # This is to help aclocal find these macros, as it can't see m4_define.
 AC_DEFUN([LTOPTIONS_VERSION], [m4_if([1])])
@@ -128,7 +128,7 @@ LT_OPTION_DEFINE([LT_INIT], [win32-dll],
 [enable_win32_dll=yes
 
 case $host in
-*-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-cegcc*)
+*-*-cygwin* | *-*-mingw* | *-*-windows* | *-*-pw32* | *-*-cegcc*)
   AC_CHECK_TOOL(AS, as, false)
   AC_CHECK_TOOL(DLLTOOL, dlltool, false)
   AC_CHECK_TOOL(OBJDUMP, objdump, false)
@@ -323,29 +323,39 @@ dnl AC_DEFUN([AM_DISABLE_FAST_INSTALL], [])
 
 # _LT_WITH_AIX_SONAME([DEFAULT])
 # ----------------------------------
-# implement the --with-aix-soname flag, and support the `aix-soname=aix'
-# and `aix-soname=both' and `aix-soname=svr4' LT_INIT options. DEFAULT
-# is either `aix', `both' or `svr4'.  If omitted, it defaults to `aix'.
+# implement the --enable-aix-soname configure option, and support the
+# `aix-soname=aix' and `aix-soname=both' and `aix-soname=svr4' LT_INIT options.
+# DEFAULT is either `aix', `both', or `svr4'.  If omitted, it defaults to `aix'.
 m4_define([_LT_WITH_AIX_SONAME],
 [m4_define([_LT_WITH_AIX_SONAME_DEFAULT], [m4_if($1, svr4, svr4, m4_if($1, both, both, aix))])dnl
 shared_archive_member_spec=
 case $host,$enable_shared in
 power*-*-aix[[5-9]]*,yes)
   AC_MSG_CHECKING([which variant of shared library versioning to provide])
-  AC_ARG_WITH([aix-soname],
-    [AS_HELP_STRING([--with-aix-soname=aix|svr4|both],
+  AC_ARG_ENABLE([aix-soname],
+    [AS_HELP_STRING([--enable-aix-soname=aix|svr4|both],
       [shared library versioning (aka "SONAME") variant to provide on AIX, @<:@default=]_LT_WITH_AIX_SONAME_DEFAULT[@:>@.])],
-    [case $withval in
-    aix|svr4|both)
-      ;;
-    *)
-      AC_MSG_ERROR([Unknown argument to --with-aix-soname])
-      ;;
-    esac
-    lt_cv_with_aix_soname=$with_aix_soname],
-    [AC_CACHE_VAL([lt_cv_with_aix_soname],
-      [lt_cv_with_aix_soname=]_LT_WITH_AIX_SONAME_DEFAULT)
-    with_aix_soname=$lt_cv_with_aix_soname])
+    [case $enableval in
+     aix|svr4|both)
+       ;;
+     *)
+       AC_MSG_ERROR([Unknown argument to --enable-aix-soname])
+       ;;
+     esac
+     lt_cv_with_aix_soname=$enable_aix_soname],
+    [_AC_ENABLE_IF([with], [aix-soname],
+        [case $withval in
+         aix|svr4|both)
+           ;;
+         *)
+           AC_MSG_ERROR([Unknown argument to --with-aix-soname])
+           ;;
+         esac
+         lt_cv_with_aix_soname=$with_aix_soname],
+        [AC_CACHE_VAL([lt_cv_with_aix_soname],
+           [lt_cv_with_aix_soname=]_LT_WITH_AIX_SONAME_DEFAULT)])
+     enable_aix_soname=$lt_cv_with_aix_soname])
+  with_aix_soname=$enable_aix_soname
   AC_MSG_RESULT([$with_aix_soname])
   if test aix != "$with_aix_soname"; then
     # For the AIX way of multilib, we name the shared archive member
@@ -376,30 +386,50 @@ LT_OPTION_DEFINE([LT_INIT], [aix-soname=svr4], [_LT_WITH_AIX_SONAME([svr4])])
 
 # _LT_WITH_PIC([MODE])
 # --------------------
-# implement the --with-pic flag, and support the 'pic-only' and 'no-pic'
+# implement the --enable-pic flag, and support the 'pic-only' and 'no-pic'
 # LT_INIT options.
 # MODE is either 'yes' or 'no'.  If omitted, it defaults to 'both'.
 m4_define([_LT_WITH_PIC],
-[AC_ARG_WITH([pic],
-    [AS_HELP_STRING([--with-pic@<:@=PKGS@:>@],
+[AC_ARG_ENABLE([pic],
+    [AS_HELP_STRING([--enable-pic@<:@=PKGS@:>@],
 	[try to use only PIC/non-PIC objects @<:@default=use both@:>@])],
     [lt_p=${PACKAGE-default}
-    case $withval in
-    yes|no) pic_mode=$withval ;;
-    *)
-      pic_mode=default
-      # Look at the argument we got.  We use all the common list separators.
-      lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR,
-      for lt_pkg in $withval; do
-	IFS=$lt_save_ifs
-	if test "X$lt_pkg" = "X$lt_p"; then
-	  pic_mode=yes
-	fi
-      done
-      IFS=$lt_save_ifs
-      ;;
-    esac],
-    [pic_mode=m4_default([$1], [default])])
+     case $enableval in
+     yes|no) pic_mode=$enableval ;;
+     *)
+       pic_mode=default
+       # Look at the argument we got.  We use all the common list separators.
+       lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR,
+       for lt_pkg in $enableval; do
+	 IFS=$lt_save_ifs
+	 if test "X$lt_pkg" = "X$lt_p"; then
+	   pic_mode=yes
+	 fi
+       done
+       IFS=$lt_save_ifs
+       ;;
+     esac],
+    [dnl Continue to support --with-pic and --without-pic, for backward
+     dnl compatibility.
+     _AC_ENABLE_IF([with], [pic],
+	[lt_p=${PACKAGE-default}
+	 case $withval in
+	 yes|no) pic_mode=$withval ;;
+	 *)
+	   pic_mode=default
+	   # Look at the argument we got.  We use all the common list separators.
+	   lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR,
+	   for lt_pkg in $withval; do
+	     IFS=$lt_save_ifs
+	     if test "X$lt_pkg" = "X$lt_p"; then
+	       pic_mode=yes
+	     fi
+	   done
+	   IFS=$lt_save_ifs
+	   ;;
+	 esac],
+	[pic_mode=m4_default([$1], [default])])]
+    )
 
 _LT_DECL([], [pic_mode], [0], [What type of objects to build])dnl
 ])# _LT_WITH_PIC

+ 1 - 1
m4/ltsugar.m4

@@ -1,6 +1,6 @@
 # ltsugar.m4 -- libtool m4 base layer.                         -*-Autoconf-*-
 #
-# Copyright (C) 2004-2005, 2007-2008, 2011-2015 Free Software
+# Copyright (C) 2004-2005, 2007-2008, 2011-2019, 2021-2024 Free Software
 # Foundation, Inc.
 # Written by Gary V. Vaughan, 2004
 #

+ 7 - 6
m4/ltversion.m4

@@ -1,6 +1,7 @@
 # ltversion.m4 -- version numbers			-*- Autoconf -*-
 #
-#   Copyright (C) 2004, 2011-2015 Free Software Foundation, Inc.
+#   Copyright (C) 2004, 2011-2019, 2021-2024 Free Software Foundation,
+#   Inc.
 #   Written by Scott James Remnant, 2004
 #
 # This file is free software; the Free Software Foundation gives
@@ -9,15 +10,15 @@
 
 # @configure_input@
 
-# serial 4179 ltversion.m4
+# serial 4441 ltversion.m4
 # This file is part of GNU Libtool
 
-m4_define([LT_PACKAGE_VERSION], [2.4.6])
-m4_define([LT_PACKAGE_REVISION], [2.4.6])
+m4_define([LT_PACKAGE_VERSION], [2.5.4])
+m4_define([LT_PACKAGE_REVISION], [2.5.4])
 
 AC_DEFUN([LTVERSION_VERSION],
-[macro_version='2.4.6'
-macro_revision='2.4.6'
+[macro_version='2.5.4'
+macro_revision='2.5.4'
 _LT_DECL(, macro_version, 0, [Which release of libtool.m4 was used?])
 _LT_DECL(, macro_revision, 0)
 ])

+ 2 - 2
m4/lt~obsolete.m4

@@ -1,7 +1,7 @@
 # lt~obsolete.m4 -- aclocal satisfying obsolete definitions.    -*-Autoconf-*-
 #
-#   Copyright (C) 2004-2005, 2007, 2009, 2011-2015 Free Software
-#   Foundation, Inc.
+#   Copyright (C) 2004-2005, 2007, 2009, 2011-2019, 2021-2024 Free
+#   Software Foundation, Inc.
 #   Written by Scott James Remnant, 2004.
 #
 # This file is free software; the Free Software Foundation gives

+ 21 - 6
scripts/Makefile.in

@@ -1,7 +1,7 @@
-# Makefile.in generated by automake 1.16.3 from Makefile.am.
+# Makefile.in generated by automake 1.17 from Makefile.am.
 # @configure_input@
 
-# Copyright (C) 1994-2020 Free Software Foundation, Inc.
+# Copyright (C) 1994-2024 Free Software Foundation, Inc.
 
 # This Makefile.in is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -69,6 +69,8 @@ am__make_running_with_option = \
   test $$has_opt = yes
 am__make_dryrun = (target_option=n; $(am__make_running_with_option))
 am__make_keepgoing = (target_option=k; $(am__make_running_with_option))
+am__rm_f = rm -f $(am__rm_f_notfound)
+am__rm_rf = rm -rf $(am__rm_f_notfound)
 pkgdatadir = $(datadir)/@PACKAGE@
 pkgincludedir = $(includedir)/@PACKAGE@
 pkglibdir = $(libdir)/@PACKAGE@
@@ -141,6 +143,8 @@ CPP = @CPP@
 CPPFLAGS = @CPPFLAGS@
 CROSS_ARCH = @CROSS_ARCH@
 CROSS_LD = @CROSS_LD@
+CSCOPE = @CSCOPE@
+CTAGS = @CTAGS@
 CUT = @CUT@
 CXX = @CXX@
 CXXCPP = @CXXCPP@
@@ -158,8 +162,10 @@ ECHO_C = @ECHO_C@
 ECHO_N = @ECHO_N@
 ECHO_T = @ECHO_T@
 EGREP = @EGREP@
+ETAGS = @ETAGS@
 EXEEXT = @EXEEXT@
 FGREP = @FGREP@
+FILECMD = @FILECMD@
 GREP = @GREP@
 GROFF = @GROFF@
 INSTALL = @INSTALL@
@@ -232,8 +238,10 @@ ac_ct_DUMPBIN = @ac_ct_DUMPBIN@
 am__include = @am__include@
 am__leading_dot = @am__leading_dot@
 am__quote = @am__quote@
+am__rm_f_notfound = @am__rm_f_notfound@
 am__tar = @am__tar@
 am__untar = @am__untar@
+am__xargs_n = @am__xargs_n@
 bindir = @bindir@
 build = @build@
 build_alias = @build_alias@
@@ -288,6 +296,7 @@ target_cpu = @target_cpu@
 target_os = @target_os@
 target_vendor = @target_vendor@
 tcpdump_path = @tcpdump_path@
+test_hexdump = @test_hexdump@
 timestamp_trace_flag = @timestamp_trace_flag@
 top_build_prefix = @top_build_prefix@
 top_builddir = @top_builddir@
@@ -338,7 +347,6 @@ ctags CTAGS:
 
 cscope cscopelist:
 
-
 distdir: $(BUILT_SOURCES)
 	$(MAKE) $(AM_MAKEFLAGS) distdir-am
 
@@ -400,13 +408,13 @@ mostlyclean-generic:
 clean-generic:
 
 distclean-generic:
-	-test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
-	-test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES)
+	-$(am__rm_f) $(CONFIG_CLEAN_FILES)
+	-test . = "$(srcdir)" || $(am__rm_f) $(CONFIG_CLEAN_VPATH_FILES)
 
 maintainer-clean-generic:
 	@echo "This command is intended for maintainers to use"
 	@echo "it deletes files that may require special tools to rebuild."
-	-test -z "$(MAINTAINERCLEANFILES)" || rm -f $(MAINTAINERCLEANFILES)
+	-$(am__rm_f) $(MAINTAINERCLEANFILES)
 clean: clean-am
 
 clean-am: clean-generic clean-libtool mostlyclean-am
@@ -493,3 +501,10 @@ uninstall-am:
 # Tell versions [3.59,3.63) of GNU make to not export all variables.
 # Otherwise a system limit (for SysV at least) may be exceeded.
 .NOEXPORT:
+
+# Tell GNU make to disable its built-in pattern rules.
+%:: %,v
+%:: RCS/%,v
+%:: RCS/%
+%:: s.%
+%:: SCCS/s.%

+ 1 - 1
src/Makefile.am

@@ -15,7 +15,7 @@ else
 LIBSTRL = ../lib/libstrl.a
 endif
 
-BUILT_SOURCES = 
+BUILT_SOURCES = defines.h
 
 manpages: tcpprep.1 tcprewrite.1 tcpreplay.1 tcpbridge.1 tcpreplay-edit.1 tcpliveplay.1 tcpcapinfo.1
 

+ 38 - 31
src/Makefile.in

@@ -1,7 +1,7 @@
-# Makefile.in generated by automake 1.16.3 from Makefile.am.
+# Makefile.in generated by automake 1.17 from Makefile.am.
 # @configure_input@
 
-# Copyright (C) 1994-2020 Free Software Foundation, Inc.
+# Copyright (C) 1994-2024 Free Software Foundation, Inc.
 
 # This Makefile.in is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -71,6 +71,8 @@ am__make_running_with_option = \
   test $$has_opt = yes
 am__make_dryrun = (target_option=n; $(am__make_running_with_option))
 am__make_keepgoing = (target_option=k; $(am__make_running_with_option))
+am__rm_f = rm -f $(am__rm_f_notfound)
+am__rm_rf = rm -rf $(am__rm_f_notfound)
 pkgdatadir = $(datadir)/@PACKAGE@
 pkgincludedir = $(includedir)/@PACKAGE@
 pkglibdir = $(libdir)/@PACKAGE@
@@ -295,10 +297,9 @@ am__base_list = \
   sed '$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;s/\n/ /g' | \
   sed '$$!N;$$!N;$$!N;$$!N;s/\n/ /g'
 am__uninstall_files_from_dir = { \
-  test -z "$$files" \
-    || { test ! -d "$$dir" && test ! -f "$$dir" && test ! -r "$$dir"; } \
-    || { echo " ( cd '$$dir' && rm -f" $$files ")"; \
-         $(am__cd) "$$dir" && rm -f $$files; }; \
+  { test ! -d "$$dir" && test ! -f "$$dir" && test ! -r "$$dir"; } \
+  || { echo " ( cd '$$dir' && rm -f" $$files ")"; \
+       $(am__cd) "$$dir" && echo $$files | $(am__xargs_n) 40 $(am__rm_f); }; \
   }
 man1dir = $(mandir)/man1
 NROFF = nroff
@@ -330,8 +331,6 @@ am__define_uniq_tagged_files = \
   unique=`for i in $$list; do \
     if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
   done | $(am__uniquify_input)`
-ETAGS = etags
-CTAGS = ctags
 DIST_SUBDIRS = common tcpedit fragroute
 am__DIST_COMMON = $(srcdir)/Makefile.in $(srcdir)/config.h.in \
 	$(srcdir)/defines.h.in $(top_srcdir)/config/depcomp
@@ -377,6 +376,8 @@ CPP = @CPP@
 CPPFLAGS = @CPPFLAGS@
 CROSS_ARCH = @CROSS_ARCH@
 CROSS_LD = @CROSS_LD@
+CSCOPE = @CSCOPE@
+CTAGS = @CTAGS@
 CUT = @CUT@
 CXX = @CXX@
 CXXCPP = @CXXCPP@
@@ -394,8 +395,10 @@ ECHO_C = @ECHO_C@
 ECHO_N = @ECHO_N@
 ECHO_T = @ECHO_T@
 EGREP = @EGREP@
+ETAGS = @ETAGS@
 EXEEXT = @EXEEXT@
 FGREP = @FGREP@
+FILECMD = @FILECMD@
 GREP = @GREP@
 GROFF = @GROFF@
 INSTALL = @INSTALL@
@@ -468,8 +471,10 @@ ac_ct_DUMPBIN = @ac_ct_DUMPBIN@
 am__include = @am__include@
 am__leading_dot = @am__leading_dot@
 am__quote = @am__quote@
+am__rm_f_notfound = @am__rm_f_notfound@
 am__tar = @am__tar@
 am__untar = @am__untar@
+am__xargs_n = @am__xargs_n@
 bindir = @bindir@
 build = @build@
 build_alias = @build_alias@
@@ -524,6 +529,7 @@ target_cpu = @target_cpu@
 target_os = @target_os@
 target_vendor = @target_vendor@
 tcpdump_path = @tcpdump_path@
+test_hexdump = @test_hexdump@
 timestamp_trace_flag = @timestamp_trace_flag@
 top_build_prefix = @top_build_prefix@
 top_builddir = @top_builddir@
@@ -537,7 +543,7 @@ top_srcdir = @top_srcdir@
 SUBDIRS = common tcpedit $(FRAGROUTE_DIR)
 @SYSTEM_STRLCPY_FALSE@LIBSTRL = ../lib/libstrl.a
 @SYSTEM_STRLCPY_TRUE@LIBSTRL = 
-BUILT_SOURCES = tcpreplay_edit_opts.h tcpreplay_opts.h \
+BUILT_SOURCES = defines.h tcpreplay_edit_opts.h tcpreplay_opts.h \
 	tcpliveplay_opts.h tcprewrite_opts.h tcpcapinfo_opts.h \
 	tcpprep_opts.h tcpbridge_opts.h
 
@@ -637,12 +643,12 @@ config.h: stamp-h1
 	@test -f $@ || $(MAKE) $(AM_MAKEFLAGS) stamp-h1
 
 stamp-h1: $(srcdir)/config.h.in $(top_builddir)/config.status
-	@rm -f stamp-h1
-	cd $(top_builddir) && $(SHELL) ./config.status src/config.h
+	$(AM_V_at)rm -f stamp-h1
+	$(AM_V_GEN)cd $(top_builddir) && $(SHELL) ./config.status src/config.h
 $(srcdir)/config.h.in: @MAINTAINER_MODE_TRUE@ $(am__configure_deps) 
-	($(am__cd) $(top_srcdir) && $(AUTOHEADER))
-	rm -f stamp-h1
-	touch $@
+	$(AM_V_GEN)($(am__cd) $(top_srcdir) && $(AUTOHEADER))
+	$(AM_V_at)rm -f stamp-h1
+	$(AM_V_at)touch $@
 
 distclean-hdr:
 	-rm -f config.h stamp-h1
@@ -687,16 +693,11 @@ uninstall-binPROGRAMS:
 	`; \
 	test -n "$$list" || exit 0; \
 	echo " ( cd '$(DESTDIR)$(bindir)' && rm -f" $$files ")"; \
-	cd "$(DESTDIR)$(bindir)" && rm -f $$files
+	cd "$(DESTDIR)$(bindir)" && $(am__rm_f) $$files
 
 clean-binPROGRAMS:
-	@list='$(bin_PROGRAMS)'; test -n "$$list" || exit 0; \
-	echo " rm -f" $$list; \
-	rm -f $$list || exit $$?; \
-	test -n "$(EXEEXT)" || exit 0; \
-	list=`for p in $$list; do echo "$$p"; done | sed 's/$(EXEEXT)$$//'`; \
-	echo " rm -f" $$list; \
-	rm -f $$list
+	$(am__rm_f) $(bin_PROGRAMS)
+	test -z "$(EXEEXT)" || $(am__rm_f) $(bin_PROGRAMS:$(EXEEXT)=)
 
 tcpbridge$(EXEEXT): $(tcpbridge_OBJECTS) $(tcpbridge_DEPENDENCIES) $(EXTRA_tcpbridge_DEPENDENCIES) 
 	@rm -f tcpbridge$(EXEEXT)
@@ -762,7 +763,7 @@ distclean-compile:
 
 $(am__depfiles_remade):
 	@$(MKDIR_P) $(@D)
-	@echo '# dummy' >$@-t && $(am__mv) $@-t $@
+	@: >>$@
 
 am--depfiles: $(am__depfiles_remade)
 
@@ -1315,7 +1316,6 @@ cscopelist-am: $(am__tagged_files)
 
 distclean-tags:
 	-rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
-
 distdir: $(BUILT_SOURCES)
 	$(MAKE) $(AM_MAKEFLAGS) distdir-am
 
@@ -1405,25 +1405,25 @@ install-strip:
 	    "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \
 	fi
 mostlyclean-generic:
-	-test -z "$(MOSTLYCLEANFILES)" || rm -f $(MOSTLYCLEANFILES)
+	-$(am__rm_f) $(MOSTLYCLEANFILES)
 
 clean-generic:
 
 distclean-generic:
-	-test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
-	-test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES)
+	-$(am__rm_f) $(CONFIG_CLEAN_FILES)
+	-test . = "$(srcdir)" || $(am__rm_f) $(CONFIG_CLEAN_VPATH_FILES)
 
 maintainer-clean-generic:
 	@echo "This command is intended for maintainers to use"
 	@echo "it deletes files that may require special tools to rebuild."
-	-test -z "$(BUILT_SOURCES)" || rm -f $(BUILT_SOURCES)
-	-test -z "$(MAINTAINERCLEANFILES)" || rm -f $(MAINTAINERCLEANFILES)
+	-$(am__rm_f) $(BUILT_SOURCES)
+	-$(am__rm_f) $(MAINTAINERCLEANFILES)
 clean: clean-recursive
 
 clean-am: clean-binPROGRAMS clean-generic clean-libtool mostlyclean-am
 
 distclean: distclean-recursive
-		-rm -f ./$(DEPDIR)/tcpbridge-bridge.Po
+	-rm -f ./$(DEPDIR)/tcpbridge-bridge.Po
 	-rm -f ./$(DEPDIR)/tcpbridge-tcpbridge.Po
 	-rm -f ./$(DEPDIR)/tcpbridge-tcpbridge_opts.Po
 	-rm -f ./$(DEPDIR)/tcpcapinfo-tcpcapinfo.Po
@@ -1495,7 +1495,7 @@ install-ps-am:
 installcheck-am:
 
 maintainer-clean: maintainer-clean-recursive
-		-rm -f ./$(DEPDIR)/tcpbridge-bridge.Po
+	-rm -f ./$(DEPDIR)/tcpbridge-bridge.Po
 	-rm -f ./$(DEPDIR)/tcpbridge-tcpbridge.Po
 	-rm -f ./$(DEPDIR)/tcpbridge-tcpbridge_opts.Po
 	-rm -f ./$(DEPDIR)/tcpcapinfo-tcpcapinfo.Po
@@ -1622,3 +1622,10 @@ tcpbridge_opts.c: tcpbridge_opts.def tcpedit/tcpedit_opts.def
 # Tell versions [3.59,3.63) of GNU make to not export all variables.
 # Otherwise a system limit (for SysV at least) may be exceeded.
 .NOEXPORT:
+
+# Tell GNU make to disable its built-in pattern rules.
+%:: %,v
+%:: RCS/%,v
+%:: RCS/%
+%:: s.%
+%:: SCCS/s.%

+ 1 - 1
src/bridge.c

@@ -2,7 +2,7 @@
 
 /*
  *   Copyright (c) 2001-2010 Aaron Turner <aturner at synfin dot net>
- *   Copyright (c) 2013-2024 Fred Klassen <tcpreplay at appneta dot com> - AppNeta
+ *   Copyright (c) 2013-2025 Fred Klassen <tcpreplay at appneta dot com> - AppNeta
  *
  *   The Tcpreplay Suite of tools is free software: you can redistribute it
  *   and/or modify it under the terms of the GNU General Public License as

+ 1 - 1
src/bridge.h

@@ -2,7 +2,7 @@
 
 /*
  *   Copyright (c) 2001-2010 Aaron Turner <aturner at synfin dot net>
- *   Copyright (c) 2013-2024 Fred Klassen <tcpreplay at appneta dot com> - AppNeta
+ *   Copyright (c) 2013-2025 Fred Klassen <tcpreplay at appneta dot com> - AppNeta
  *
  *   The Tcpreplay Suite of tools is free software: you can redistribute it
  *   and/or modify it under the terms of the GNU General Public License as

+ 1 - 1
src/common.h

@@ -2,7 +2,7 @@
 
 /*
  *   Copyright (c) 2001-2010 Aaron Turner <aturner at synfin dot net>
- *   Copyright (c) 2013-2024 Fred Klassen <tcpreplay at appneta dot com> - AppNeta
+ *   Copyright (c) 2013-2025 Fred Klassen <tcpreplay at appneta dot com> - AppNeta
  *
  *   The Tcpreplay Suite of tools is free software: you can redistribute it
  *   and/or modify it under the terms of the GNU General Public License as

+ 30 - 16
src/common/Makefile.in

@@ -1,7 +1,7 @@
-# Makefile.in generated by automake 1.16.3 from Makefile.am.
+# Makefile.in generated by automake 1.17 from Makefile.am.
 # @configure_input@
 
-# Copyright (C) 1994-2020 Free Software Foundation, Inc.
+# Copyright (C) 1994-2024 Free Software Foundation, Inc.
 
 # This Makefile.in is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -71,6 +71,8 @@ am__make_running_with_option = \
   test $$has_opt = yes
 am__make_dryrun = (target_option=n; $(am__make_running_with_option))
 am__make_keepgoing = (target_option=k; $(am__make_running_with_option))
+am__rm_f = rm -f $(am__rm_f_notfound)
+am__rm_rf = rm -rf $(am__rm_f_notfound)
 pkgdatadir = $(datadir)/@PACKAGE@
 pkgincludedir = $(includedir)/@PACKAGE@
 pkglibdir = $(libdir)/@PACKAGE@
@@ -109,12 +111,13 @@ CONFIG_HEADER = $(top_builddir)/src/config.h
 CONFIG_CLEAN_FILES =
 CONFIG_CLEAN_VPATH_FILES =
 LIBRARIES = $(noinst_LIBRARIES)
-ARFLAGS = cru
+ARFLAGS = cr
 AM_V_AR = $(am__v_AR_@AM_V@)
 am__v_AR_ = $(am__v_AR_@AM_DEFAULT_V@)
 am__v_AR_0 = @echo "  AR      " $@;
 am__v_AR_1 = 
 libcommon_a_AR = $(AR) $(ARFLAGS)
+libcommon_a_RANLIB = $(RANLIB)
 @SYSTEM_STRLCPY_FALSE@libcommon_a_DEPENDENCIES = ../../lib/libstrl.a
 am__libcommon_a_SOURCES_DIST = cidr.c err.c list.c cache.c services.c \
 	get.c fakepcap.c fakepcapnav.c fakepoll.c xX.c utils.c timer.c \
@@ -203,8 +206,6 @@ am__define_uniq_tagged_files = \
   unique=`for i in $$list; do \
     if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
   done | $(am__uniquify_input)`
-ETAGS = etags
-CTAGS = ctags
 am__DIST_COMMON = $(srcdir)/Makefile.in $(top_srcdir)/config/depcomp
 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
 ACLOCAL = @ACLOCAL@
@@ -223,6 +224,8 @@ CPP = @CPP@
 CPPFLAGS = @CPPFLAGS@
 CROSS_ARCH = @CROSS_ARCH@
 CROSS_LD = @CROSS_LD@
+CSCOPE = @CSCOPE@
+CTAGS = @CTAGS@
 CUT = @CUT@
 CXX = @CXX@
 CXXCPP = @CXXCPP@
@@ -240,8 +243,10 @@ ECHO_C = @ECHO_C@
 ECHO_N = @ECHO_N@
 ECHO_T = @ECHO_T@
 EGREP = @EGREP@
+ETAGS = @ETAGS@
 EXEEXT = @EXEEXT@
 FGREP = @FGREP@
+FILECMD = @FILECMD@
 GREP = @GREP@
 GROFF = @GROFF@
 INSTALL = @INSTALL@
@@ -314,8 +319,10 @@ ac_ct_DUMPBIN = @ac_ct_DUMPBIN@
 am__include = @am__include@
 am__leading_dot = @am__leading_dot@
 am__quote = @am__quote@
+am__rm_f_notfound = @am__rm_f_notfound@
 am__tar = @am__tar@
 am__untar = @am__untar@
+am__xargs_n = @am__xargs_n@
 bindir = @bindir@
 build = @build@
 build_alias = @build_alias@
@@ -370,6 +377,7 @@ target_cpu = @target_cpu@
 target_os = @target_os@
 target_vendor = @target_vendor@
 tcpdump_path = @tcpdump_path@
+test_hexdump = @test_hexdump@
 timestamp_trace_flag = @timestamp_trace_flag@
 top_build_prefix = @top_build_prefix@
 top_builddir = @top_builddir@
@@ -428,12 +436,12 @@ $(ACLOCAL_M4): @MAINTAINER_MODE_TRUE@ $(am__aclocal_m4_deps)
 $(am__aclocal_m4_deps):
 
 clean-noinstLIBRARIES:
-	-test -z "$(noinst_LIBRARIES)" || rm -f $(noinst_LIBRARIES)
+	-$(am__rm_f) $(noinst_LIBRARIES)
 
 libcommon.a: $(libcommon_a_OBJECTS) $(libcommon_a_DEPENDENCIES) $(EXTRA_libcommon_a_DEPENDENCIES) 
 	$(AM_V_at)-rm -f libcommon.a
 	$(AM_V_AR)$(libcommon_a_AR) libcommon.a $(libcommon_a_OBJECTS) $(libcommon_a_LIBADD)
-	$(AM_V_at)$(RANLIB) libcommon.a
+	$(AM_V_at)$(libcommon_a_RANLIB) libcommon.a
 
 mostlyclean-compile:
 	-rm -f *.$(OBJEXT)
@@ -465,7 +473,7 @@ distclean-compile:
 
 $(am__depfiles_remade):
 	@$(MKDIR_P) $(@D)
-	@echo '# dummy' >$@-t && $(am__mv) $@-t $@
+	@: >>$@
 
 am--depfiles: $(am__depfiles_remade)
 
@@ -550,7 +558,6 @@ cscopelist-am: $(am__tagged_files)
 
 distclean-tags:
 	-rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
-
 distdir: $(BUILT_SOURCES)
 	$(MAKE) $(AM_MAKEFLAGS) distdir-am
 
@@ -611,26 +618,26 @@ install-strip:
 	    "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \
 	fi
 mostlyclean-generic:
-	-test -z "$(MOSTLYCLEANFILES)" || rm -f $(MOSTLYCLEANFILES)
+	-$(am__rm_f) $(MOSTLYCLEANFILES)
 
 clean-generic:
 
 distclean-generic:
-	-test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
-	-test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES)
+	-$(am__rm_f) $(CONFIG_CLEAN_FILES)
+	-test . = "$(srcdir)" || $(am__rm_f) $(CONFIG_CLEAN_VPATH_FILES)
 
 maintainer-clean-generic:
 	@echo "This command is intended for maintainers to use"
 	@echo "it deletes files that may require special tools to rebuild."
-	-test -z "$(BUILT_SOURCES)" || rm -f $(BUILT_SOURCES)
-	-test -z "$(MAINTAINERCLEANFILES)" || rm -f $(MAINTAINERCLEANFILES)
+	-$(am__rm_f) $(BUILT_SOURCES)
+	-$(am__rm_f) $(MAINTAINERCLEANFILES)
 clean: clean-am
 
 clean-am: clean-generic clean-libtool clean-noinstLIBRARIES \
 	mostlyclean-am
 
 distclean: distclean-am
-		-rm -f ./$(DEPDIR)/cache.Po
+	-rm -f ./$(DEPDIR)/cache.Po
 	-rm -f ./$(DEPDIR)/cidr.Po
 	-rm -f ./$(DEPDIR)/dlt_names.Po
 	-rm -f ./$(DEPDIR)/err.Po
@@ -696,7 +703,7 @@ install-ps-am:
 installcheck-am:
 
 maintainer-clean: maintainer-clean-am
-		-rm -f ./$(DEPDIR)/cache.Po
+	-rm -f ./$(DEPDIR)/cache.Po
 	-rm -f ./$(DEPDIR)/cidr.Po
 	-rm -f ./$(DEPDIR)/dlt_names.Po
 	-rm -f ./$(DEPDIR)/err.Po
@@ -765,3 +772,10 @@ git_version.c:
 # Tell versions [3.59,3.63) of GNU make to not export all variables.
 # Otherwise a system limit (for SysV at least) may be exceeded.
 .NOEXPORT:
+
+# Tell GNU make to disable its built-in pattern rules.
+%:: %,v
+%:: RCS/%,v
+%:: RCS/%
+%:: s.%
+%:: SCCS/s.%

+ 1 - 1
src/common/cache.c

@@ -2,7 +2,7 @@
 
 /*
  *   Copyright (c) 2001-2010 Aaron Turner <aturner at synfin dot net>
- *   Copyright (c) 2013-2024 Fred Klassen <tcpreplay at appneta dot com> - AppNeta
+ *   Copyright (c) 2013-2025 Fred Klassen <tcpreplay at appneta dot com> - AppNeta
  *
  *   The Tcpreplay Suite of tools is free software: you can redistribute it
  *   and/or modify it under the terms of the GNU General Public License as

+ 1 - 1
src/common/cache.h

@@ -2,7 +2,7 @@
 
 /*
  *   Copyright (c) 2001-2010 Aaron Turner <aturner at synfin dot net>
- *   Copyright (c) 2013-2024 Fred Klassen <tcpreplay at appneta dot com> - AppNeta
+ *   Copyright (c) 2013-2025 Fred Klassen <tcpreplay at appneta dot com> - AppNeta
  *
  *   The Tcpreplay Suite of tools is free software: you can redistribute it 
  *   and/or modify it under the terms of the GNU General Public License as 

+ 1 - 2
src/common/cidr.c

@@ -2,7 +2,7 @@
 
 /*
  *   Copyright (c) 2001-2010 Aaron Turner <aturner at synfin dot net>
- *   Copyright (c) 2013-2024 Fred Klassen <tcpreplay at appneta dot com> - AppNeta
+ *   Copyright (c) 2013-2025 Fred Klassen <tcpreplay at appneta dot com> - AppNeta
  *
  *   The Tcpreplay Suite of tools is free software: you can redistribute it
  *   and/or modify it under the terms of the GNU General Public License as
@@ -21,7 +21,6 @@
 #include "defines.h"
 #include "config.h"
 #include "common.h"
-#include <arpa/inet.h>
 #include <netinet/in.h>
 #include <stdio.h>
 #include <stdlib.h>

+ 1 - 1
src/common/cidr.h

@@ -2,7 +2,7 @@
 
 /*
  *   Copyright (c) 2001-2010 Aaron Turner <aturner at synfin dot net>
- *   Copyright (c) 2013-2024 Fred Klassen <tcpreplay at appneta dot com> - AppNeta
+ *   Copyright (c) 2013-2025 Fred Klassen <tcpreplay at appneta dot com> - AppNeta
  *
  *   The Tcpreplay Suite of tools is free software: you can redistribute it
  *   and/or modify it under the terms of the GNU General Public License as

+ 1 - 1
src/common/err.c

@@ -7,7 +7,7 @@
  *
  * Copyright (c) 2001-2010 Aaron Turner.
  *
- * Copyright (c) 2013-2024 Fred Klassen - AppNeta
+ * Copyright (c) 2013-2025 Fred Klassen - AppNeta
  *
  * Copyright (c) 2000 Dug Song <dugsong@monkey.org>
  *

+ 1 - 1
src/common/err.h

@@ -7,7 +7,7 @@
  *
  * Copyright (c) 2001-2010 Aaron Turner.
  *
- * Copyright (c) 2013-2024 Fred Klassen - AppNeta
+ * Copyright (c) 2013-2025 Fred Klassen - AppNeta
  *
  * Copyright (c) 2000 Dug Song <dugsong@monkey.org>
  *

+ 1 - 1
src/common/fakepcap.c

@@ -2,7 +2,7 @@
 
 /*
  *   Copyright (c) 2001-2010 Aaron Turner <aturner at synfin dot net>
- *   Copyright (c) 2013-2024 Fred Klassen <tcpreplay at appneta dot com> - AppNeta
+ *   Copyright (c) 2013-2025 Fred Klassen <tcpreplay at appneta dot com> - AppNeta
  *
  *   The Tcpreplay Suite of tools is free software: you can redistribute it
  *   and/or modify it under the terms of the GNU General Public License as

+ 1 - 1
src/common/fakepcap.h

@@ -2,7 +2,7 @@
 
 /*
  *   Copyright (c) 2001-2010 Aaron Turner <aturner at synfin dot net>
- *   Copyright (c) 2013-2024 Fred Klassen <tcpreplay at appneta dot com> - AppNeta
+ *   Copyright (c) 2013-2025 Fred Klassen <tcpreplay at appneta dot com> - AppNeta
  *
  *   The Tcpreplay Suite of tools is free software: you can redistribute it 
  *   and/or modify it under the terms of the GNU General Public License as 

+ 1 - 1
src/common/fakepcapnav.c

@@ -2,7 +2,7 @@
 
 /*
  *   Copyright (c) 2001-2010 Aaron Turner <aturner at synfin dot net>
- *   Copyright (c) 2013-2024 Fred Klassen <tcpreplay at appneta dot com> - AppNeta
+ *   Copyright (c) 2013-2025 Fred Klassen <tcpreplay at appneta dot com> - AppNeta
  *
  *   The Tcpreplay Suite of tools is free software: you can redistribute it
  *   and/or modify it under the terms of the GNU General Public License as

+ 1 - 1
src/common/fakepcapnav.h

@@ -2,7 +2,7 @@
 
 /*
  *   Copyright (c) 2001-2010 Aaron Turner <aturner at synfin dot net>
- *   Copyright (c) 2013-2024 Fred Klassen <tcpreplay at appneta dot com> - AppNeta
+ *   Copyright (c) 2013-2025 Fred Klassen <tcpreplay at appneta dot com> - AppNeta
  *
  *   The Tcpreplay Suite of tools is free software: you can redistribute it
  *   and/or modify it under the terms of the GNU General Public License as

+ 2 - 2
src/common/flows.c

@@ -1,6 +1,6 @@
 /*
  *   Copyright (c) 2001-2010 Aaron Turner <aturner at synfin dot net>
- *   Copyright (c) 2013-2024 Fred Klassen <tcpreplay at appneta dot com> - AppNeta
+ *   Copyright (c) 2013-2025 Fred Klassen <tcpreplay at appneta dot com> - AppNeta
  *
  *   The Tcpreplay Suite of tools is free software: you can redistribute it 
  *   and/or modify it under the terms of the GNU General Public License as 
@@ -239,7 +239,7 @@ flow_decode(flow_hash_table_t *fht,
             return FLOW_ENTRY_INVALID;
         }
 
-        uint8_t ip6_version = packet[0] >> 4;
+        uint8_t ip6_version = packet[l2len] >> 4;
         if (ip6_version != 6) {
             warnx("flow_decode: packet " COUNTER_SPEC " IPv6 header version should be 6 but instead is %u",
                   packetnum,

+ 1 - 1
src/common/flows.h

@@ -1,6 +1,6 @@
 /*
  *   Copyright (c) 2001-2010 Aaron Turner <aturner at synfin dot net>
- *   Copyright (c) 2013-2024 Fred Klassen <tcpreplay at appneta dot com> - AppNeta
+ *   Copyright (c) 2013-2025 Fred Klassen <tcpreplay at appneta dot com> - AppNeta
  *
  *   The Tcpreplay Suite of tools is free software: you can redistribute it
  *   and/or modify it under the terms of the GNU General Public License as

+ 5 - 3
src/common/get.c

@@ -2,7 +2,7 @@
 
 /*
  *   Copyright (c) 2001-2010 Aaron Turner <aturner at synfin dot net>
- *   Copyright (c) 2013-2024 Fred Klassen <tcpreplay at appneta dot com> - AppNeta
+ *   Copyright (c) 2013-2025 Fred Klassen <tcpreplay at appneta dot com> - AppNeta
  *
  *   The Tcpreplay Suite of tools is free software: you can redistribute it
  *   and/or modify it under the terms of the GNU General Public License as
@@ -273,8 +273,10 @@ get_l2len_protocol(const u_char *pktdata,
     assert(l2offset);
     assert(vlan_offset);
 
-    if (!pktdata || !datalen)
-        errx(-1, "get_l2len_protocol: invalid L2 parameters: pktdata=0x%p len=%d", pktdata, datalen);
+    if (!pktdata || !datalen) {
+        err_no_exitx("get_l2len_protocol: invalid L2 parameters: pktdata=0x%p len=%d", pktdata, datalen);
+        return -1;
+    }
 
     *protocol = 0;
     *l2len = 0;

+ 1 - 1
src/common/get.h

@@ -2,7 +2,7 @@
 
 /*
  *   Copyright (c) 2001-2010 Aaron Turner <aturner at synfin dot net>
- *   Copyright (c) 2013-2024 Fred Klassen <tcpreplay at appneta dot com> - AppNeta
+ *   Copyright (c) 2013-2025 Fred Klassen <tcpreplay at appneta dot com> - AppNeta
  *
  *   The Tcpreplay Suite of tools is free software: you can redistribute it 
  *   and/or modify it under the terms of the GNU General Public License as 

+ 1 - 1
src/common/git_version.c

@@ -1,4 +1,4 @@
-const char GIT_Version[] = "git:v4.5.1";
+const char GIT_Version[] = "git:v4.5.2";
 const char *git_version(void) {
     return GIT_Version;
 }

+ 1 - 1
src/common/interface.c

@@ -2,7 +2,7 @@
 
 /*
  *   Copyright (c) 2001-2010 Aaron Turner <aturner at synfin dot net>
- *   Copyright (c) 2013-2024 Fred Klassen <tcpreplay at appneta dot com> - AppNeta
+ *   Copyright (c) 2013-2025 Fred Klassen <tcpreplay at appneta dot com> - AppNeta
  *
  *   The Tcpreplay Suite of tools is free software: you can redistribute it
  *   and/or modify it under the terms of the GNU General Public License as

+ 1 - 1
src/common/interface.h

@@ -2,7 +2,7 @@
 
 /*
  *   Copyright (c) 2001-2010 Aaron Turner <aturner at synfin dot net>
- *   Copyright (c) 2013-2024 Fred Klassen <tcpreplay at appneta dot com> - AppNeta
+ *   Copyright (c) 2013-2025 Fred Klassen <tcpreplay at appneta dot com> - AppNeta
  *
  *   The Tcpreplay Suite of tools is free software: you can redistribute it
  *   and/or modify it under the terms of the GNU General Public License as

+ 1 - 1
src/common/list.c

@@ -1,6 +1,6 @@
 /*
  *   Copyright (c) 2001-2010 Aaron Turner <aturner at synfin dot net>
- *   Copyright (c) 2013-2024 Fred Klassen <tcpreplay at appneta dot com> - AppNeta
+ *   Copyright (c) 2013-2025 Fred Klassen <tcpreplay at appneta dot com> - AppNeta
  *
  *   The Tcpreplay Suite of tools is free software: you can redistribute it
  *   and/or modify it under the terms of the GNU General Public License as

+ 1 - 1
src/common/list.h

@@ -2,7 +2,7 @@
 
 /*
  *   Copyright (c) 2001-2010 Aaron Turner <aturner at synfin dot net>
- *   Copyright (c) 2013-2024 Fred Klassen <tcpreplay at appneta dot com> - AppNeta
+ *   Copyright (c) 2013-2025 Fred Klassen <tcpreplay at appneta dot com> - AppNeta
  *
  *   The Tcpreplay Suite of tools is free software: you can redistribute it
  *   and/or modify it under the terms of the GNU General Public License as

+ 1 - 1
src/common/mac.c

@@ -2,7 +2,7 @@
 
 /*
  *   Copyright (c) 2001-2010 Aaron Turner <aturner at synfin dot net>
- *   Copyright (c) 2013-2024 Fred Klassen <tcpreplay at appneta dot com> - AppNeta
+ *   Copyright (c) 2013-2025 Fred Klassen <tcpreplay at appneta dot com> - AppNeta
  *
  *   The Tcpreplay Suite of tools is free software: you can redistribute it
  *   and/or modify it under the terms of the GNU General Public License as

+ 1 - 1
src/common/mac.h

@@ -2,7 +2,7 @@
 
 /*
  *   Copyright (c) 2001-2010 Aaron Turner <aturner at synfin dot net>
- *   Copyright (c) 2013-2024 Fred Klassen <tcpreplay at appneta dot com> - AppNeta
+ *   Copyright (c) 2013-2025 Fred Klassen <tcpreplay at appneta dot com> - AppNeta
  *
  *   The Tcpreplay Suite of tools is free software: you can redistribute it 
  *   and/or modify it under the terms of the GNU General Public License as 

+ 1 - 1
src/common/pcap_dlt.h

@@ -2,7 +2,7 @@
 
 /*
  *   Copyright (c) 2001-2010 Aaron Turner <aturner at synfin dot net>
- *   Copyright (c) 2013-2024 Fred Klassen <tcpreplay at appneta dot com> - AppNeta
+ *   Copyright (c) 2013-2025 Fred Klassen <tcpreplay at appneta dot com> - AppNeta
  *
  *   The Tcpreplay Suite of tools is free software: you can redistribute it
  *   and/or modify it under the terms of the GNU General Public License as

+ 7 - 2
src/common/sendpacket.c

@@ -705,7 +705,10 @@ sendpacket_close(sendpacket_t *sp)
     case SP_TYPE_LIBXDP:
 #ifdef HAVE_LIBXDP
         close(sp->handle.fd);
+        xsk_socket__delete(sp->xsk_info->xsk);
         safe_free(sp->xsk_info);
+        xsk_umem__delete(sp->umem_info->umem);
+        safe_free(sp->umem_info->buffer);
         safe_free(sp->umem_info);
 #endif
         break;
@@ -1440,6 +1443,8 @@ sendpacket_open_xsk(const char *device, char *errbuf)
     struct xsk_socket_info *xsk_info =
             create_xsk_socket(umem_info, nb_of_tx_queue_desc, nb_of_rx_queue_desc, device, queue_id, errbuf);
     if (xsk_info == NULL) {
+        safe_free(umem_info->buffer);
+        safe_free(umem_info);
         return NULL;
     }
 
@@ -1497,7 +1502,7 @@ create_xsk_socket(struct xsk_umem_info *umem_info,
                   u_int32_t queue_id,
                   char *errbuf)
 {
-    struct xsk_socket_info *xsk_info = (struct xsk_socket_info *)safe_malloc(sizeof(struct xsk_socket_info));
+    struct xsk_socket_info *xsk_info;
     struct xsk_socket_config *socket_config = (struct xsk_socket_config *)safe_malloc(sizeof(struct xsk_socket_config));
 
     socket_config->rx_size = nb_of_rx_queue_desc;
@@ -1505,7 +1510,7 @@ create_xsk_socket(struct xsk_umem_info *umem_info,
     socket_config->libbpf_flags = XSK_LIBBPF_FLAGS__INHIBIT_PROG_LOAD;
     socket_config->bind_flags = 0; // XDP_FLAGS_SKB_MODE (1U << 1) or XDP_FLAGS_DRV_MODE (1U << 2)
     xsk_info = xsk_configure_socket(umem_info, socket_config, queue_id, device);
-
+    safe_free(socket_config);
     if (xsk_info == NULL) {
         snprintf(errbuf, SENDPACKET_ERRBUF_SIZE, "AF_XDP socket configuration is not successful: %s", strerror(errno));
         return NULL;

+ 10 - 3
src/common/sendpacket.h

@@ -2,7 +2,7 @@
 
 /*
  *   Copyright (c) 2001-2010 Aaron Turner <aturner at synfin dot net>
- *   Copyright (c) 2013-2024 Fred Klassen <tcpreplay at appneta dot com> - AppNeta
+ *   Copyright (c) 2013-2025 Fred Klassen <tcpreplay at appneta dot com> - AppNeta
  *
  *   The Tcpreplay Suite of tools is free software: you can redistribute it
  *   and/or modify it under the terms of the GNU General Public License as
@@ -27,6 +27,7 @@
 #ifdef __NetBSD__
 #include <net/if_ether.h>
 #elif ! defined(__HAIKU__)
+#include <net/if.h>
 #include <netinet/if_ether.h>
 #endif
 
@@ -249,8 +250,14 @@ kick_tx(struct xsk_socket_info *xsk)
     if (ret >= 0 || errno == ENOBUFS || errno == EAGAIN || errno == EBUSY || errno == ENETDOWN) {
         return;
     }
-    printf("%s\n", "Packet sending exited with error!");
-    exit (1);
+    if (errno == EINVAL) {
+        printf("%s\n", "Send error: XDP is either not supported by this underlying network driver, or it has a bug.\n"
+                          "Try upgrading to a newer kernel version and/or network driver and try again.");
+        exit(0);
+    } else {
+        printf("%s %s\n", "XDP packet sending exited with error!", strerror(errno));
+        exit(1);
+    }
 }
 
 static inline void

+ 1 - 1
src/common/services.c

@@ -2,7 +2,7 @@
 
 /*
  *   Copyright (c) 2001-2010 Aaron Turner <aturner at synfin dot net>
- *   Copyright (c) 2013-2024 Fred Klassen <tcpreplay at appneta dot com> - AppNeta
+ *   Copyright (c) 2013-2025 Fred Klassen <tcpreplay at appneta dot com> - AppNeta
  *
  *   The Tcpreplay Suite of tools is free software: you can redistribute it 
  *   and/or modify it under the terms of the GNU General Public License as 

+ 1 - 1
src/common/services.h

@@ -2,7 +2,7 @@
 
 /*
  *   Copyright (c) 2001-2010 Aaron Turner <aturner at synfin dot net>
- *   Copyright (c) 2013-2024 Fred Klassen <tcpreplay at appneta dot com> - AppNeta
+ *   Copyright (c) 2013-2025 Fred Klassen <tcpreplay at appneta dot com> - AppNeta
  *
  *   The Tcpreplay Suite of tools is free software: you can redistribute it
  *   and/or modify it under the terms of the GNU General Public License as

+ 1 - 1
src/common/tcpdump.c

@@ -2,7 +2,7 @@
 
 /*
  *   Copyright (c) 2001-2010 Aaron Turner <aturner at synfin dot net>
- *   Copyright (c) 2013-2024 Fred Klassen <tcpreplay at appneta dot com> - AppNeta
+ *   Copyright (c) 2013-2025 Fred Klassen <tcpreplay at appneta dot com> - AppNeta
  *
  *   The Tcpreplay Suite of tools is free software: you can redistribute it
  *   and/or modify it under the terms of the GNU General Public License as

+ 1 - 1
src/common/tcpdump.h

@@ -2,7 +2,7 @@
 
 /*
  *   Copyright (c) 2001-2010 Aaron Turner <aturner at synfin dot net>
- *   Copyright (c) 2013-2024 Fred Klassen <tcpreplay at appneta dot com> - AppNeta
+ *   Copyright (c) 2013-2025 Fred Klassen <tcpreplay at appneta dot com> - AppNeta
  *
  *   The Tcpreplay Suite of tools is free software: you can redistribute it
  *   and/or modify it under the terms of the GNU General Public License as

+ 1 - 1
src/common/timer.c

@@ -2,7 +2,7 @@
 
 /*
  *   Copyright (c) 2001-2010 Aaron Turner <aturner at synfin dot net>
- *   Copyright (c) 2013-2024 Fred Klassen <tcpreplay at appneta dot com> - AppNeta
+ *   Copyright (c) 2013-2025 Fred Klassen <tcpreplay at appneta dot com> - AppNeta
  *
  *   The Tcpreplay Suite of tools is free software: you can redistribute it
  *   and/or modify it under the terms of the GNU General Public License as

+ 1 - 1
src/common/timer.h

@@ -2,7 +2,7 @@
 
 /*
  *   Copyright (c) 2001-2010 Aaron Turner <aturner at synfin dot net>
- *   Copyright (c) 2013-2024 Fred Klassen <tcpreplay at appneta dot com> - AppNeta
+ *   Copyright (c) 2013-2025 Fred Klassen <tcpreplay at appneta dot com> - AppNeta
  *
  *   The Tcpreplay Suite of tools is free software: you can redistribute it
  *   and/or modify it under the terms of the GNU General Public License as

+ 5 - 2
src/common/txring.c

@@ -31,6 +31,9 @@
  * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  */
 
+#include "defines.h"
+#include "config.h"
+
 #ifdef HAVE_TX_RING
 
 #include "txring.h"
@@ -92,7 +95,7 @@ txring_put(txring_t *txp, const void *data, size_t length)
 
         switch ((volatile uint32_t)ps_header->tp_status) {
         case TP_STATUS_WRONG_FORMAT:
-            warnx("TP_STATUS_WRONG_FORMAT occuries O_o. Frame %d, pkt len %d\n", txp->tx_index, length);
+            warnx("TP_STATUS_WRONG_FORMAT occures O_o. Frame %d, pkt len %d\n", txp->tx_index, length);
             break;
 
         case TP_STATUS_AVAILABLE:
@@ -194,7 +197,7 @@ txring_init(int fd, unsigned int mtu)
     txring_t *txp;
 
     /* allocate memory for structure and fill it with different stuff*/
-    *txp = (txring_t *)safe_malloc(sizeof(txring_t));
+    txp = (txring_t *)safe_malloc(sizeof(txring_t));
     txp->treq = (struct tpacket_req *)safe_malloc(sizeof(struct tpacket_req));
 
     txring_mkreq(txp->treq, mtu);

+ 2 - 2
src/common/txring.h

@@ -33,11 +33,11 @@
 
 #pragma once
 
-#ifdef HAVE_TX_RING
-
 #include "defines.h"
 #include "config.h"
 
+#ifdef HAVE_TX_RING
+
 #if __GLIBC__ >= 2 && __GLIBC_MINOR >= 1
 #include <net/ethernet.h> /* the L2 protocols */
 #include <netpacket/packet.h>

+ 1 - 1
src/common/utils.c

@@ -2,7 +2,7 @@
 
 /*
  *   Copyright (c) 2001-2010 Aaron Turner <aturner at synfin dot net>
- *   Copyright (c) 2013-2024 Fred Klassen <tcpreplay at appneta dot com> - AppNeta
+ *   Copyright (c) 2013-2025 Fred Klassen <tcpreplay at appneta dot com> - AppNeta
  *
  *   The Tcpreplay Suite of tools is free software: you can redistribute it
  *   and/or modify it under the terms of the GNU General Public License as

+ 1 - 1
src/common/utils.h

@@ -2,7 +2,7 @@
 
 /*
  *   Copyright (c) 2001-2010 Aaron Turner <aturner at synfin dot net>
- *   Copyright (c) 2013-2024 Fred Klassen <tcpreplay at appneta dot com> - AppNeta
+ *   Copyright (c) 2013-2025 Fred Klassen <tcpreplay at appneta dot com> - AppNeta
  *
  *   The Tcpreplay Suite of tools is free software: you can redistribute it
  *   and/or modify it under the terms of the GNU General Public License as

+ 5 - 1
src/common/xX.c

@@ -2,7 +2,7 @@
 
 /*
  *   Copyright (c) 2001-2010 Aaron Turner <aturner at synfin dot net>
- *   Copyright (c) 2013-2024 Fred Klassen <tcpreplay at appneta dot com> - AppNeta
+ *   Copyright (c) 2013-2025 Fred Klassen <tcpreplay at appneta dot com> - AppNeta
  *
  *   The Tcpreplay Suite of tools is free software: you can redistribute it
  *   and/or modify it under the terms of the GNU General Public License as
@@ -43,6 +43,10 @@ parse_xX_str(tcpr_xX_t *xX, char *str, tcpr_bpf_t *bpf)
     dbgx(1, "Parsing string: %s", str);
     dbgx(1, "Switching on: %c", str[0]);
 
+    if (str[0] && str[1] == 0) {
+        errx(-1, "Syntax error for option -%c", str[0]);
+    }
+
     switch (str[0]) {
     case 'B': /* both ip's */
         str = str + 2;

+ 1 - 1
src/common/xX.h

@@ -2,7 +2,7 @@
 
 /*
  *   Copyright (c) 2001-2010 Aaron Turner <aturner at synfin dot net>
- *   Copyright (c) 2013-2024 Fred Klassen <tcpreplay at appneta dot com> - AppNeta
+ *   Copyright (c) 2013-2025 Fred Klassen <tcpreplay at appneta dot com> - AppNeta
  *
  *   The Tcpreplay Suite of tools is free software: you can redistribute it 
  *   and/or modify it under the terms of the GNU General Public License as 

+ 119 - 107
src/config.h.in

@@ -78,7 +78,7 @@
 /* Enable GNU Profiler */
 #undef GPROF
 
-/* Define to 1 if you have the `alarm' function. */
+/* Define to 1 if you have the 'alarm' function. */
 #undef HAVE_ALARM
 
 /* Define to 1 if you have the <architecture/i386/pio.h> header file. */
@@ -87,7 +87,7 @@
 /* Define to 1 if you have the <arpa/inet.h> header file. */
 #undef HAVE_ARPA_INET_H
 
-/* Define to 1 if you have the `atexit' function. */
+/* Define to 1 if you have the 'atexit' function. */
 #undef HAVE_ATEXIT
 
 /* Do we have BPF device support? */
@@ -99,16 +99,16 @@
 /* Define to 1 if you have the <bpf/libbpf.h> header file. */
 #undef HAVE_BPF_LIBBPF_H
 
-/* Define to 1 if you have the `bzero' function. */
+/* Define to 1 if you have the 'bzero' function. */
 #undef HAVE_BZERO
 
-/* Define to 1 if you have the `canonicalize_file_name' function. */
+/* Define to 1 if you have the 'canonicalize_file_name' function. */
 #undef HAVE_CANONICALIZE_FILE_NAME
 
-/* Define to 1 if you have the `chmod' function. */
+/* Define to 1 if you have the 'chmod' function. */
 #undef HAVE_CHMOD
 
-/* Define to 1 if you have the `ctime' function. */
+/* Define to 1 if you have the 'ctime' function. */
 #undef HAVE_CTIME
 
 /* Building Cygwin */
@@ -120,7 +120,7 @@
 /* Define this if /dev/zero is readable device */
 #undef HAVE_DEV_ZERO
 
-/* Define to 1 if you have the <dirent.h> header file, and it defines `DIR'.
+/* Define to 1 if you have the <dirent.h> header file, and it defines 'DIR'.
    */
 #undef HAVE_DIRENT_H
 
@@ -142,46 +142,46 @@
 /* Define to 1 if you have the <dnet.h> header file. */
 #undef HAVE_DNET_H
 
-/* Define to 1 if you don't have `vprintf' but do have `_doprnt.' */
+/* Define to 1 if you don't have 'vprintf' but do have '_doprnt.' */
 #undef HAVE_DOPRNT
 
 /* Define to 1 if you have the <dumbnet.h> header file. */
 #undef HAVE_DUMBNET_H
 
-/* Define to 1 if you have the `dup2' function. */
+/* Define to 1 if you have the 'dup2' function. */
 #undef HAVE_DUP2
 
 /* Define to 1 if you have the <errno.h> header file. */
 #undef HAVE_ERRNO_H
 
-/* Define to 1 if you have the `fchmod' function. */
+/* Define to 1 if you have the 'fchmod' function. */
 #undef HAVE_FCHMOD
 
 /* Define to 1 if you have the <fcntl.h> header file. */
 #undef HAVE_FCNTL_H
 
-/* Define to 1 if you have the `fork' function. */
+/* Define to 1 if you have the 'fork' function. */
 #undef HAVE_FORK
 
 /* Building Free BSD */
 #undef HAVE_FREEBSD
 
-/* Define to 1 if fseeko (and presumably ftello) exists and is declared. */
+/* Define to 1 if fseeko (and ftello) are declared in stdio.h. */
 #undef HAVE_FSEEKO
 
-/* Define to 1 if you have the `fstat' function. */
+/* Define to 1 if you have the 'fstat' function. */
 #undef HAVE_FSTAT
 
 /* Define to 1 if you have the <fts.h> header file. */
 #undef HAVE_FTS_H
 
-/* Define to 1 if you have the `gethostbyname' function. */
+/* Define to 1 if you have the 'gethostbyname' function. */
 #undef HAVE_GETHOSTBYNAME
 
-/* Define to 1 if you have the `getpagesize' function. */
+/* Define to 1 if you have the 'getpagesize' function. */
 #undef HAVE_GETPAGESIZE
 
-/* Define to 1 if you have the `gettimeofday' function. */
+/* Define to 1 if you have the 'gettimeofday' function. */
 #undef HAVE_GETTIMEOFDAY
 
 /* Do we have inet_addr? */
@@ -190,7 +190,7 @@
 /* Do we have inet_aton? */
 #undef HAVE_INET_ATON
 
-/* Define to 1 if you have the `inet_ntoa' function. */
+/* Define to 1 if you have the 'inet_ntoa' function. */
 #undef HAVE_INET_NTOA
 
 /* Do we have inet_ntop? */
@@ -199,61 +199,61 @@
 /* Do we have inet_pton? */
 #undef HAVE_INET_PTON
 
-/* Define to 1 if the system has the type `int16_t'. */
+/* Define to 1 if the system has the type 'int16_t'. */
 #undef HAVE_INT16_T
 
-/* Define to 1 if the system has the type `int32_t'. */
+/* Define to 1 if the system has the type 'int32_t'. */
 #undef HAVE_INT32_T
 
-/* Define to 1 if the system has the type `int8_t'. */
+/* Define to 1 if the system has the type 'int8_t'. */
 #undef HAVE_INT8_T
 
-/* Define to 1 if the system has the type `intptr_t'. */
+/* Define to 1 if the system has the type 'intptr_t'. */
 #undef HAVE_INTPTR_T
 
 /* Define to 1 if you have the <inttypes.h> header file. */
 #undef HAVE_INTTYPES_H
 
-/* Define to 1 if you have the `ioperm' function. */
+/* Define to 1 if you have the 'ioperm' function. */
 #undef HAVE_IOPERM
 
-/* Define to 1 if you have the `asan' library (-lasan). */
+/* Define to 1 if you have the 'asan' library (-lasan). */
 #undef HAVE_LIBASAN
 
-/* Define to 1 if you have the `bpf' library (-lbpf). */
+/* Define to 1 if you have the 'bpf' library (-lbpf). */
 #undef HAVE_LIBBPF
 
-/* Define to 1 if you have the `bsd' library (-lbsd). */
+/* Define to 1 if you have the 'bsd' library (-lbsd). */
 #undef HAVE_LIBBSD
 
 /* Do we have libdnet? */
 #undef HAVE_LIBDNET
 
-/* Define to 1 if you have the `gen' library (-lgen). */
+/* Define to 1 if you have the 'gen' library (-lgen). */
 #undef HAVE_LIBGEN
 
 /* Define to 1 if you have the <libgen.h> header file. */
 #undef HAVE_LIBGEN_H
 
-/* Define to 1 if you have the `intl' library (-lintl). */
+/* Define to 1 if you have the 'intl' library (-lintl). */
 #undef HAVE_LIBINTL
 
 /* Define to 1 if you have the <libintl.h> header file. */
 #undef HAVE_LIBINTL_H
 
-/* Define to 1 if you have the `nsl' library (-lnsl). */
+/* Define to 1 if you have the 'nsl' library (-lnsl). */
 #undef HAVE_LIBNSL
 
 /* Does this version of libpcap support netmap? */
 #undef HAVE_LIBPCAP_NETMAP
 
-/* Define to 1 if you have the `resolv' library (-lresolv). */
+/* Define to 1 if you have the 'resolv' library (-lresolv). */
 #undef HAVE_LIBRESOLV
 
-/* Define to 1 if you have the `rt' library (-lrt). */
+/* Define to 1 if you have the 'rt' library (-lrt). */
 #undef HAVE_LIBRT
 
-/* Define to 1 if you have the `socket' library (-lsocket). */
+/* Define to 1 if you have the 'socket' library (-lsocket). */
 #undef HAVE_LIBSOCKET
 
 /* Do we have LIBXDP AF_XDP socket support? */
@@ -265,22 +265,22 @@
 /* Building Linux */
 #undef HAVE_LINUX
 
-/* Define to 1 if you have the `memmove' function. */
+/* Define to 1 if you have the 'memmove' function. */
 #undef HAVE_MEMMOVE
 
 /* Define to 1 if you have the <memory.h> header file. */
 #undef HAVE_MEMORY_H
 
-/* Define to 1 if you have the `memset' function. */
+/* Define to 1 if you have the 'memset' function. */
 #undef HAVE_MEMSET
 
-/* Define to 1 if you have the `mmap' function. */
+/* Define to 1 if you have the 'mmap' function. */
 #undef HAVE_MMAP
 
-/* Define to 1 if you have the `munmap' function. */
+/* Define to 1 if you have the 'munmap' function. */
 #undef HAVE_MUNMAP
 
-/* Define to 1 if you have the <ndir.h> header file, and it defines `DIR'. */
+/* Define to 1 if you have the <ndir.h> header file, and it defines 'DIR'. */
 #undef HAVE_NDIR_H
 
 /* Define to 1 if you have the <netinet/in.h> header file. */
@@ -310,7 +310,7 @@
 /* Define to 1 if you have the <net/route.h> header file. */
 #undef HAVE_NET_ROUTE_H
 
-/* Define to 1 if you have the `ntohll' function. */
+/* Define to 1 if you have the 'ntohll' function. */
 #undef HAVE_NTOHLL
 
 /* Building Open BSD */
@@ -355,28 +355,28 @@
 /* ${with_pfring_lib} numa pthread rt */
 #undef HAVE_PF_RING_PCAP
 
-/* Define to 1 if the system has the type `pid_t'. */
+/* Define to 1 if the system has the type 'pid_t'. */
 #undef HAVE_PID_T
 
-/* Define to 1 if you have the `poll' function. */
+/* Define to 1 if you have the 'poll' function. */
 #undef HAVE_POLL
 
 /* Define to 1 if you have the <poll.h> header file. */
 #undef HAVE_POLL_H
 
-/* Define to 1 if you have the `pow' function. */
+/* Define to 1 if you have the 'pow' function. */
 #undef HAVE_POW
 
-/* Define to 1 if the system has the type `ptrdiff_t'. */
+/* Define to 1 if the system has the type 'ptrdiff_t'. */
 #undef HAVE_PTRDIFF_T
 
-/* Define to 1 if you have the `putenv' function. */
+/* Define to 1 if you have the 'putenv' function. */
 #undef HAVE_PUTENV
 
 /* Define this if we have a functional realpath(3C) */
 #undef HAVE_REALPATH
 
-/* Define to 1 if you have the `regcomp' function. */
+/* Define to 1 if you have the 'regcomp' function. */
 #undef HAVE_REGCOMP
 
 /* Define to 1 if you have the <runetype.h> header file. */
@@ -385,7 +385,7 @@
 /* Define to 1 if you have the <sched.h> header file. */
 #undef HAVE_SCHED_H
 
-/* Define to 1 if you have the `select' function. */
+/* Define to 1 if you have the 'select' function. */
 #undef HAVE_SELECT
 
 /* Define to 1 if you have the <setjmp.h> header file. */
@@ -394,13 +394,13 @@
 /* Define to 1 if you have the <signal.h> header file. */
 #undef HAVE_SIGNAL_H
 
-/* Define to 1 if the system has the type `size_t'. */
+/* Define to 1 if the system has the type 'size_t'. */
 #undef HAVE_SIZE_T
 
-/* Define to 1 if you have the `snprintf' function. */
+/* Define to 1 if you have the 'snprintf' function. */
 #undef HAVE_SNPRINTF
 
-/* Define to 1 if you have the `socket' function. */
+/* Define to 1 if you have the 'socket' function. */
 #undef HAVE_SOCKET
 
 /* Building Solaris */
@@ -418,22 +418,25 @@
 /* Define to 1 if you have the <stdint.h> header file. */
 #undef HAVE_STDINT_H
 
+/* Define to 1 if you have the <stdio.h> header file. */
+#undef HAVE_STDIO_H
+
 /* Define to 1 if you have the <stdlib.h> header file. */
 #undef HAVE_STDLIB_H
 
-/* Define to 1 if you have the `strcasecmp' function. */
+/* Define to 1 if you have the 'strcasecmp' function. */
 #undef HAVE_STRCASECMP
 
-/* Define to 1 if you have the `strchr' function. */
+/* Define to 1 if you have the 'strchr' function. */
 #undef HAVE_STRCHR
 
-/* Define to 1 if you have the `strcspn' function. */
+/* Define to 1 if you have the 'strcspn' function. */
 #undef HAVE_STRCSPN
 
-/* Define to 1 if you have the `strdup' function. */
+/* Define to 1 if you have the 'strdup' function. */
 #undef HAVE_STRDUP
 
-/* Define to 1 if you have the `strerror' function. */
+/* Define to 1 if you have the 'strerror' function. */
 #undef HAVE_STRERROR
 
 /* Define this if strftime() works */
@@ -445,37 +448,37 @@
 /* Define to 1 if you have the <string.h> header file. */
 #undef HAVE_STRING_H
 
-/* Define to 1 if you have the `strlcpy' function. */
+/* Define to 1 if you have the 'strlcpy' function. */
 #undef HAVE_STRLCPY
 
-/* Define to 1 if you have the `strncpy' function. */
+/* Define to 1 if you have the 'strncpy' function. */
 #undef HAVE_STRNCPY
 
-/* Define to 1 if you have the `strpbrk' function. */
+/* Define to 1 if you have the 'strpbrk' function. */
 #undef HAVE_STRPBRK
 
-/* Define to 1 if you have the `strrchr' function. */
+/* Define to 1 if you have the 'strrchr' function. */
 #undef HAVE_STRRCHR
 
-/* Define to 1 if you have the `strsignal' function. */
+/* Define to 1 if you have the 'strsignal' function. */
 #undef HAVE_STRSIGNAL
 
-/* Define to 1 if you have the `strspn' function. */
+/* Define to 1 if you have the 'strspn' function. */
 #undef HAVE_STRSPN
 
-/* Define to 1 if you have the `strstr' function. */
+/* Define to 1 if you have the 'strstr' function. */
 #undef HAVE_STRSTR
 
-/* Define to 1 if you have the `strtol' function. */
+/* Define to 1 if you have the 'strtol' function. */
 #undef HAVE_STRTOL
 
-/* Define to 1 if you have the `strtoul' function. */
+/* Define to 1 if you have the 'strtoul' function. */
 #undef HAVE_STRTOUL
 
-/* Define to 1 if you have the `strtoull' function. */
+/* Define to 1 if you have the 'strtoull' function. */
 #undef HAVE_STRTOULL
 
-/* Define to 1 if `tv_sec' is a member of `struct timeval'. */
+/* Define to 1 if 'tv_sec' is a member of 'struct timeval'. */
 #undef HAVE_STRUCT_TIMEVAL_TV_SEC
 
 /* Building SunOS */
@@ -484,7 +487,7 @@
 /* Define to 1 if you have the <sysexits.h> header file. */
 #undef HAVE_SYSEXITS_H
 
-/* Define to 1 if you have the <sys/dir.h> header file, and it defines `DIR'.
+/* Define to 1 if you have the <sys/dir.h> header file, and it defines 'DIR'.
    */
 #undef HAVE_SYS_DIR_H
 
@@ -503,7 +506,7 @@
 /* Define to 1 if you have the <sys/mman.h> header file. */
 #undef HAVE_SYS_MMAN_H
 
-/* Define to 1 if you have the <sys/ndir.h> header file, and it defines `DIR'.
+/* Define to 1 if you have the <sys/ndir.h> header file, and it defines 'DIR'.
    */
 #undef HAVE_SYS_NDIR_H
 
@@ -555,19 +558,19 @@
 /* Do we have Linux TX_RING socket support? */
 #undef HAVE_TX_RING
 
-/* Define to 1 if the system has the type `uint16_t'. */
+/* Define to 1 if the system has the type 'uint16_t'. */
 #undef HAVE_UINT16_T
 
-/* Define to 1 if the system has the type `uint32_t'. */
+/* Define to 1 if the system has the type 'uint32_t'. */
 #undef HAVE_UINT32_T
 
-/* Define to 1 if the system has the type `uint8_t'. */
+/* Define to 1 if the system has the type 'uint8_t'. */
 #undef HAVE_UINT8_T
 
-/* Define to 1 if the system has the type `uintptr_t'. */
+/* Define to 1 if the system has the type 'uintptr_t'. */
 #undef HAVE_UINTPTR_T
 
-/* Define to 1 if the system has the type `uint_t'. */
+/* Define to 1 if the system has the type 'uint_t'. */
 #undef HAVE_UINT_T
 
 /* Define to 1 if you have the <unistd.h> header file. */
@@ -582,22 +585,22 @@
 /* Define to 1 if you have the <varargs.h> header file. */
 #undef HAVE_VARARGS_H
 
-/* Define to 1 if you have the `vfork' function. */
+/* Define to 1 if you have the 'vfork' function. */
 #undef HAVE_VFORK
 
 /* Define to 1 if you have the <vfork.h> header file. */
 #undef HAVE_VFORK_H
 
-/* Define to 1 if you have the `vprintf' function. */
+/* Define to 1 if you have the 'vprintf' function. */
 #undef HAVE_VPRINTF
 
-/* Define to 1 if you have the `vsnprintf' function. */
+/* Define to 1 if you have the 'vsnprintf' function. */
 #undef HAVE_VSNPRINTF
 
 /* Define to 1 if you have the <wchar.h> header file. */
 #undef HAVE_WCHAR_H
 
-/* Define to 1 if the system has the type `wchar_t'. */
+/* Define to 1 if the system has the type 'wchar_t'. */
 #undef HAVE_WCHAR_T
 
 /* Windows/Cygwin */
@@ -606,19 +609,19 @@
 /* Do we have WinPcap? */
 #undef HAVE_WINPCAP
 
-/* Define to 1 if the system has the type `wint_t'. */
+/* Define to 1 if the system has the type 'wint_t'. */
 #undef HAVE_WINT_T
 
-/* Define to 1 if `fork' works. */
+/* Define to 1 if 'fork' works. */
 #undef HAVE_WORKING_FORK
 
-/* Define to 1 if `vfork' works. */
+/* Define to 1 if 'vfork' works. */
 #undef HAVE_WORKING_VFORK
 
 /* Define to 1 if you have the <xdp/libxdp.h> header file. */
 #undef HAVE_XDP_LIBXDP_H
 
-/* Define to 1 if the system has the type `_Bool'. */
+/* Define to 1 if the system has the type '_Bool'. */
 #undef HAVE__BOOL
 
 /* What is the path (if any) to the libpcap bpf header file? */
@@ -627,18 +630,18 @@
 /* Version of libdnet */
 #undef LIBDNET_VERSION
 
-/* Define to 1 if `lstat' dereferences a symlink specified with a trailing
+/* Define to 1 if 'lstat' dereferences a symlink specified with a trailing
    slash. */
 #undef LSTAT_FOLLOWS_SLASHED_SYMLINK
 
 /* Define to the sub-directory where libtool stores uninstalled libraries. */
 #undef LT_OBJDIR
 
-/* Define to 1 if `major', `minor', and `makedev' are declared in <mkdev.h>.
+/* Define to 1 if 'major', 'minor', and 'makedev' are declared in <mkdev.h>.
    */
 #undef MAJOR_IN_MKDEV
 
-/* Define to 1 if `major', `minor', and `makedev' are declared in
+/* Define to 1 if 'major', 'minor', and 'makedev' are declared in
    <sysmacros.h>. */
 #undef MAJOR_IN_SYSMACROS
 
@@ -681,19 +684,21 @@
 /* name of regex header file */
 #undef REGEX_HEADER
 
-/* The size of `char *', as computed by sizeof. */
+/* The size of 'char *', as computed by sizeof. */
 #undef SIZEOF_CHAR_P
 
-/* The size of `int', as computed by sizeof. */
+/* The size of 'int', as computed by sizeof. */
 #undef SIZEOF_INT
 
-/* The size of `long', as computed by sizeof. */
+/* The size of 'long', as computed by sizeof. */
 #undef SIZEOF_LONG
 
-/* The size of `short', as computed by sizeof. */
+/* The size of 'short', as computed by sizeof. */
 #undef SIZEOF_SHORT
 
-/* Define to 1 if you have the ANSI C header files. */
+/* Define to 1 if all of the C89 standard headers exist (not just the ones
+   required in a freestanding environment). This macro is provided for
+   backward compatibility; new code need not use it. */
 #undef STDC_HEADERS
 
 /* The tcpdump binary initially used */
@@ -702,9 +707,6 @@
 /* Enable dumping of trace timestamps at the end of a test */
 #undef TIMESTAMP_TRACE
 
-/* Define to 1 if you can safely include both <sys/time.h> and <time.h>. */
-#undef TIME_WITH_SYS_TIME
-
 /* Version number of package */
 #undef VERSION
 
@@ -726,20 +728,18 @@
 # endif
 #endif
 
-/* Enable large inode numbers on Mac OS X 10.5.  */
-#ifndef _DARWIN_USE_64_BIT_INODE
-# define _DARWIN_USE_64_BIT_INODE 1
-#endif
-
 /* Number of bits in a file offset, on hosts where this is settable. */
 #undef _FILE_OFFSET_BITS
 
-/* Define to 1 to make fseeko visible on some hosts (e.g. glibc 2.2). */
+/* Define to 1 if necessary to make fseeko visible. */
 #undef _LARGEFILE_SOURCE
 
-/* Define for large files, on AIX-style hosts. */
+/* Define to 1 on platforms where this makes off_t a 64-bit type. */
 #undef _LARGE_FILES
 
+/* Number of bits in time_t, on hosts where this is settable. */
+#undef _TIME_BITS
+
 /* Define for Solaris 2.5.1 so the uint32_t typedef from <sys/synch.h>,
    <pthread.h>, or <semaphore.h> is not used. If the typedef were allowed, the
    #define below would cause a syntax error. */
@@ -755,10 +755,13 @@
    #define below would cause a syntax error. */
 #undef _UINT8_T
 
-/* Define to empty if `const' does not conform to ANSI C. */
+/* Define to 1 on platforms where this makes time_t a 64-bit type. */
+#undef __MINGW_USE_VC2005_COMPAT
+
+/* Define to empty if 'const' does not conform to ANSI C. */
 #undef const
 
-/* Define to `__inline__' or `__inline' if that's what the C compiler
+/* Define to '__inline__' or '__inline' if that's what the C compiler
    calls it, or to nothing if 'inline' is not supported under any name.  */
 #ifndef __cplusplus
 #undef inline
@@ -780,30 +783,39 @@
    a type exists and the standard includes do not define it. */
 #undef int8_t
 
-/* Define to `long int' if <sys/types.h> does not define. */
+/* Define to 'long int' if <sys/types.h> does not define. */
 #undef off_t
 
-/* Define to `int' if <sys/types.h> does not define. */
+/* Define as a signed integer type capable of holding a process identifier. */
 #undef pid_t
 
-/* Define to `unsigned int' if <sys/types.h> does not define. */
+/* Define as 'unsigned int' if <stddef.h> doesn't define. */
 #undef size_t
 
-/* Define to `int' if <sys/types.h> does not define. */
+/* Define as 'int' if <sys/types.h> doesn't define. */
 #undef ssize_t
 
-/* Define to `uint16_t' if <sys/types.h> does not define. */
+/* Define to 'uint8_t' if <sys/types.h> does not define. */
+#undef u_char
+
+/* Define to 'uint32_t' if <sys/types.h> does not define. */
+#undef u_int
+
+/* Define to 'uint16_t' if <sys/types.h> does not define. */
 #undef u_int16_t
 
-/* Define to `uint32_t' if <sys/types.h> does not define. */
+/* Define to 'uint32_t' if <sys/types.h> does not define. */
 #undef u_int32_t
 
-/* Define to `uint64_t' if <sys/types.h> does not define. */
+/* Define to 'uint64_t' if <sys/types.h> does not define. */
 #undef u_int64_t
 
-/* Define to `uint8_t' if <sys/types.h> does not define. */
+/* Define to 'uint8_t' if <sys/types.h> does not define. */
 #undef u_int8_t
 
+/* Define to 'uint16_t' if <sys/types.h> does not define. */
+#undef u_short
+
 /* Define to the type of an unsigned integer type of width exactly 16 bits if
    such a type exists and the standard includes do not define it. */
 #undef uint16_t
@@ -820,5 +832,5 @@
    such a type exists and the standard includes do not define it. */
 #undef uint8_t
 
-/* Define as `fork' if `vfork' does not work. */
+/* Define as 'fork' if 'vfork' does not work. */
 #undef vfork

+ 0 - 408
src/defines.h

@@ -1,408 +0,0 @@
-#pragma once
-
-#include "config.h"
-
-#ifdef HAVE_STDDEF_H
-#include <stddef.h>
-#endif
-
-#ifdef HAVE_SYS_TYPES_H
-#include <sys/types.h>
-#endif
-
-#ifdef WIN32
-#include "msvc_inttypes.h"
-#include "msvc_stdint.h"
-#else
-
-#ifdef HAVE_INTTYPES_H
-#include <inttypes.h>
-#endif
-
-#ifdef HAVE_STDINT_H
-#include <stdint.h>
-#endif
-
-#endif /* WIN32 */
-
-#ifdef HAVE_SYS_SOCKET
-#include <sys/socket.h>
-#endif
-
-#ifdef HAVE_NETINET_IN_H
-#include <netinet/in.h>
-#endif
-
-#ifdef HAVE_NETINET_IN_SYSTM_H
-#include <netinet/in_systm.h>
-#endif
-
-#ifdef HAVE_SCHED_H
-#include <sched.h>
-#endif
-
-#include "tcpr.h"
-
-#ifdef HAVE_BPF
-#include <net/bpf.h>
-#define PCAP_DONT_INCLUDE_PCAP_BPF_H 1
-#endif
-
-#ifdef HAVE_LIBBPF
-#undef HAVE_BPF
-#include <bpf/bpf.h>
-#include <bpf/libbpf.h>
-#define PCAP_DONT_INCLUDE_PCAP_BPF_H 1
-
-struct bpf_program {
-char dummy[0];
-};
-
-#endif
-
-#ifdef HAVE_LIBXDP
-#include <xdp/libxdp.h>
-#endif
-
-#if defined INCLUDE_PCAP_BPF_H_FILE && !defined PCAP_DONT_INCLUDE_PCAP_BPF_H
-#include <@INCLUDE_PCAP_BPF_HEADER@>
-#define PCAP_DONT_INCLUDE_PCAP_BPF_H 1 /* don't re-include it in pcap.h */
-#endif
-
-#include </usr/include/pcap.h>
-
-/* include our own strlcat/strlcpy? */
-#ifndef HAVE_STRLCPY
-#include <lib/strlcpy.h>
-#endif
-
-/*
- * net/bpf.h doesn't include DLT types, but pcap-bpf.h does.
- * Unfortunately, pcap-bpf.h also includes things in net/bpf.h
- * while also missing some key things (wow, that sucks)
- * The result is that I stole the DLT types from pcap-bpf.h and
- * put them in here.
- */
-#include <common/dlt_names.h>
-
-#ifdef HAVE_BOOL_H
-#include <bool.h>
-#endif
-
-#ifdef HAVE_STDBOOL_H
-#include <stdbool.h>
-#endif
-
-
-/* should packet counters be 32 or 64 bit? --enable-64bit */
-#ifdef ENABLE_64BITS
-#define COUNTER unsigned long long
-#define COUNTER_SPEC "%llu"
-#else
-#define COUNTER unsigned long
-#define COUNTER_SPEC "%lu"
-#endif
-#define COUNTER_OVERFLOW_RISK (((COUNTER)~0) >> 23)
-
-#include <common/cidr.h>
-#include <common/list.h>
-
-
-typedef struct tcpr_ipv4_hdr ipv4_hdr_t;
-typedef struct tcpr_ipv6_hdr ipv6_hdr_t;
-typedef struct tcpr_tcp_hdr tcp_hdr_t;
-typedef struct tcpr_udp_hdr udp_hdr_t;
-typedef struct tcpr_icmpv4_hdr icmpv4_hdr_t;
-typedef struct tcpr_icmpv6_hdr icmpv6_hdr_t;
-typedef struct tcpr_ethernet_hdr eth_hdr_t;
-typedef struct tcpr_802_1q_hdr vlan_hdr_t;
-typedef struct sll_header sll_hdr_t;
-typedef struct sll2_header sll2_hdr_t;
-typedef struct tcpr_arp_hdr arp_hdr_t;
-typedef struct tcpr_dnsv4_hdr dnsv4_hdr_t;
-
-/* our custom typdefs/structs */
-typedef u_char tcpr_macaddr_t[TCPR_ETH_H];
-
-typedef struct tcpr_bpf_s {
-    char *filter;
-    int optimize;
-    struct bpf_program program;
-} tcpr_bpf_t;
-
-typedef struct tcpr_xX_s {
-#define xX_MODE_INCLUDE 'x'
-#define xX_MODE_EXCLUDE 'X'
-    int mode;
-    tcpr_list_t *list;
-    tcpr_cidr_t *cidr;
-#define xX_TYPE_LIST 1
-#define xX_TYPE_CIDR 2
-    int type;
-} tcpr_xX_t;
-
-/* number of ports 0-65535 */
-#define NUM_PORTS 65536
-typedef struct tcpr_services_s {
-    char tcp[NUM_PORTS];
-    char udp[NUM_PORTS];
-} tcpr_services_t;
-
-typedef struct tcpr_speed_s {
-    /* speed modifiers */
-    int mode;
-#define SPEED_MULTIPLIER 1
-#define SPEED_MBPSRATE 2
-#define SPEED_PACKETRATE 3
-#define SPEED_TOPSPEED 4
-#define SPEED_ONEATATIME 5
-    COUNTER speed;
-    float multiplier;
-    int pps_multi;
-} tcpr_speed_t;
-
-#define MAX_FILES 1024 /* Max number of files we can pass to tcpreplay */
-
-/* Max Transmission Unit of standard ethernet  don't forget *frames* are MTU + L2 header! */
-#define DEFAULT_MTU 1500
-
-/* tell libpcap to capture the entire packet
- * this is the maximum size supported by libpcap
- * (https://github.com/the-tcpdump-group/libpcap/blob/master/pcap-int.h#L99-L125)
- */
-#define MAX_SNAPLEN 262144
-
-/* snap length plus some room for adding a
- * couple VLAN headers or a L2 header
- */
-#define MAXPACKET (MAX_SNAPLEN + 22)
-
-#define PACKET_HEADROOM 512 /* additional headroom allocated for packets to accommodate editing */
-
-#define DNS_RESOLVE 1
-#define DNS_DONT_RESOLVE 0
-
-#define RESOLVE 0        /* disable dns lookups */
-#define BPF_OPTIMIZE 1   /* default is to optimize bpf program */
-#define PCAP_TIMEOUT 100 /* 100ms pcap_open_live timeout */
-
-#define DEFAULT_FUZZ_FACTOR 8
-
-/* HP-UX already defines TRUE/FALSE */
-#ifndef TRUE
-typedef enum bool_e { FALSE = 0, TRUE } bool_t;
-#endif
-
-#define EBUF_SIZE 1024 /* size of our error buffers */
-#define MAC_SIZE 7     /* size of the mac[] buffer */
-
-typedef enum pad_e { PAD_PACKET, TRUNC_PACKET } pad_t;
-
-#define DNS_QUERY_FLAG 0x8000
-
-typedef enum direction_e { DIR_UNKNOWN = -1, DIR_CLIENT = 0, DIR_SERVER = 1, DIR_ANY = 2 } direction_t;
-
-typedef enum tcpprep_mode_e {
-    ERROR_MODE,  /* Some kind of error has occurred */
-    CIDR_MODE,   /* single pass, CIDR netblock */
-    REGEX_MODE,  /* single pass, regex */
-    PORT_MODE,   /* single pass, use src/dst ports to split */
-    MAC_MODE,    /* single pass, use src mac to split */
-    FIRST_MODE,  /* single pass, use first seen to split */
-    AUTO_MODE,   /* first pass through in auto mode */
-    ROUTER_MODE, /* second pass through in router mode */
-    BRIDGE_MODE, /* second pass through in bridge mode */
-    SERVER_MODE, /* second pass through in server (router) mode */
-    CLIENT_MODE  /* second pass through in client (router) mode */
-} tcpprep_mode_t;
-
-#define BROADCAST_MAC "\xff\xff\xff\xff\xff\xff"
-#define IPV4_MULTICAST_MAC "\x01\x00\x5e\x00\x00\x00"
-#define IPV6_MULTICAST_MAC "\x33\x33\x00\x00\x00\x00"
-#define IPV4_VRRP "\x00\x00\x50\x00\x01\x00"
-#define IPV6_VRRP "\x00\x00\x50\x00\x02\x00"
-
-/* MAC macros for printf */
-#define MAC_FORMAT "%02X:%02X:%02X:%02X:%02X:%02X"
-#define MAC_STR(x) x[0], x[1], x[2], x[3], x[4], x[5]
-
-/* struct timeval print structs */
-#ifdef HAVE_DARWIN
-/* Darwin defines usec as an __int32_t, not unsigned long. */
-#define TIMEVAL_FORMAT "%lus %dusec"
-#else
-#define TIMEVAL_FORMAT "%lus %luusec"
-#endif
-#define TIMESPEC_FORMAT "%lus %lunsec"
-
-/* force a word or half-word swap on both Big and Little endian systems */
-#ifndef SWAPLONG
-#define SWAPLONG(y) ((((y)&0xff) << 24) | (((y)&0xff00) << 8) | (((y)&0xff0000) >> 8) | (((y) >> 24) & 0xff))
-#endif
-
-#ifndef SWAPSHORT
-#define SWAPSHORT(y) ((((y)&0xff) << 8) | ((u_short)((y)&0xff00) >> 8))
-#endif
-
-/* converts a 64bit int to network byte order */
-#if !defined ntohll && !defined htonll
-#ifndef HAVE_NTOHLL
-#ifdef WORDS_BIGENDIAN
-#define ntohll(x) (x)
-#define htonll(x) (x)
-#else
-/* stolen from http://www.codeproject.com/cpp/endianness.asp */
-#define ntohll(x) (((u_int64_t)(ntohl((int)((x << 32) >> 32))) << 32) | (unsigned int)ntohl(((int)(x >> 32))))
-#define htonll(x) ntohll(x)
-#endif /* WORDS_BIGENDIAN */
-#endif /* HAVE_NTOHLL */
-#endif /* !ntohll && !htonll */
-
-#define DEBUG_INFO 1   /* informational only, lessthan 1 line per packet */
-#define DEBUG_BASIC 2  /* limited debugging, one line per packet */
-#define DEBUG_DETAIL 3 /* more detailed, a few lines per packet */
-#define DEBUG_MORE 4   /* even more detail */
-#define DEBUG_CODE 5   /* examines code & values, many lines per packet */
-
-#if defined HAVE_IOPERM && defined __i386_
-#define HAVE_IOPORT_SLEEP
-#endif
-
-/* Win32 doesn't know about PF_INET6 */
-#ifndef PF_INET6
-#ifdef AF_INET6
-#define PF_INET6 AF_INET6
-#else
-#define PF_INET6 30 /* stolen from OS/X */
-#endif
-#endif
-
-/* convert IPv6 Extension Header Len value to bytes */
-#define IPV6_EXTLEN_TO_BYTES(x) ((x * 4) + 8)
-
-#ifndef HAVE_UINT8_T
-typedef u_int8_t uint8_t typedef u_int16_t uint16_t typedef u_int32_t uint32_t
-#endif
-
-/* Support for flexible arrays. */
-#undef __flexarr
-#if defined(__GNUC__) && ((__GNUC__ > 2) || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97))
-/* GCC 2.97 supports C99 flexible array members.  */
-#define __flexarr []
-#else
-#ifdef __GNUC__
-#define __flexarr [0]
-#else
-#if defined(__STDC_VERSION__) && __STDC_VERSION__ >= 199901L
-#define __flexarr []
-#elif defined(_WIN32)
-/* MS VC++ */
-#define __flexarr []
-#else
-/* Some other non-C99 compiler. Approximate with [1]. */
-#define __flexarr [1]
-#endif
-#endif
-#endif
-
-
-/* Time converters */
-#define SEC_TO_MILLISEC(x) (x * 1000)
-#define SEC_TO_MICROSEC(x) (x * 1000000)
-#define SEC_TO_NANOSEC(x) ((u_int64_t)x * 1000000000)
-
-#define MILLISEC_TO_SEC(x) (x / 1000)
-#define MICROSEC_TO_SEC(x) (x / 1000000)
-#define NANOSEC_TO_SEC(x) ((u_int64_t)x / 1000000000)
-
-#define TIMEVAL_TO_MILLISEC(x)  (((x)->tv_sec * 1000) + ((x)->tv_usec / 1000))
-#define TIMEVAL_TO_MICROSEC(x)  (((x)->tv_sec * 1000000) + (x)->tv_usec)
-#define TIMEVAL_TO_NANOSEC(x)   ((u_int64_t)((x)->tv_sec * 1000000000) + ((u_int64_t)(x)->tv_usec * 1000))
-
-#define MILLISEC_TO_TIMEVAL(x, tv)                                                                                     \
-    do {                                                                                                               \
-        (tv)->tv_sec = (x) / 1000;                                                                                     \
-        (tv)->tv_usec = (x * 1000) - ((tv)->tv_sec * 1000000);                                                         \
-    } while (0)
-
-#define MICROSEC_TO_TIMEVAL(x, tv)                                                                                     \
-    do {                                                                                                               \
-        (tv)->tv_sec = (x) / 1000000;                                                                                  \
-        (tv)->tv_usec = (x) - ((tv)->tv_sec * 1000000);                                                                \
-    } while (0)
-
-#define NANOSEC_TO_TIMEVAL(x, tv)                                                                                      \
-    do {                                                                                                               \
-        (tv)->tv_sec = (x) / 1000000000;                                                                               \
-        (tv)->tv_usec = ((x) % 1000000000) / 1000;                                                                     \
-    } while (0)
-
-#define NANOSEC_TO_TIMESPEC(x, ts)                                                                                     \
-    do {                                                                                                               \
-        (ts)->tv_sec = (x) / 1000000000;                                                                               \
-        (ts)->tv_nsec = (x) % 1000000000;                                                                              \
-    } while (0)
-
-#define TIMESPEC_TO_MILLISEC(x) (((x)->tv_sec * 1000) + ((x)->tv_nsec / 1000000))
-#define TIMESPEC_TO_MICROSEC(x) (((x)->tv_sec * 1000000) + (x)->tv_nsec / 1000)
-#define TIMESPEC_TO_NANOSEC(x) ((u_int64_t)((x)->tv_sec * 1000000000) + ((u_int64_t)(x)->tv_nsec))
-
-#define TIMEVAL_SET(a, b)                                                                                              \
-    do {                                                                                                               \
-        (a)->tv_sec = (b)->tv_sec;                                                                                     \
-        (a)->tv_usec = (b)->tv_usec;                                                                                   \
-    } while (0)
-
-#define TIMESPEC_SET(a, b)                                                                                             \
-    do {                                                                                                               \
-        (a)->tv_sec = (b)->tv_sec;                                                                                     \
-        (a)->tv_nsec = (b)->tv_nsec;                                                                                   \
-    } while (0)
-
-/* libpcap that supports it, puts nanosecond values in tv_usec when pcap file is read with nanosec precision,
- * and so tv_usec is directly copied to tv_nsec.
- * But older versions do that do not support nanosecond precision need to multiply tv_usec by 1000 to convert
- * to tv_nsec.
- */
-#define PCAP_TIMEVAL_TO_TIMESPEC_SET(a, b)                              \
-    do {                                                                \
-        (b)->tv_sec = (a)->tv_sec;                                      \
-        (b)->tv_nsec = (a)->tv_usec * PCAP_TSTAMP_US_TO_NS_MULTIPLIER;  \
-    } while(0)
-
-#define PCAP_TIMEVAL_TO_TIMEVAL_SET(a, b)                               \
-    do {                                                                \
-        (b)->tv_sec = (a)->tv_sec;                                      \
-        (b)->tv_usec = (a)->tv_usec / PCAP_TSTAMP_US_TO_US_DIVISOR;     \
-    } while(0)
-
-/*
- * Help suppress some compiler warnings
- * No problem if variable is actually used 
-*/
-#ifdef UNUSED
-#elif defined(__GNUC__)
-#define UNUSED(x) x __attribute__((unused))
-#elif defined(__LCLINT__)
-#define UNUSED(x) /*@unused@*/ x
-#else
-#define UNUSED(x) x
-#endif
-
-#ifndef max
-#define max(a, b)                                                                                                      \
-    ({                                                                                                                 \
-        __typeof__(a) _a = (a);                                                                                        \
-        __typeof__(b) _b = (b);                                                                                        \
-        _a > _b ? _a : _b;                                                                                             \
-    })
-#endif
-
-#ifndef min
-#define min(a, b)                                                                                                      \
-    ({                                                                                                                 \
-        __typeof__(a) _a = (a);                                                                                        \
-        __typeof__(b) _b = (b);                                                                                        \
-        _a > _b ? _b : _a;                                                                                             \
-    })
-#endif

+ 5 - 1
src/defines.h.in

@@ -10,6 +10,10 @@
 #include <sys/types.h>
 #endif
 
+#ifdef HAVE_ARPA_INET_H
+#include <arpa/inet.h>
+#endif
+
 #ifdef WIN32
 #include "msvc_inttypes.h"
 #include "msvc_stdint.h"
@@ -25,7 +29,7 @@
 
 #endif /* WIN32 */
 
-#ifdef HAVE_SYS_SOCKET
+#ifdef HAVE_SYS_SOCKET_H
 #include <sys/socket.h>
 #endif
 

+ 29 - 15
src/fragroute/Makefile.in

@@ -1,7 +1,7 @@
-# Makefile.in generated by automake 1.16.3 from Makefile.am.
+# Makefile.in generated by automake 1.17 from Makefile.am.
 # @configure_input@
 
-# Copyright (C) 1994-2020 Free Software Foundation, Inc.
+# Copyright (C) 1994-2024 Free Software Foundation, Inc.
 
 # This Makefile.in is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -71,6 +71,8 @@ am__make_running_with_option = \
   test $$has_opt = yes
 am__make_dryrun = (target_option=n; $(am__make_running_with_option))
 am__make_keepgoing = (target_option=k; $(am__make_running_with_option))
+am__rm_f = rm -f $(am__rm_f_notfound)
+am__rm_rf = rm -rf $(am__rm_f_notfound)
 pkgdatadir = $(datadir)/@PACKAGE@
 pkgincludedir = $(includedir)/@PACKAGE@
 pkglibdir = $(libdir)/@PACKAGE@
@@ -107,12 +109,13 @@ CONFIG_HEADER = $(top_builddir)/src/config.h
 CONFIG_CLEAN_FILES =
 CONFIG_CLEAN_VPATH_FILES =
 LIBRARIES = $(noinst_LIBRARIES)
-ARFLAGS = cru
+ARFLAGS = cr
 AM_V_AR = $(am__v_AR_@AM_V@)
 am__v_AR_ = $(am__v_AR_@AM_DEFAULT_V@)
 am__v_AR_0 = @echo "  AR      " $@;
 am__v_AR_1 = 
 libfragroute_a_AR = $(AR) $(ARFLAGS)
+libfragroute_a_RANLIB = $(RANLIB)
 libfragroute_a_LIBADD =
 am_libfragroute_a_OBJECTS = libfragroute_a-fragroute.$(OBJEXT) \
 	libfragroute_a-bget.$(OBJEXT) libfragroute_a-mod.$(OBJEXT) \
@@ -222,8 +225,6 @@ am__define_uniq_tagged_files = \
   unique=`for i in $$list; do \
     if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
   done | $(am__uniquify_input)`
-ETAGS = etags
-CTAGS = ctags
 am__DIST_COMMON = $(srcdir)/Makefile.in $(top_srcdir)/config/depcomp \
 	README
 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
@@ -243,6 +244,8 @@ CPP = @CPP@
 CPPFLAGS = @CPPFLAGS@
 CROSS_ARCH = @CROSS_ARCH@
 CROSS_LD = @CROSS_LD@
+CSCOPE = @CSCOPE@
+CTAGS = @CTAGS@
 CUT = @CUT@
 CXX = @CXX@
 CXXCPP = @CXXCPP@
@@ -260,8 +263,10 @@ ECHO_C = @ECHO_C@
 ECHO_N = @ECHO_N@
 ECHO_T = @ECHO_T@
 EGREP = @EGREP@
+ETAGS = @ETAGS@
 EXEEXT = @EXEEXT@
 FGREP = @FGREP@
+FILECMD = @FILECMD@
 GREP = @GREP@
 GROFF = @GROFF@
 INSTALL = @INSTALL@
@@ -334,8 +339,10 @@ ac_ct_DUMPBIN = @ac_ct_DUMPBIN@
 am__include = @am__include@
 am__leading_dot = @am__leading_dot@
 am__quote = @am__quote@
+am__rm_f_notfound = @am__rm_f_notfound@
 am__tar = @am__tar@
 am__untar = @am__untar@
+am__xargs_n = @am__xargs_n@
 bindir = @bindir@
 build = @build@
 build_alias = @build_alias@
@@ -390,6 +397,7 @@ target_cpu = @target_cpu@
 target_os = @target_os@
 target_vendor = @target_vendor@
 tcpdump_path = @tcpdump_path@
+test_hexdump = @test_hexdump@
 timestamp_trace_flag = @timestamp_trace_flag@
 top_build_prefix = @top_build_prefix@
 top_builddir = @top_builddir@
@@ -445,12 +453,12 @@ $(ACLOCAL_M4): @MAINTAINER_MODE_TRUE@ $(am__aclocal_m4_deps)
 $(am__aclocal_m4_deps):
 
 clean-noinstLIBRARIES:
-	-test -z "$(noinst_LIBRARIES)" || rm -f $(noinst_LIBRARIES)
+	-$(am__rm_f) $(noinst_LIBRARIES)
 
 libfragroute.a: $(libfragroute_a_OBJECTS) $(libfragroute_a_DEPENDENCIES) $(EXTRA_libfragroute_a_DEPENDENCIES) 
 	$(AM_V_at)-rm -f libfragroute.a
 	$(AM_V_AR)$(libfragroute_a_AR) libfragroute.a $(libfragroute_a_OBJECTS) $(libfragroute_a_LIBADD)
-	$(AM_V_at)$(RANLIB) libfragroute.a
+	$(AM_V_at)$(libfragroute_a_RANLIB) libfragroute.a
 
 mostlyclean-compile:
 	-rm -f *.$(OBJEXT)
@@ -484,7 +492,7 @@ distclean-compile:
 
 $(am__depfiles_remade):
 	@$(MKDIR_P) $(@D)
-	@echo '# dummy' >$@-t && $(am__mv) $@-t $@
+	@: >>$@
 
 am--depfiles: $(am__depfiles_remade)
 
@@ -891,7 +899,6 @@ cscopelist-am: $(am__tagged_files)
 
 distclean-tags:
 	-rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
-
 distdir: $(BUILT_SOURCES)
 	$(MAKE) $(AM_MAKEFLAGS) distdir-am
 
@@ -949,25 +956,25 @@ install-strip:
 	    "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \
 	fi
 mostlyclean-generic:
-	-test -z "$(MOSTLYCLEANFILES)" || rm -f $(MOSTLYCLEANFILES)
+	-$(am__rm_f) $(MOSTLYCLEANFILES)
 
 clean-generic:
 
 distclean-generic:
-	-test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
-	-test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES)
+	-$(am__rm_f) $(CONFIG_CLEAN_FILES)
+	-test . = "$(srcdir)" || $(am__rm_f) $(CONFIG_CLEAN_VPATH_FILES)
 
 maintainer-clean-generic:
 	@echo "This command is intended for maintainers to use"
 	@echo "it deletes files that may require special tools to rebuild."
-	-test -z "$(MAINTAINERCLEANFILES)" || rm -f $(MAINTAINERCLEANFILES)
+	-$(am__rm_f) $(MAINTAINERCLEANFILES)
 clean: clean-am
 
 clean-am: clean-generic clean-libtool clean-noinstLIBRARIES \
 	mostlyclean-am
 
 distclean: distclean-am
-		-rm -f ./$(DEPDIR)/libfragroute_a-argv.Po
+	-rm -f ./$(DEPDIR)/libfragroute_a-argv.Po
 	-rm -f ./$(DEPDIR)/libfragroute_a-bget.Po
 	-rm -f ./$(DEPDIR)/libfragroute_a-fragroute.Po
 	-rm -f ./$(DEPDIR)/libfragroute_a-iputil.Po
@@ -1035,7 +1042,7 @@ install-ps-am:
 installcheck-am:
 
 maintainer-clean: maintainer-clean-am
-		-rm -f ./$(DEPDIR)/libfragroute_a-argv.Po
+	-rm -f ./$(DEPDIR)/libfragroute_a-argv.Po
 	-rm -f ./$(DEPDIR)/libfragroute_a-bget.Po
 	-rm -f ./$(DEPDIR)/libfragroute_a-fragroute.Po
 	-rm -f ./$(DEPDIR)/libfragroute_a-iputil.Po
@@ -1098,3 +1105,10 @@ uninstall-am:
 # Tell versions [3.59,3.63) of GNU make to not export all variables.
 # Otherwise a system limit (for SysV at least) may be exceeded.
 .NOEXPORT:
+
+# Tell GNU make to disable its built-in pattern rules.
+%:: %,v
+%:: RCS/%,v
+%:: RCS/%
+%:: s.%
+%:: SCCS/s.%

+ 10 - 18
src/fragroute/bget.c

@@ -533,9 +533,9 @@ static long numdget = 0, numdrel = 0; /* Number of direct gets and rels */
 
 /* Automatic expansion block management functions */
 
-static int (*compfcn) _((bufsize sizereq, int sequence)) = NULL;
-static void *(*acqfcn) _((bufsize size)) = NULL;
-static void (*relfcn) _((void *buf)) = NULL;
+static int (*compfcn) (size_t sizereq, int sequence) = NULL;
+static void *(*acqfcn) (size_t size) = NULL;
+static void (*relfcn) (void *buf) = NULL;
 
 static bufsize exp_incr = 0;          /* Expansion block size */
 static bufsize pool_len = 0;          /*  0: no bpool calls have been made
@@ -562,8 +562,7 @@ static bufsize pool_len = 0;          /*  0: no bpool calls have been made
 /*  BGET  --  Allocate a buffer.  */
 
 void *
-bget(requested_size)
-bufsize requested_size;
+bget(bufsize requested_size)
 {
     bufsize size = requested_size;
     struct bfhead *b;
@@ -755,8 +754,7 @@ bufsize requested_size;
            region requested by the caller. */
 
 void *
-bgetz(size)
-bufsize size;
+bgetz(bufsize size)
 {
     char *buf = (char *)bget(size);
 
@@ -785,8 +783,7 @@ bufsize size;
            enhanced to allow the buffer to grow into adjacent free
            blocks and to avoid moving data unnecessarily.  */
 
-void *bgetr(buf, size) void *buf;
-bufsize size;
+void *bgetr(void *buf, bufsize size)
 {
     void *nbuf;
     bufsize osize; /* Old size of buffer */
@@ -821,7 +818,7 @@ bufsize size;
 
 /*  BREL  --  Release a buffer.  */
 
-void brel(buf) void *buf;
+void brel(void *buf)
 {
     struct bfhead *b, *bn;
 
@@ -966,11 +963,7 @@ void brel(buf) void *buf;
 
 /*  BECTL  --  Establish automatic pool expansion control  */
 
-void bectl(compact, acquire, release, pool_incr)
-  int (*compact) _((bufsize sizereq, int sequence));
-  void *(*acquire) _((bufsize size));
-  void (*release) _((void *buf));
-  bufsize pool_incr;
+void bectl(int (*compact)(size_t, int), void *(*acquire)(size_t), void (*release)(void*), bufsize pool_incr)
 {
     compfcn = compact;
     acqfcn = acquire;
@@ -981,8 +974,7 @@ void bectl(compact, acquire, release, pool_incr)
 
 /*  BPOOL  --  Add a region of memory to the buffer pool.  */
 
-void bpool(buf, len) void *buf;
-bufsize len;
+void bpool(void *buf, bufsize len)
 {
     struct bfhead *b = BFH(buf);
     struct bhead *bn;
@@ -1280,7 +1272,7 @@ extern long time();
 #endif
 
 extern char *malloc();
-extern int free _((char *));
+extern int free (char *);
 
 static char *bchain = NULL;          /* Our private buffer chain */
 static char *bp = NULL;           /* Our initial buffer pool */

+ 13 - 23
src/fragroute/bget.h

@@ -6,27 +6,17 @@
 
 #pragma once
 
-#ifndef _
-#ifdef PROTOTYPES
-#define  _(x)  x              /* If compiler knows prototypes */
-#else
-#define  _(x)  ()                     /* It it doesn't */
-#endif /* PROTOTYPES */
-#endif
-
 typedef long bufsize;
-void    bpool        _((void *buffer, bufsize len));
-void   *bget        _((bufsize size));
-void   *bgetz        _((bufsize size));
-void   *bgetr        _((void *buffer, bufsize newsize));
-void    brel        _((void *buf));
-void    bectl        _((int (*compact)(bufsize sizereq, int sequence),
-void *(*acquire)(bufsize size),
-void (*release)(void *buf), bufsize pool_incr));
-void    bstats        _((bufsize *curalloc, bufsize *totfree, bufsize *maxfree,
-long *nget, long *nrel));
-void    bstatse     _((bufsize *pool_incr, long *npool, long *npget,
-long *nprel, long *ndget, long *ndrel));
-void    bufdump     _((void *buf));
-void    bpoold        _((void *pool, int dumpalloc, int dumpfree));
-int    bpoolv        _((void *pool));
+void    bpool        (void *buffer, bufsize len);
+void   *bget        (bufsize size);
+void   *bgetz        (bufsize size);
+void   *bgetr        (void *buffer, bufsize newsize);
+void    brel        (void *buf);
+void    bectl        (int (*compact)(size_t sizereq, int sequence),
+                      void *(*acquire)(size_t size),
+                      void (*release)(void *buf), bufsize pool_incr);
+void    bstats        (bufsize *curalloc, bufsize *totfree, bufsize *maxfree, long *nget, long *nrel);
+void    bstatse     (bufsize *pool_incr, long *npool, long *npget, long *nprel, long *ndget, long *ndrel);
+void    bufdump     (void *buf);
+void    bpoold        (void *pool, int dumpalloc, int dumpfree);
+int    bpoolv        (void *pool);

+ 1 - 1
src/fragroute/fragroute.c

@@ -3,7 +3,7 @@
  *
  * Copyright (c) 2001 Dug Song <dugsong@monkey.org>
  * Copyright (c) 2007-2008 Aaron Turner.
- * Copyright (c) 2013-2024 Fred Klassen - AppNeta
+ * Copyright (c) 2013-2025 Fred Klassen - AppNeta
  * $Id$
  */
 

+ 1 - 1
src/fragroute/fragroute.h

@@ -3,7 +3,7 @@
 /*
  *   Copyright (c) 2001 Dug Song <dugsong@monkey.org>
  *   Copyright (c) 2001-2010 Aaron Turner <aturner at synfin dot net>
- *   Copyright (c) 2013-2024 Fred Klassen <tcpreplay at appneta dot com> - AppNeta
+ *   Copyright (c) 2013-2025 Fred Klassen <tcpreplay at appneta dot com> - AppNeta
  *
  *   The Tcpreplay Suite of tools is free software: you can redistribute it
  *   and/or modify it under the terms of the GNU General Public License as

+ 1 - 1
src/fragroute/mod.c

@@ -8,11 +8,11 @@
  */
 
 #include "mod.h"
+#include "lib/queue.h"
 #include "defines.h"
 #include "config.h"
 #include "common.h"
 #include "argv.h"
-#include "lib/queue.h"
 #include <ctype.h>
 #include <stdio.h>
 #include <stdlib.h>

+ 1 - 1
src/fragroute/pkt.h

@@ -8,9 +8,9 @@
 
 #pragma once
 
+#include "lib/queue.h"
 #include "defines.h"
 #include "config.h"
-#include "lib/queue.h"
 #include <sys/time.h>
 
 #ifdef HAVE_LIBDNET

+ 1 - 1
src/replay.c

@@ -2,7 +2,7 @@
 
 /*
  *   Copyright (c) 2001-2010 Aaron Turner <aturner at synfin dot net>
- *   Copyright (c) 2013-2024 Fred Klassen <tcpreplay at appneta dot com> - AppNeta
+ *   Copyright (c) 2013-2025 Fred Klassen <tcpreplay at appneta dot com> - AppNeta
  *
  *   The Tcpreplay Suite of tools is free software: you can redistribute it
  *   and/or modify it under the terms of the GNU General Public License as

+ 1 - 1
src/replay.h

@@ -2,7 +2,7 @@
 
 /*
  *   Copyright (c) 2001-2010 Aaron Turner <aturner at synfin dot net>
- *   Copyright (c) 2013-2024 Fred Klassen <tcpreplay at appneta dot com> - AppNeta
+ *   Copyright (c) 2013-2025 Fred Klassen <tcpreplay at appneta dot com> - AppNeta
  *
  *   The Tcpreplay Suite of tools is free software: you can redistribute it
  *   and/or modify it under the terms of the GNU General Public License as

+ 1 - 1
src/send_packets.c

@@ -2,7 +2,7 @@
 
 /*
  *   Copyright (c) 2001-2010 Aaron Turner <aturner at synfin dot net>
- *   Copyright (c) 2013-2024 Fred Klassen <tcpreplay at appneta dot com> - AppNeta
+ *   Copyright (c) 2013-2025 Fred Klassen <tcpreplay at appneta dot com> - AppNeta
  *
  *   The Tcpreplay Suite of tools is free software: you can redistribute it
  *   and/or modify it under the terms of the GNU General Public License as

+ 1 - 1
src/send_packets.h

@@ -2,7 +2,7 @@
 
 /*
  *   Copyright (c) 2001-2010 Aaron Turner <aturner at synfin dot net>
- *   Copyright (c) 2013-2024 Fred Klassen <tcpreplay at appneta dot com> - AppNeta
+ *   Copyright (c) 2013-2025 Fred Klassen <tcpreplay at appneta dot com> - AppNeta
  *
  *   The Tcpreplay Suite of tools is free software: you can redistribute it
  *   and/or modify it under the terms of the GNU General Public License as

+ 1 - 1
src/signal_handler.c

@@ -2,7 +2,7 @@
 
 /*
  *   Copyright (c) 2001-2010 Aaron Turner <aturner at synfin dot net>
- *   Copyright (c) 2013-2024 Fred Klassen <tcpreplay at appneta dot com> - AppNeta
+ *   Copyright (c) 2013-2025 Fred Klassen <tcpreplay at appneta dot com> - AppNeta
  *
  *   The Tcpreplay Suite of tools is free software: you can redistribute it
  *   and/or modify it under the terms of the GNU General Public License as

+ 1 - 1
src/signal_handler.h

@@ -2,7 +2,7 @@
 
 /*
  *   Copyright (c) 2001-2010 Aaron Turner <aturner at synfin dot net>
- *   Copyright (c) 2013-2024 Fred Klassen <tcpreplay at appneta dot com> - AppNeta
+ *   Copyright (c) 2013-2025 Fred Klassen <tcpreplay at appneta dot com> - AppNeta
  *
  *   The Tcpreplay Suite of tools is free software: you can redistribute it
  *   and/or modify it under the terms of the GNU General Public License as

+ 1 - 1
src/sleep.c

@@ -1,6 +1,6 @@
 /*
  *   Copyright (c) 2001-2010 Aaron Turner <aturner at synfin dot net>
- *   Copyright (c) 2013-2024 Fred Klassen <tcpreplay at appneta dot com> - AppNeta
+ *   Copyright (c) 2013-2025 Fred Klassen <tcpreplay at appneta dot com> - AppNeta
  *
  *   The Tcpreplay Suite of tools is free software: you can redistribute it
  *   and/or modify it under the terms of the GNU General Public License as

+ 1 - 1
src/sleep.h

@@ -2,7 +2,7 @@
 
 /*
  *   Copyright (c) 2001-2010 Aaron Turner <aturner at synfin dot net>
- *   Copyright (c) 2013-2024 Fred Klassen <tcpreplay at appneta dot com> - AppNeta
+ *   Copyright (c) 2013-2025 Fred Klassen <tcpreplay at appneta dot com> - AppNeta
  *
  *   The Tcpreplay Suite of tools is free software: you can redistribute it
  *   and/or modify it under the terms of the GNU General Public License as

+ 3 - 3
src/tcpbridge.1

@@ -10,7 +10,7 @@
 .ds B-Font B
 .ds I-Font I
 .ds R-Font R
-.TH tcpbridge 1 "12 Jul 2024" "tcpbridge" "User Commands"
+.TH tcpbridge 1 "26 Aug 2025" "tcpbridge" "User Commands"
 .\"
 .\" DO NOT EDIT THIS FILE (in-mem file)
 .\"
@@ -796,13 +796,13 @@ libopts had an internal operational error.  Please report
 it to autogen-users@lists.sourceforge.net.  Thank you.
 .PP
 .SH "AUTHORS"
-Copyright 2013-2024 Fred Klassen \- AppNeta
+Copyright 2013-2025 Fred Klassen \- AppNeta
 Copyright 2000-2012 Aaron Turner
 For support please use the tcpreplay-users@lists.sourceforge.net mailing list.
 The latest version of this software is always available from:
 http://tcpreplay.appneta.com/
 .SH "COPYRIGHT"
-Copyright (C) 2000-2024 Aaron Turner and Fred Klassen all rights reserved.
+Copyright (C) 2000-2025 Aaron Turner and Fred Klassen all rights reserved.
 This program is released under the terms of the GNU General Public License, version 3 or later.
 .SH "BUGS"
 Please send bug reports to: tcpreplay-users@lists.sourceforge.net

+ 1 - 1
src/tcpbridge.c

@@ -2,7 +2,7 @@
 
 /*
  *   Copyright (c) 2001-2010 Aaron Turner <aturner at synfin dot net>
- *   Copyright (c) 2013-2024 Fred Klassen <tcpreplay at appneta dot com> - AppNeta
+ *   Copyright (c) 2013-2025 Fred Klassen <tcpreplay at appneta dot com> - AppNeta
  *
  *   The Tcpreplay Suite of tools is free software: you can redistribute it
  *   and/or modify it under the terms of the GNU General Public License as

+ 1 - 1
src/tcpbridge.h

@@ -2,7 +2,7 @@
 
 /*
  *   Copyright (c) 2001-2010 Aaron Turner <aturner at synfin dot net>
- *   Copyright (c) 2013-2024 Fred Klassen <tcpreplay at appneta dot com> - AppNeta
+ *   Copyright (c) 2013-2025 Fred Klassen <tcpreplay at appneta dot com> - AppNeta
  *
  *   The Tcpreplay Suite of tools is free software: you can redistribute it
  *   and/or modify it under the terms of the GNU General Public License as

+ 4 - 4
src/tcpbridge_opts.c

@@ -19,7 +19,7 @@
  * The tcpbridge program is copyrighted and licensed
  * under the following terms:
  *
- *  Copyright (C) 2000-2024 Aaron Turner and Fred Klassen, all rights reserved.
+ *  Copyright (C) 2000-2025 Aaron Turner and Fred Klassen, all rights reserved.
  *  This is free software. It is licensed for use, modification and
  *  redistribution under the terms of the GNU General Public License,
  *  version 3 or later <http://gnu.org/licenses/gpl.html>
@@ -82,7 +82,7 @@ extern tcpbridge_opt_t options;
  */
 static char const tcpbridge_opt_strs[4731] =
 /*     0 */ "tcpbridge (tcpbridge)\n"
-            "Copyright (C) 2000-2024 Aaron Turner and Fred Klassen, all rights reserved.\n"
+            "Copyright (C) 2000-2025 Aaron Turner and Fred Klassen, all rights reserved.\n"
             "This is free software. It is licensed for use, modification and\n"
             "redistribution under the terms of the GNU General Public License,\n"
             "version 3 or later <http://gnu.org/licenses/gpl.html>\n\0"
@@ -2494,7 +2494,7 @@ doOptVersion(tOptions* pOptions, tOptDesc* pOptDesc)
     fprintf(stderr, " (debug)");
 #endif
     fprintf(stderr, "\n");
-    fprintf(stderr, "Copyright 2013-2024 by Fred Klassen <tcpreplay at appneta dot com> - AppNeta\n");
+    fprintf(stderr, "Copyright 2013-2025 by Fred Klassen <tcpreplay at appneta dot com> - AppNeta\n");
     fprintf(stderr, "Copyright 2000-2012 by Aaron Turner <aturner at synfin dot net>\n");
     fprintf(stderr, "The entire Tcpreplay Suite is licensed under the GPLv3\n");
 #ifdef HAVE_LIBDNET
@@ -2749,7 +2749,7 @@ static void bogus_function(void) {
    */
   /* referenced via tcpbridgeOptions.pzCopyright */
   puts(_("tcpbridge (tcpbridge)\n\
-Copyright (C) 2000-2024 Aaron Turner and Fred Klassen, all rights reserved.\n\
+Copyright (C) 2000-2025 Aaron Turner and Fred Klassen, all rights reserved.\n\
 This is free software. It is licensed for use, modification and\n\
 redistribution under the terms of the GNU General Public License,\n\
 version 3 or later <http://gnu.org/licenses/gpl.html>\n"));

+ 4 - 4
src/tcpbridge_opts.def

@@ -2,7 +2,7 @@
 
 /*
  *   Copyright (c) 2001-2010 Aaron Turner <aturner at synfin dot net>
- *   Copyright (c) 2013-2024 Fred Klassen <tcpreplay at appneta dot com> - AppNeta
+ *   Copyright (c) 2013-2025 Fred Klassen <tcpreplay at appneta dot com> - AppNeta
  *
  *   The Tcpreplay Suite of tools is free software: you can redistribute it
  *   and/or modify it under the terms of the GNU General Public License as
@@ -23,12 +23,12 @@ autogen definitions options;
 
 
 copyright = {
-    date        = "2000-2024";
+    date        = "2000-2025";
     owner       = "Aaron Turner and Fred Klassen";
     eaddr       = "tcpreplay-users@lists.sourceforge.net";
     type        = gpl;
     author      = <<- EOText
-Copyright 2013-2024 Fred Klassen - AppNeta
+Copyright 2013-2025 Fred Klassen - AppNeta
 
 Copyright 2000-2012 Aaron Turner
 
@@ -366,7 +366,7 @@ flag = {
     fprintf(stderr, " (debug)");
 #endif
     fprintf(stderr, "\n");
-    fprintf(stderr, "Copyright 2013-2024 by Fred Klassen <tcpreplay at appneta dot com> - AppNeta\n");
+    fprintf(stderr, "Copyright 2013-2025 by Fred Klassen <tcpreplay at appneta dot com> - AppNeta\n");
     fprintf(stderr, "Copyright 2000-2012 by Aaron Turner <aturner at synfin dot net>\n");
     fprintf(stderr, "The entire Tcpreplay Suite is licensed under the GPLv3\n");
 #ifdef HAVE_LIBDNET

+ 1 - 1
src/tcpbridge_opts.h

@@ -19,7 +19,7 @@
  * The tcpbridge program is copyrighted and licensed
  * under the following terms:
  *
- *  Copyright (C) 2000-2024 Aaron Turner and Fred Klassen, all rights reserved.
+ *  Copyright (C) 2000-2025 Aaron Turner and Fred Klassen, all rights reserved.
  *  This is free software. It is licensed for use, modification and
  *  redistribution under the terms of the GNU General Public License,
  *  version 3 or later <http://gnu.org/licenses/gpl.html>

+ 1 - 1
src/tcpcapinfo.1

@@ -10,7 +10,7 @@
 .ds B-Font B
 .ds I-Font I
 .ds R-Font R
-.TH tcpcapinfo 1 "12 Jul 2024" "Tcpreplay Suite" "User Commands"
+.TH tcpcapinfo 1 "26 Aug 2025" "Tcpreplay Suite" "User Commands"
 .\"
 .\" DO NOT EDIT THIS FILE (in-mem file)
 .\"

+ 1 - 1
src/tcpcapinfo.c

@@ -2,7 +2,7 @@
 
 /*
  *   Copyright (c) 2001-2012 Aaron Turner <aturner at synfin dot net>
- *   Copyright (c) 2013-2024 Fred Klassen <tcpreplay at appneta dot com> - AppNeta
+ *   Copyright (c) 2013-2025 Fred Klassen <tcpreplay at appneta dot com> - AppNeta
  *
  *   The Tcpreplay Suite of tools is free software: you can redistribute it
  *   and/or modify it under the terms of the GNU General Public License as

+ 1 - 1
src/tcpcapinfo_opts.c

@@ -349,7 +349,7 @@ doOptVersion(tOptions* pOptions, tOptDesc* pOptDesc)
     fprintf(stderr, " (debug)");
 #endif
     fprintf(stderr, "\n");
-    fprintf(stderr, "Copyright 2013-2024 by Fred Klassen <tcpreplay at appneta dot com> - AppNeta\n");
+    fprintf(stderr, "Copyright 2013-2025 by Fred Klassen <tcpreplay at appneta dot com> - AppNeta\n");
     fprintf(stderr, "Copyright 2000-2010 by Aaron Turner <aturner at synfin dot net>\n");
     fprintf(stderr, "The entire Tcpreplay Suite is licensed under the GPLv3\n");
     exit(0);

+ 2 - 2
src/tcpcapinfo_opts.def

@@ -2,7 +2,7 @@
 
 /*
  *   Copyright (c) 2001-2010 Aaron Turner <aturner at synfin dot net>
- *   Copyright (c) 2013-2024 Fred Klassen <tcpreplay at appneta dot com> - AppNeta
+ *   Copyright (c) 2013-2025 Fred Klassen <tcpreplay at appneta dot com> - AppNeta
  *
  *   The Tcpreplay Suite of tools is free software: you can redistribute it 
  *   and/or modify it under the terms of the GNU General Public License as 
@@ -102,7 +102,7 @@ flag = {
     fprintf(stderr, " (debug)");
 #endif
     fprintf(stderr, "\n");
-    fprintf(stderr, "Copyright 2013-2024 by Fred Klassen <tcpreplay at appneta dot com> - AppNeta\n");
+    fprintf(stderr, "Copyright 2013-2025 by Fred Klassen <tcpreplay at appneta dot com> - AppNeta\n");
     fprintf(stderr, "Copyright 2000-2010 by Aaron Turner <aturner at synfin dot net>\n");
     fprintf(stderr, "The entire Tcpreplay Suite is licensed under the GPLv3\n");
     exit(0);

+ 82 - 68
src/tcpedit/Makefile.in

@@ -1,7 +1,7 @@
-# Makefile.in generated by automake 1.16.3 from Makefile.am.
+# Makefile.in generated by automake 1.17 from Makefile.am.
 # @configure_input@
 
-# Copyright (C) 1994-2020 Free Software Foundation, Inc.
+# Copyright (C) 1994-2024 Free Software Foundation, Inc.
 
 # This Makefile.in is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -172,6 +172,8 @@ am__make_running_with_option = \
   test $$has_opt = yes
 am__make_dryrun = (target_option=n; $(am__make_running_with_option))
 am__make_keepgoing = (target_option=k; $(am__make_running_with_option))
+am__rm_f = rm -f $(am__rm_f_notfound)
+am__rm_rf = rm -rf $(am__rm_f_notfound)
 pkgdatadir = $(datadir)/@PACKAGE@
 pkgincludedir = $(includedir)/@PACKAGE@
 pkglibdir = $(libdir)/@PACKAGE@
@@ -208,12 +210,13 @@ CONFIG_HEADER = $(top_builddir)/src/config.h
 CONFIG_CLEAN_FILES =
 CONFIG_CLEAN_VPATH_FILES =
 LIBRARIES = $(noinst_LIBRARIES)
-ARFLAGS = cru
+ARFLAGS = cr
 AM_V_AR = $(am__v_AR_@AM_V@)
 am__v_AR_ = $(am__v_AR_@AM_DEFAULT_V@)
 am__v_AR_0 = @echo "  AR      " $@;
 am__v_AR_1 = 
 libtcpedit_a_AR = $(AR) $(ARFLAGS)
+libtcpedit_a_RANLIB = $(RANLIB)
 libtcpedit_a_LIBADD =
 am__dirstamp = $(am__leading_dot)dirstamp
 am_libtcpedit_a_OBJECTS = tcpedit.$(OBJEXT) parse_args.$(OBJEXT) \
@@ -324,8 +327,6 @@ am__define_uniq_tagged_files = \
   unique=`for i in $$list; do \
     if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
   done | $(am__uniquify_input)`
-ETAGS = etags
-CTAGS = ctags
 am__DIST_COMMON = $(srcdir)/Makefile.in $(srcdir)/plugins/Makefile.am \
 	$(srcdir)/plugins/dlt_en10mb/Makefile.am \
 	$(srcdir)/plugins/dlt_hdlc/Makefile.am \
@@ -357,6 +358,8 @@ CPP = @CPP@
 CPPFLAGS = @CPPFLAGS@
 CROSS_ARCH = @CROSS_ARCH@
 CROSS_LD = @CROSS_LD@
+CSCOPE = @CSCOPE@
+CTAGS = @CTAGS@
 CUT = @CUT@
 CXX = @CXX@
 CXXCPP = @CXXCPP@
@@ -374,8 +377,10 @@ ECHO_C = @ECHO_C@
 ECHO_N = @ECHO_N@
 ECHO_T = @ECHO_T@
 EGREP = @EGREP@
+ETAGS = @ETAGS@
 EXEEXT = @EXEEXT@
 FGREP = @FGREP@
+FILECMD = @FILECMD@
 GREP = @GREP@
 GROFF = @GROFF@
 INSTALL = @INSTALL@
@@ -448,8 +453,10 @@ ac_ct_DUMPBIN = @ac_ct_DUMPBIN@
 am__include = @am__include@
 am__leading_dot = @am__leading_dot@
 am__quote = @am__quote@
+am__rm_f_notfound = @am__rm_f_notfound@
 am__tar = @am__tar@
 am__untar = @am__untar@
+am__xargs_n = @am__xargs_n@
 bindir = @bindir@
 build = @build@
 build_alias = @build_alias@
@@ -504,6 +511,7 @@ target_cpu = @target_cpu@
 target_os = @target_os@
 target_vendor = @target_vendor@
 tcpdump_path = @tcpdump_path@
+test_hexdump = @test_hexdump@
 timestamp_trace_flag = @timestamp_trace_flag@
 top_build_prefix = @top_build_prefix@
 top_builddir = @top_builddir@
@@ -651,13 +659,13 @@ $(ACLOCAL_M4): @MAINTAINER_MODE_TRUE@ $(am__aclocal_m4_deps)
 $(am__aclocal_m4_deps):
 
 clean-noinstLIBRARIES:
-	-test -z "$(noinst_LIBRARIES)" || rm -f $(noinst_LIBRARIES)
+	-$(am__rm_f) $(noinst_LIBRARIES)
 plugins/$(am__dirstamp):
 	@$(MKDIR_P) plugins
-	@: > plugins/$(am__dirstamp)
+	@: >>plugins/$(am__dirstamp)
 plugins/$(DEPDIR)/$(am__dirstamp):
 	@$(MKDIR_P) plugins/$(DEPDIR)
-	@: > plugins/$(DEPDIR)/$(am__dirstamp)
+	@: >>plugins/$(DEPDIR)/$(am__dirstamp)
 plugins/dlt_plugins.$(OBJEXT): plugins/$(am__dirstamp) \
 	plugins/$(DEPDIR)/$(am__dirstamp)
 plugins/ethernet.$(OBJEXT): plugins/$(am__dirstamp) \
@@ -666,10 +674,10 @@ plugins/dlt_utils.$(OBJEXT): plugins/$(am__dirstamp) \
 	plugins/$(DEPDIR)/$(am__dirstamp)
 plugins/dlt_en10mb/$(am__dirstamp):
 	@$(MKDIR_P) plugins/dlt_en10mb
-	@: > plugins/dlt_en10mb/$(am__dirstamp)
+	@: >>plugins/dlt_en10mb/$(am__dirstamp)
 plugins/dlt_en10mb/$(DEPDIR)/$(am__dirstamp):
 	@$(MKDIR_P) plugins/dlt_en10mb/$(DEPDIR)
-	@: > plugins/dlt_en10mb/$(DEPDIR)/$(am__dirstamp)
+	@: >>plugins/dlt_en10mb/$(DEPDIR)/$(am__dirstamp)
 plugins/dlt_en10mb/en10mb.$(OBJEXT):  \
 	plugins/dlt_en10mb/$(am__dirstamp) \
 	plugins/dlt_en10mb/$(DEPDIR)/$(am__dirstamp)
@@ -678,72 +686,72 @@ plugins/dlt_en10mb/en10mb_api.$(OBJEXT):  \
 	plugins/dlt_en10mb/$(DEPDIR)/$(am__dirstamp)
 plugins/dlt_hdlc/$(am__dirstamp):
 	@$(MKDIR_P) plugins/dlt_hdlc
-	@: > plugins/dlt_hdlc/$(am__dirstamp)
+	@: >>plugins/dlt_hdlc/$(am__dirstamp)
 plugins/dlt_hdlc/$(DEPDIR)/$(am__dirstamp):
 	@$(MKDIR_P) plugins/dlt_hdlc/$(DEPDIR)
-	@: > plugins/dlt_hdlc/$(DEPDIR)/$(am__dirstamp)
+	@: >>plugins/dlt_hdlc/$(DEPDIR)/$(am__dirstamp)
 plugins/dlt_hdlc/hdlc.$(OBJEXT): plugins/dlt_hdlc/$(am__dirstamp) \
 	plugins/dlt_hdlc/$(DEPDIR)/$(am__dirstamp)
 plugins/dlt_hdlc/hdlc_api.$(OBJEXT): plugins/dlt_hdlc/$(am__dirstamp) \
 	plugins/dlt_hdlc/$(DEPDIR)/$(am__dirstamp)
 plugins/dlt_user/$(am__dirstamp):
 	@$(MKDIR_P) plugins/dlt_user
-	@: > plugins/dlt_user/$(am__dirstamp)
+	@: >>plugins/dlt_user/$(am__dirstamp)
 plugins/dlt_user/$(DEPDIR)/$(am__dirstamp):
 	@$(MKDIR_P) plugins/dlt_user/$(DEPDIR)
-	@: > plugins/dlt_user/$(DEPDIR)/$(am__dirstamp)
+	@: >>plugins/dlt_user/$(DEPDIR)/$(am__dirstamp)
 plugins/dlt_user/user.$(OBJEXT): plugins/dlt_user/$(am__dirstamp) \
 	plugins/dlt_user/$(DEPDIR)/$(am__dirstamp)
 plugins/dlt_user/user_api.$(OBJEXT): plugins/dlt_user/$(am__dirstamp) \
 	plugins/dlt_user/$(DEPDIR)/$(am__dirstamp)
 plugins/dlt_raw/$(am__dirstamp):
 	@$(MKDIR_P) plugins/dlt_raw
-	@: > plugins/dlt_raw/$(am__dirstamp)
+	@: >>plugins/dlt_raw/$(am__dirstamp)
 plugins/dlt_raw/$(DEPDIR)/$(am__dirstamp):
 	@$(MKDIR_P) plugins/dlt_raw/$(DEPDIR)
-	@: > plugins/dlt_raw/$(DEPDIR)/$(am__dirstamp)
+	@: >>plugins/dlt_raw/$(DEPDIR)/$(am__dirstamp)
 plugins/dlt_raw/raw.$(OBJEXT): plugins/dlt_raw/$(am__dirstamp) \
 	plugins/dlt_raw/$(DEPDIR)/$(am__dirstamp)
 plugins/dlt_null/$(am__dirstamp):
 	@$(MKDIR_P) plugins/dlt_null
-	@: > plugins/dlt_null/$(am__dirstamp)
+	@: >>plugins/dlt_null/$(am__dirstamp)
 plugins/dlt_null/$(DEPDIR)/$(am__dirstamp):
 	@$(MKDIR_P) plugins/dlt_null/$(DEPDIR)
-	@: > plugins/dlt_null/$(DEPDIR)/$(am__dirstamp)
+	@: >>plugins/dlt_null/$(DEPDIR)/$(am__dirstamp)
 plugins/dlt_null/null.$(OBJEXT): plugins/dlt_null/$(am__dirstamp) \
 	plugins/dlt_null/$(DEPDIR)/$(am__dirstamp)
 plugins/dlt_loop/$(am__dirstamp):
 	@$(MKDIR_P) plugins/dlt_loop
-	@: > plugins/dlt_loop/$(am__dirstamp)
+	@: >>plugins/dlt_loop/$(am__dirstamp)
 plugins/dlt_loop/$(DEPDIR)/$(am__dirstamp):
 	@$(MKDIR_P) plugins/dlt_loop/$(DEPDIR)
-	@: > plugins/dlt_loop/$(DEPDIR)/$(am__dirstamp)
+	@: >>plugins/dlt_loop/$(DEPDIR)/$(am__dirstamp)
 plugins/dlt_loop/loop.$(OBJEXT): plugins/dlt_loop/$(am__dirstamp) \
 	plugins/dlt_loop/$(DEPDIR)/$(am__dirstamp)
 plugins/dlt_linuxsll/$(am__dirstamp):
 	@$(MKDIR_P) plugins/dlt_linuxsll
-	@: > plugins/dlt_linuxsll/$(am__dirstamp)
+	@: >>plugins/dlt_linuxsll/$(am__dirstamp)
 plugins/dlt_linuxsll/$(DEPDIR)/$(am__dirstamp):
 	@$(MKDIR_P) plugins/dlt_linuxsll/$(DEPDIR)
-	@: > plugins/dlt_linuxsll/$(DEPDIR)/$(am__dirstamp)
+	@: >>plugins/dlt_linuxsll/$(DEPDIR)/$(am__dirstamp)
 plugins/dlt_linuxsll/linuxsll.$(OBJEXT):  \
 	plugins/dlt_linuxsll/$(am__dirstamp) \
 	plugins/dlt_linuxsll/$(DEPDIR)/$(am__dirstamp)
 plugins/dlt_linuxsll2/$(am__dirstamp):
 	@$(MKDIR_P) plugins/dlt_linuxsll2
-	@: > plugins/dlt_linuxsll2/$(am__dirstamp)
+	@: >>plugins/dlt_linuxsll2/$(am__dirstamp)
 plugins/dlt_linuxsll2/$(DEPDIR)/$(am__dirstamp):
 	@$(MKDIR_P) plugins/dlt_linuxsll2/$(DEPDIR)
-	@: > plugins/dlt_linuxsll2/$(DEPDIR)/$(am__dirstamp)
+	@: >>plugins/dlt_linuxsll2/$(DEPDIR)/$(am__dirstamp)
 plugins/dlt_linuxsll2/linuxsll2.$(OBJEXT):  \
 	plugins/dlt_linuxsll2/$(am__dirstamp) \
 	plugins/dlt_linuxsll2/$(DEPDIR)/$(am__dirstamp)
 plugins/dlt_ieee80211/$(am__dirstamp):
 	@$(MKDIR_P) plugins/dlt_ieee80211
-	@: > plugins/dlt_ieee80211/$(am__dirstamp)
+	@: >>plugins/dlt_ieee80211/$(am__dirstamp)
 plugins/dlt_ieee80211/$(DEPDIR)/$(am__dirstamp):
 	@$(MKDIR_P) plugins/dlt_ieee80211/$(DEPDIR)
-	@: > plugins/dlt_ieee80211/$(DEPDIR)/$(am__dirstamp)
+	@: >>plugins/dlt_ieee80211/$(DEPDIR)/$(am__dirstamp)
 plugins/dlt_ieee80211/ieee80211.$(OBJEXT):  \
 	plugins/dlt_ieee80211/$(am__dirstamp) \
 	plugins/dlt_ieee80211/$(DEPDIR)/$(am__dirstamp)
@@ -752,28 +760,28 @@ plugins/dlt_ieee80211/ieee80211_hdr.$(OBJEXT):  \
 	plugins/dlt_ieee80211/$(DEPDIR)/$(am__dirstamp)
 plugins/dlt_radiotap/$(am__dirstamp):
 	@$(MKDIR_P) plugins/dlt_radiotap
-	@: > plugins/dlt_radiotap/$(am__dirstamp)
+	@: >>plugins/dlt_radiotap/$(am__dirstamp)
 plugins/dlt_radiotap/$(DEPDIR)/$(am__dirstamp):
 	@$(MKDIR_P) plugins/dlt_radiotap/$(DEPDIR)
-	@: > plugins/dlt_radiotap/$(DEPDIR)/$(am__dirstamp)
+	@: >>plugins/dlt_radiotap/$(DEPDIR)/$(am__dirstamp)
 plugins/dlt_radiotap/radiotap.$(OBJEXT):  \
 	plugins/dlt_radiotap/$(am__dirstamp) \
 	plugins/dlt_radiotap/$(DEPDIR)/$(am__dirstamp)
 plugins/dlt_jnpr_ether/$(am__dirstamp):
 	@$(MKDIR_P) plugins/dlt_jnpr_ether
-	@: > plugins/dlt_jnpr_ether/$(am__dirstamp)
+	@: >>plugins/dlt_jnpr_ether/$(am__dirstamp)
 plugins/dlt_jnpr_ether/$(DEPDIR)/$(am__dirstamp):
 	@$(MKDIR_P) plugins/dlt_jnpr_ether/$(DEPDIR)
-	@: > plugins/dlt_jnpr_ether/$(DEPDIR)/$(am__dirstamp)
+	@: >>plugins/dlt_jnpr_ether/$(DEPDIR)/$(am__dirstamp)
 plugins/dlt_jnpr_ether/jnpr_ether.$(OBJEXT):  \
 	plugins/dlt_jnpr_ether/$(am__dirstamp) \
 	plugins/dlt_jnpr_ether/$(DEPDIR)/$(am__dirstamp)
 plugins/dlt_pppserial/$(am__dirstamp):
 	@$(MKDIR_P) plugins/dlt_pppserial
-	@: > plugins/dlt_pppserial/$(am__dirstamp)
+	@: >>plugins/dlt_pppserial/$(am__dirstamp)
 plugins/dlt_pppserial/$(DEPDIR)/$(am__dirstamp):
 	@$(MKDIR_P) plugins/dlt_pppserial/$(DEPDIR)
-	@: > plugins/dlt_pppserial/$(DEPDIR)/$(am__dirstamp)
+	@: >>plugins/dlt_pppserial/$(DEPDIR)/$(am__dirstamp)
 plugins/dlt_pppserial/pppserial.$(OBJEXT):  \
 	plugins/dlt_pppserial/$(am__dirstamp) \
 	plugins/dlt_pppserial/$(DEPDIR)/$(am__dirstamp)
@@ -781,7 +789,7 @@ plugins/dlt_pppserial/pppserial.$(OBJEXT):  \
 libtcpedit.a: $(libtcpedit_a_OBJECTS) $(libtcpedit_a_DEPENDENCIES) $(EXTRA_libtcpedit_a_DEPENDENCIES) 
 	$(AM_V_at)-rm -f libtcpedit.a
 	$(AM_V_AR)$(libtcpedit_a_AR) libtcpedit.a $(libtcpedit_a_OBJECTS) $(libtcpedit_a_LIBADD)
-	$(AM_V_at)$(RANLIB) libtcpedit.a
+	$(AM_V_at)$(libtcpedit_a_RANLIB) libtcpedit.a
 
 mostlyclean-compile:
 	-rm -f *.$(OBJEXT)
@@ -834,7 +842,7 @@ distclean-compile:
 
 $(am__depfiles_remade):
 	@$(MKDIR_P) $(@D)
-	@echo '# dummy' >$@-t && $(am__mv) $@-t $@
+	@: >>$@
 
 am--depfiles: $(am__depfiles_remade)
 
@@ -919,7 +927,6 @@ cscopelist-am: $(am__tagged_files)
 
 distclean-tags:
 	-rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
-
 distdir: $(BUILT_SOURCES)
 	$(MAKE) $(AM_MAKEFLAGS) distdir-am
 
@@ -980,52 +987,52 @@ install-strip:
 	    "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \
 	fi
 mostlyclean-generic:
-	-test -z "$(MOSTLYCLEANFILES)" || rm -f $(MOSTLYCLEANFILES)
+	-$(am__rm_f) $(MOSTLYCLEANFILES)
 
 clean-generic:
 
 distclean-generic:
-	-test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
-	-test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES)
-	-rm -f plugins/$(DEPDIR)/$(am__dirstamp)
-	-rm -f plugins/$(am__dirstamp)
-	-rm -f plugins/dlt_en10mb/$(DEPDIR)/$(am__dirstamp)
-	-rm -f plugins/dlt_en10mb/$(am__dirstamp)
-	-rm -f plugins/dlt_hdlc/$(DEPDIR)/$(am__dirstamp)
-	-rm -f plugins/dlt_hdlc/$(am__dirstamp)
-	-rm -f plugins/dlt_ieee80211/$(DEPDIR)/$(am__dirstamp)
-	-rm -f plugins/dlt_ieee80211/$(am__dirstamp)
-	-rm -f plugins/dlt_jnpr_ether/$(DEPDIR)/$(am__dirstamp)
-	-rm -f plugins/dlt_jnpr_ether/$(am__dirstamp)
-	-rm -f plugins/dlt_linuxsll/$(DEPDIR)/$(am__dirstamp)
-	-rm -f plugins/dlt_linuxsll/$(am__dirstamp)
-	-rm -f plugins/dlt_linuxsll2/$(DEPDIR)/$(am__dirstamp)
-	-rm -f plugins/dlt_linuxsll2/$(am__dirstamp)
-	-rm -f plugins/dlt_loop/$(DEPDIR)/$(am__dirstamp)
-	-rm -f plugins/dlt_loop/$(am__dirstamp)
-	-rm -f plugins/dlt_null/$(DEPDIR)/$(am__dirstamp)
-	-rm -f plugins/dlt_null/$(am__dirstamp)
-	-rm -f plugins/dlt_pppserial/$(DEPDIR)/$(am__dirstamp)
-	-rm -f plugins/dlt_pppserial/$(am__dirstamp)
-	-rm -f plugins/dlt_radiotap/$(DEPDIR)/$(am__dirstamp)
-	-rm -f plugins/dlt_radiotap/$(am__dirstamp)
-	-rm -f plugins/dlt_raw/$(DEPDIR)/$(am__dirstamp)
-	-rm -f plugins/dlt_raw/$(am__dirstamp)
-	-rm -f plugins/dlt_user/$(DEPDIR)/$(am__dirstamp)
-	-rm -f plugins/dlt_user/$(am__dirstamp)
+	-$(am__rm_f) $(CONFIG_CLEAN_FILES)
+	-test . = "$(srcdir)" || $(am__rm_f) $(CONFIG_CLEAN_VPATH_FILES)
+	-$(am__rm_f) plugins/$(DEPDIR)/$(am__dirstamp)
+	-$(am__rm_f) plugins/$(am__dirstamp)
+	-$(am__rm_f) plugins/dlt_en10mb/$(DEPDIR)/$(am__dirstamp)
+	-$(am__rm_f) plugins/dlt_en10mb/$(am__dirstamp)
+	-$(am__rm_f) plugins/dlt_hdlc/$(DEPDIR)/$(am__dirstamp)
+	-$(am__rm_f) plugins/dlt_hdlc/$(am__dirstamp)
+	-$(am__rm_f) plugins/dlt_ieee80211/$(DEPDIR)/$(am__dirstamp)
+	-$(am__rm_f) plugins/dlt_ieee80211/$(am__dirstamp)
+	-$(am__rm_f) plugins/dlt_jnpr_ether/$(DEPDIR)/$(am__dirstamp)
+	-$(am__rm_f) plugins/dlt_jnpr_ether/$(am__dirstamp)
+	-$(am__rm_f) plugins/dlt_linuxsll/$(DEPDIR)/$(am__dirstamp)
+	-$(am__rm_f) plugins/dlt_linuxsll/$(am__dirstamp)
+	-$(am__rm_f) plugins/dlt_linuxsll2/$(DEPDIR)/$(am__dirstamp)
+	-$(am__rm_f) plugins/dlt_linuxsll2/$(am__dirstamp)
+	-$(am__rm_f) plugins/dlt_loop/$(DEPDIR)/$(am__dirstamp)
+	-$(am__rm_f) plugins/dlt_loop/$(am__dirstamp)
+	-$(am__rm_f) plugins/dlt_null/$(DEPDIR)/$(am__dirstamp)
+	-$(am__rm_f) plugins/dlt_null/$(am__dirstamp)
+	-$(am__rm_f) plugins/dlt_pppserial/$(DEPDIR)/$(am__dirstamp)
+	-$(am__rm_f) plugins/dlt_pppserial/$(am__dirstamp)
+	-$(am__rm_f) plugins/dlt_radiotap/$(DEPDIR)/$(am__dirstamp)
+	-$(am__rm_f) plugins/dlt_radiotap/$(am__dirstamp)
+	-$(am__rm_f) plugins/dlt_raw/$(DEPDIR)/$(am__dirstamp)
+	-$(am__rm_f) plugins/dlt_raw/$(am__dirstamp)
+	-$(am__rm_f) plugins/dlt_user/$(DEPDIR)/$(am__dirstamp)
+	-$(am__rm_f) plugins/dlt_user/$(am__dirstamp)
 
 maintainer-clean-generic:
 	@echo "This command is intended for maintainers to use"
 	@echo "it deletes files that may require special tools to rebuild."
-	-test -z "$(BUILT_SOURCES)" || rm -f $(BUILT_SOURCES)
-	-test -z "$(MAINTAINERCLEANFILES)" || rm -f $(MAINTAINERCLEANFILES)
+	-$(am__rm_f) $(BUILT_SOURCES)
+	-$(am__rm_f) $(MAINTAINERCLEANFILES)
 clean: clean-am
 
 clean-am: clean-generic clean-libtool clean-noinstLIBRARIES \
 	mostlyclean-am
 
 distclean: distclean-am
-		-rm -f ./$(DEPDIR)/checksum.Po
+	-rm -f ./$(DEPDIR)/checksum.Po
 	-rm -f ./$(DEPDIR)/dlt.Po
 	-rm -f ./$(DEPDIR)/edit_packet.Po
 	-rm -f ./$(DEPDIR)/fuzzing.Po
@@ -1099,7 +1106,7 @@ install-ps-am:
 installcheck-am:
 
 maintainer-clean: maintainer-clean-am
-		-rm -f ./$(DEPDIR)/checksum.Po
+	-rm -f ./$(DEPDIR)/checksum.Po
 	-rm -f ./$(DEPDIR)/dlt.Po
 	-rm -f ./$(DEPDIR)/edit_packet.Po
 	-rm -f ./$(DEPDIR)/fuzzing.Po
@@ -1287,3 +1294,10 @@ pppserial.c: \
 # Tell versions [3.59,3.63) of GNU make to not export all variables.
 # Otherwise a system limit (for SysV at least) may be exceeded.
 .NOEXPORT:
+
+# Tell GNU make to disable its built-in pattern rules.
+%:: %,v
+%:: RCS/%,v
+%:: RCS/%
+%:: s.%
+%:: SCCS/s.%

+ 3 - 1
src/tcpedit/checksum.c

@@ -2,7 +2,7 @@
 
 /*
  *   Copyright (c) 2001-2010 Aaron Turner <aturner at synfin dot net>
- *   Copyright (c) 2013-2024 Fred Klassen <tcpreplay at appneta dot com> - AppNeta
+ *   Copyright (c) 2013-2025 Fred Klassen <tcpreplay at appneta dot com> - AppNeta
  *
  *   The Tcpreplay Suite of tools is free software: you can redistribute it
  *   and/or modify it under the terms of the GNU General Public License as
@@ -78,6 +78,7 @@ do_checksum(tcpedit_t *tcpedit, uint8_t *data, int proto, int len, const u_char
 
     switch (proto) {
     case IPPROTO_TCP:
+    case IPPROTO_TCP_V6FRAG:
         if (len < (int)sizeof(tcp_hdr_t)) {
             tcpedit_setwarn(tcpedit, "%s", "Unable to checksum TCP with insufficient L4 data");
             return TCPEDIT_WARN;
@@ -98,6 +99,7 @@ do_checksum(tcpedit_t *tcpedit, uint8_t *data, int proto, int len, const u_char
         } else {
             sum = do_checksum_math((uint16_t *)&ipv4->ip_src, 8);
         }
+
         sum += ntohs(IPPROTO_TCP + len);
         sum += do_checksum_math((uint16_t *)tcp, len);
         tcp->th_sum = CHECKSUM_CARRY(sum);

+ 0 - 0
src/tcpedit/checksum.h


Some files were not shown because too many files changed in this diff