Makefile.in 40 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027
  1. # Makefile.in generated by automake 1.14.1 from Makefile.am.
  2. # @configure_input@
  3. # Copyright (C) 1994-2013 Free Software Foundation, Inc.
  4. # This Makefile.in is free software; the Free Software Foundation
  5. # gives unlimited permission to copy and/or distribute it,
  6. # with or without modifications, as long as this notice is preserved.
  7. # This program is distributed in the hope that it will be useful,
  8. # but WITHOUT ANY WARRANTY, to the extent permitted by law; without
  9. # even the implied warranty of MERCHANTABILITY or FITNESS FOR A
  10. # PARTICULAR PURPOSE.
  11. @SET_MAKE@
  12. VPATH = @srcdir@
  13. am__is_gnu_make = test -n '$(MAKEFILE_LIST)' && test -n '$(MAKELEVEL)'
  14. am__make_running_with_option = \
  15. case $${target_option-} in \
  16. ?) ;; \
  17. *) echo "am__make_running_with_option: internal error: invalid" \
  18. "target option '$${target_option-}' specified" >&2; \
  19. exit 1;; \
  20. esac; \
  21. has_opt=no; \
  22. sane_makeflags=$$MAKEFLAGS; \
  23. if $(am__is_gnu_make); then \
  24. sane_makeflags=$$MFLAGS; \
  25. else \
  26. case $$MAKEFLAGS in \
  27. *\\[\ \ ]*) \
  28. bs=\\; \
  29. sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \
  30. | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \
  31. esac; \
  32. fi; \
  33. skip_next=no; \
  34. strip_trailopt () \
  35. { \
  36. flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \
  37. }; \
  38. for flg in $$sane_makeflags; do \
  39. test $$skip_next = yes && { skip_next=no; continue; }; \
  40. case $$flg in \
  41. *=*|--*) continue;; \
  42. -*I) strip_trailopt 'I'; skip_next=yes;; \
  43. -*I?*) strip_trailopt 'I';; \
  44. -*O) strip_trailopt 'O'; skip_next=yes;; \
  45. -*O?*) strip_trailopt 'O';; \
  46. -*l) strip_trailopt 'l'; skip_next=yes;; \
  47. -*l?*) strip_trailopt 'l';; \
  48. -[dEDm]) skip_next=yes;; \
  49. -[JT]) skip_next=yes;; \
  50. esac; \
  51. case $$flg in \
  52. *$$target_option*) has_opt=yes; break;; \
  53. esac; \
  54. done; \
  55. test $$has_opt = yes
  56. am__make_dryrun = (target_option=n; $(am__make_running_with_option))
  57. am__make_keepgoing = (target_option=k; $(am__make_running_with_option))
  58. pkgdatadir = $(datadir)/@PACKAGE@
  59. pkgincludedir = $(includedir)/@PACKAGE@
  60. pkglibdir = $(libdir)/@PACKAGE@
  61. pkglibexecdir = $(libexecdir)/@PACKAGE@
  62. am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
  63. install_sh_DATA = $(install_sh) -c -m 644
  64. install_sh_PROGRAM = $(install_sh) -c
  65. install_sh_SCRIPT = $(install_sh) -c
  66. INSTALL_HEADER = $(INSTALL_DATA)
  67. transform = $(program_transform_name)
  68. NORMAL_INSTALL = :
  69. PRE_INSTALL = :
  70. POST_INSTALL = :
  71. NORMAL_UNINSTALL = :
  72. PRE_UNINSTALL = :
  73. POST_UNINSTALL = :
  74. build_triplet = @build@
  75. host_triplet = @host@
  76. target_triplet = @target@
  77. subdir = test
  78. DIST_COMMON = $(srcdir)/Makefile.in $(srcdir)/Makefile.am \
  79. $(srcdir)/config.in
  80. ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
  81. am__aclocal_m4_deps = $(top_srcdir)/m4/libtool.m4 \
  82. $(top_srcdir)/m4/ltoptions.m4 $(top_srcdir)/m4/ltsugar.m4 \
  83. $(top_srcdir)/m4/ltversion.m4 $(top_srcdir)/m4/lt~obsolete.m4 \
  84. $(top_srcdir)/libopts/m4/libopts.m4 \
  85. $(top_srcdir)/libopts/m4/stdnoreturn.m4 \
  86. $(top_srcdir)/acinclude.m4 $(top_srcdir)/configure.ac
  87. am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
  88. $(ACLOCAL_M4)
  89. mkinstalldirs = $(install_sh) -d
  90. CONFIG_HEADER = $(top_builddir)/src/config.h
  91. CONFIG_CLEAN_FILES = config
  92. CONFIG_CLEAN_VPATH_FILES =
  93. AM_V_P = $(am__v_P_@AM_V@)
  94. am__v_P_ = $(am__v_P_@AM_DEFAULT_V@)
  95. am__v_P_0 = false
  96. am__v_P_1 = :
  97. AM_V_GEN = $(am__v_GEN_@AM_V@)
  98. am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@)
  99. am__v_GEN_0 = @echo " GEN " $@;
  100. am__v_GEN_1 =
  101. AM_V_at = $(am__v_at_@AM_V@)
  102. am__v_at_ = $(am__v_at_@AM_DEFAULT_V@)
  103. am__v_at_0 = @
  104. am__v_at_1 =
  105. SOURCES =
  106. DIST_SOURCES =
  107. am__can_run_installinfo = \
  108. case $$AM_UPDATE_INFO_DIR in \
  109. n|no|NO) false;; \
  110. *) (install-info --version) >/dev/null 2>&1;; \
  111. esac
  112. am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP)
  113. DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
  114. ACLOCAL = @ACLOCAL@
  115. AMTAR = @AMTAR@
  116. AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
  117. AR = @AR@
  118. AUTOCONF = @AUTOCONF@
  119. AUTOGEN = @AUTOGEN@
  120. AUTOHEADER = @AUTOHEADER@
  121. AUTOMAKE = @AUTOMAKE@
  122. AWK = @AWK@
  123. CC = @CC@
  124. CCDEPMODE = @CCDEPMODE@
  125. CFLAGS = @CFLAGS@
  126. CPP = @CPP@
  127. CPPFLAGS = @CPPFLAGS@
  128. CROSS_ARCH = @CROSS_ARCH@
  129. CROSS_LD = @CROSS_LD@
  130. CUT = @CUT@
  131. CXX = @CXX@
  132. CXXCPP = @CXXCPP@
  133. CXXDEPMODE = @CXXDEPMODE@
  134. CXXFLAGS = @CXXFLAGS@
  135. CYGPATH_W = @CYGPATH_W@
  136. DEFS = @DEFS@
  137. DEPDIR = @DEPDIR@
  138. DLLTOOL = @DLLTOOL@
  139. DMALLOC_LIB = @DMALLOC_LIB@
  140. DSYMUTIL = @DSYMUTIL@
  141. DUMPBIN = @DUMPBIN@
  142. ECHO = @ECHO@
  143. ECHO_C = @ECHO_C@
  144. ECHO_N = @ECHO_N@
  145. ECHO_T = @ECHO_T@
  146. EGREP = @EGREP@
  147. EXEEXT = @EXEEXT@
  148. FGREP = @FGREP@
  149. GREP = @GREP@
  150. GROFF = @GROFF@
  151. INSTALL = @INSTALL@
  152. INSTALL_DATA = @INSTALL_DATA@
  153. INSTALL_PROGRAM = @INSTALL_PROGRAM@
  154. INSTALL_SCRIPT = @INSTALL_SCRIPT@
  155. INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@
  156. LD = @LD@
  157. LDFLAGS = @LDFLAGS@
  158. LDNETINC = @LDNETINC@
  159. LDNETLIB = @LDNETLIB@
  160. LIBOBJS = @LIBOBJS@
  161. LIBOPTS_CFLAGS = @LIBOPTS_CFLAGS@
  162. LIBOPTS_DIR = @LIBOPTS_DIR@
  163. LIBOPTS_LDADD = @LIBOPTS_LDADD@
  164. LIBS = @LIBS@
  165. LIBTOOL = @LIBTOOL@
  166. LIPO = @LIPO@
  167. LNAVLIB = @LNAVLIB@
  168. LNAV_CFLAGS = @LNAV_CFLAGS@
  169. LN_S = @LN_S@
  170. LPCAPINC = @LPCAPINC@
  171. LPCAPLIB = @LPCAPLIB@
  172. LTLIBOBJS = @LTLIBOBJS@
  173. MACOSX_SDK_PATH = @MACOSX_SDK_PATH@
  174. MAINT = @MAINT@
  175. MAKEINFO = @MAKEINFO@
  176. MANIFEST_TOOL = @MANIFEST_TOOL@
  177. MKDIR_P = @MKDIR_P@
  178. NETMAPFLAGS = @NETMAPFLAGS@
  179. NETMAPINC = @NETMAPINC@
  180. NETMAPINCDIR = @NETMAPINCDIR@
  181. NETMAPUSERINC = @NETMAPUSERINC@
  182. NM = @NM@
  183. NMEDIT = @NMEDIT@
  184. OBJDUMP = @OBJDUMP@
  185. OBJEXT = @OBJEXT@
  186. OTOOL = @OTOOL@
  187. OTOOL64 = @OTOOL64@
  188. PACKAGE = @PACKAGE@
  189. PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@
  190. PACKAGE_NAME = @PACKAGE_NAME@
  191. PACKAGE_STRING = @PACKAGE_STRING@
  192. PACKAGE_TARNAME = @PACKAGE_TARNAME@
  193. PACKAGE_URL = @PACKAGE_URL@
  194. PACKAGE_VERSION = @PACKAGE_VERSION@
  195. PATH_SEPARATOR = @PATH_SEPARATOR@
  196. PCAP_BPF_H_FILE = @PCAP_BPF_H_FILE@
  197. PCAP_CONFIG = @PCAP_CONFIG@
  198. POSIX_SHELL = @POSIX_SHELL@
  199. PRINTF = @PRINTF@
  200. RANLIB = @RANLIB@
  201. SED = @SED@
  202. SET_MAKE = @SET_MAKE@
  203. SHELL = @SHELL@
  204. STDNORETURN_H = @STDNORETURN_H@
  205. STRIP = @STRIP@
  206. TCPREPLAY_RELEASE = @TCPREPLAY_RELEASE@
  207. TCPREPLAY_VERSION = @TCPREPLAY_VERSION@
  208. VERSION = @VERSION@
  209. abs_builddir = @abs_builddir@
  210. abs_srcdir = @abs_srcdir@
  211. abs_top_builddir = @abs_top_builddir@
  212. abs_top_srcdir = @abs_top_srcdir@
  213. ac_ct_AR = @ac_ct_AR@
  214. ac_ct_CC = @ac_ct_CC@
  215. ac_ct_CXX = @ac_ct_CXX@
  216. ac_ct_DUMPBIN = @ac_ct_DUMPBIN@
  217. am__include = @am__include@
  218. am__leading_dot = @am__leading_dot@
  219. am__quote = @am__quote@
  220. am__tar = @am__tar@
  221. am__untar = @am__untar@
  222. bindir = @bindir@
  223. build = @build@
  224. build_alias = @build_alias@
  225. build_cpu = @build_cpu@
  226. build_os = @build_os@
  227. build_vendor = @build_vendor@
  228. builddir = @builddir@
  229. datadir = @datadir@
  230. datarootdir = @datarootdir@
  231. debug_flag = @debug_flag@
  232. debug_run_time_flag = @debug_run_time_flag@
  233. depmod = @depmod@
  234. docdir = @docdir@
  235. dvidir = @dvidir@
  236. exec_prefix = @exec_prefix@
  237. extra_debug_flag = @extra_debug_flag@
  238. host = @host@
  239. host_alias = @host_alias@
  240. host_cpu = @host_cpu@
  241. host_os = @host_os@
  242. host_vendor = @host_vendor@
  243. htmldir = @htmldir@
  244. includedir = @includedir@
  245. infodir = @infodir@
  246. insmod = @insmod@
  247. install_sh = @install_sh@
  248. libdir = @libdir@
  249. libexecdir = @libexecdir@
  250. localedir = @localedir@
  251. localstatedir = @localstatedir@
  252. mandir = @mandir@
  253. mkdir_p = @mkdir_p@
  254. nic1 = @nic1@
  255. nic2 = @nic2@
  256. oldincludedir = @oldincludedir@
  257. pcncfg = @pcncfg@
  258. pdfdir = @pdfdir@
  259. prefix = @prefix@
  260. program_transform_name = @program_transform_name@
  261. psdir = @psdir@
  262. rmmod = @rmmod@
  263. sbindir = @sbindir@
  264. sharedstatedir = @sharedstatedir@
  265. srcdir = @srcdir@
  266. sysconfdir = @sysconfdir@
  267. target = @target@
  268. target_alias = @target_alias@
  269. target_cpu = @target_cpu@
  270. target_os = @target_os@
  271. target_vendor = @target_vendor@
  272. tcpdump_path = @tcpdump_path@
  273. timestamp_trace_flag = @timestamp_trace_flag@
  274. top_build_prefix = @top_build_prefix@
  275. top_builddir = @top_builddir@
  276. top_srcdir = @top_srcdir@
  277. # $Id$
  278. MAKEFLAGS = -s -k
  279. HOST = @host@
  280. TARGET = @target@
  281. BUILD = @build@
  282. ENABLE_DEBUG = @debug_run_time_flag@
  283. TCPPREP = ../src/tcpprep --no-arg-comment
  284. TCPREPLAY = ../src/tcpreplay
  285. TCPREWRITE = ../src/tcprewrite
  286. TCPBRIDGE = ../src/tcpbridge
  287. EXTRA_DIST = test.pcap test.auto_bridge test.auto_client test.auto_router \
  288. test.auto_server test.auto_first test.cidr test.comment test.port test.mac \
  289. test.cidr_reverse test.mac_reverse test.regex_reverse \
  290. test.prep_config test.primary test.regex test.secondary \
  291. test.rewrite_seed test.rewrite_portmap test.rewrite_endpoint \
  292. test.rewrite_pnat test.rewrite_pad test.rewrite_trunc \
  293. test.rewrite_mac test.rewrite_layer2 test.rewrite_config \
  294. test.rewrite_skip test.rewrite_dltuser test.rewrite_dlthdlc \
  295. test.rewrite_vlandel test.rewrite_efcs test.rewrite_1ttl \
  296. test.rewrite_2ttl test.rewrite_3ttl test.rewrite_enet_subsmac \
  297. test.rewrite_mtutrunc test.rewrite_mac_seed \
  298. test.rewrite_mac_seed_keep test.rewrite_l7fuzzing\
  299. test2.rewrite_seed test2.rewrite_portmap test2.rewrite_endpoint \
  300. test2.rewrite_pnat test2.rewrite_pad test2.rewrite_trunc \
  301. test2.rewrite_mac test2.rewrite_layer2 test2.rewrite_config \
  302. test2.rewrite_skip test2.rewrite_dltuser test2.rewrite_dlthdlc \
  303. test2.rewrite_vlandel test2.rewrite_efcs test2.rewrite_1ttl \
  304. test2.rewrite_mtutrunc test2.rewrite_enet_subsmac \
  305. test2.rewrite_2ttl test2.rewrite_3ttl test.rewrite_tos test2.rewrite_tos \
  306. test2.rewrite_enet_subsmac test2.rewrite_mac_seed \
  307. test2.rewrite_mac_seed_keep test2.rewrite_l7fuzzing
  308. @WORDS_BIGENDIAN_FALSE@STANDARD_REWRITE = standard_littleendian
  309. @WORDS_BIGENDIAN_TRUE@STANDARD_REWRITE = standard_bigendian
  310. @WORDS_BIGENDIAN_FALSE@REWRITE_WARN = "little"
  311. @WORDS_BIGENDIAN_TRUE@REWRITE_WARN = "big"
  312. all: all-am
  313. .SUFFIXES:
  314. $(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.am $(am__configure_deps)
  315. @for dep in $?; do \
  316. case '$(am__configure_deps)' in \
  317. *$$dep*) \
  318. ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \
  319. && { if test -f $@; then exit 0; else break; fi; }; \
  320. exit 1;; \
  321. esac; \
  322. done; \
  323. echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign test/Makefile'; \
  324. $(am__cd) $(top_srcdir) && \
  325. $(AUTOMAKE) --foreign test/Makefile
  326. .PRECIOUS: Makefile
  327. Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
  328. @case '$?' in \
  329. *config.status*) \
  330. cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \
  331. *) \
  332. echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \
  333. cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \
  334. esac;
  335. $(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES)
  336. cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
  337. $(top_srcdir)/configure: @MAINTAINER_MODE_TRUE@ $(am__configure_deps)
  338. cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
  339. $(ACLOCAL_M4): @MAINTAINER_MODE_TRUE@ $(am__aclocal_m4_deps)
  340. cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
  341. $(am__aclocal_m4_deps):
  342. config: $(top_builddir)/config.status $(srcdir)/config.in
  343. cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@
  344. mostlyclean-libtool:
  345. -rm -f *.lo
  346. clean-libtool:
  347. -rm -rf .libs _libs
  348. tags TAGS:
  349. ctags CTAGS:
  350. cscope cscopelist:
  351. distdir: $(DISTFILES)
  352. @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
  353. topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
  354. list='$(DISTFILES)'; \
  355. dist_files=`for file in $$list; do echo $$file; done | \
  356. sed -e "s|^$$srcdirstrip/||;t" \
  357. -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \
  358. case $$dist_files in \
  359. */*) $(MKDIR_P) `echo "$$dist_files" | \
  360. sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \
  361. sort -u` ;; \
  362. esac; \
  363. for file in $$dist_files; do \
  364. if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
  365. if test -d $$d/$$file; then \
  366. dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
  367. if test -d "$(distdir)/$$file"; then \
  368. find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
  369. fi; \
  370. if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
  371. cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \
  372. find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
  373. fi; \
  374. cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \
  375. else \
  376. test -f "$(distdir)/$$file" \
  377. || cp -p $$d/$$file "$(distdir)/$$file" \
  378. || exit 1; \
  379. fi; \
  380. done
  381. check-am: all-am
  382. check: check-am
  383. all-am: Makefile
  384. installdirs:
  385. install: install-am
  386. install-exec: install-exec-am
  387. install-data: install-data-am
  388. uninstall: uninstall-am
  389. install-am: all-am
  390. @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am
  391. installcheck: installcheck-am
  392. install-strip:
  393. if test -z '$(STRIP)'; then \
  394. $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
  395. install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
  396. install; \
  397. else \
  398. $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
  399. install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
  400. "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \
  401. fi
  402. mostlyclean-generic:
  403. clean-generic:
  404. distclean-generic:
  405. -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
  406. -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES)
  407. maintainer-clean-generic:
  408. @echo "This command is intended for maintainers to use"
  409. @echo "it deletes files that may require special tools to rebuild."
  410. clean-am: clean-generic clean-libtool mostlyclean-am
  411. distclean-am: clean-am distclean-generic
  412. dvi: dvi-am
  413. dvi-am:
  414. html: html-am
  415. html-am:
  416. info: info-am
  417. info-am:
  418. install-data-am:
  419. install-dvi: install-dvi-am
  420. install-dvi-am:
  421. install-exec-am:
  422. install-html: install-html-am
  423. install-html-am:
  424. install-info: install-info-am
  425. install-info-am:
  426. install-man:
  427. install-pdf: install-pdf-am
  428. install-pdf-am:
  429. install-ps: install-ps-am
  430. install-ps-am:
  431. installcheck-am:
  432. maintainer-clean-am: distclean-am maintainer-clean-generic
  433. mostlyclean: mostlyclean-am
  434. mostlyclean-am: mostlyclean-generic mostlyclean-libtool
  435. pdf: pdf-am
  436. pdf-am:
  437. ps: ps-am
  438. ps-am:
  439. uninstall-am:
  440. .MAKE: install-am install-strip
  441. .PHONY: all all-am check check-am clean clean-generic clean-libtool \
  442. cscopelist-am ctags-am distclean distclean-generic \
  443. distclean-libtool distdir dvi dvi-am html html-am info info-am \
  444. install install-am install-data install-data-am install-dvi \
  445. install-dvi-am install-exec install-exec-am install-html \
  446. install-html-am install-info install-info-am install-man \
  447. install-pdf install-pdf-am install-ps install-ps-am \
  448. install-strip installcheck installcheck-am installdirs \
  449. maintainer-clean maintainer-clean-generic mostlyclean \
  450. mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \
  451. tags-am uninstall uninstall-am
  452. test: all
  453. all: clearlog check tcpprep tcpreplay tcprewrite
  454. clearlog:
  455. -rm test.log
  456. check:
  457. $(PRINTF) "%s\n" "NOTICE: Tests must be run as root"
  458. $(PRINTF) "%s\n" "Sending traffic on '$(nic1)' and '$(nic2)'"
  459. standard: standard_prep $(STANDARD_REWRITE)
  460. $(PRINTF) "Warning: only creating %s endian standard test files\n" $(REWRITE_WARN)
  461. standard_prep:
  462. $(TCPPREP) -i test.pcap -o test.auto_router -a router
  463. $(TCPPREP) -i test.pcap -o test.auto_bridge -a bridge
  464. $(TCPPREP) -i test.pcap -o test.auto_client -a client
  465. $(TCPPREP) -i test.pcap -o test.auto_server -a server
  466. $(TCPPREP) -i test.pcap -o test.auto_first -a first
  467. $(TCPPREP) --load-opts config -o test.prep_config
  468. $(TCPPREP) -i test.pcap -o test.port -p
  469. $(TCPPREP) -i test.pcap -o test.mac -e 00:02:3b:00:3d:ce
  470. $(TCPPREP) -i test.pcap -o test.cidr -c '216.27.178.0/24'
  471. $(TCPPREP) -i test.pcap -o test.regex -r '216.27.178.*'
  472. $(TCPPREP) -i test.pcap -o test.comment -C "This is a comment" -p
  473. $(TCPPREP) -i test.pcap -o test.mac_reverse -e 00:02:3b:00:3d:ce --reverse
  474. $(TCPPREP) -i test.pcap -o test.cidr_reverse -c '216.27.178.0/24' --reverse
  475. $(TCPPREP) -i test.pcap -o test.regex_reverse -r '216.27.178.*' --reverse
  476. standard_bigendian:
  477. $(TCPREWRITE) -i test.pcap -o test.rewrite_seed -s 55
  478. $(TCPREWRITE) -i test.pcap -o test.rewrite_tos --tos=50
  479. $(TCPREWRITE) -i test.pcap -o test.rewrite_portmap -r 80:8080
  480. $(TCPREWRITE) -i test.pcap -o test.rewrite_endpoint \
  481. -e 10.10.0.1:10.10.0.2 -c test.auto_router
  482. $(TCPREWRITE) -i test.pcap -o test.rewrite_pnat \
  483. -N 216.27.178.0/24:172.16.0.0/24
  484. $(TCPREWRITE) -i test.pcap -o test.rewrite_pad -F pad
  485. $(TCPREWRITE) -i test.pcap -o test.rewrite_trunc -F trunc
  486. $(TCPREWRITE) -i test.pcap -o test.rewrite_mac \
  487. --enet-dmac=00:12:13:14:15:16,00:22:33:44:55:66 \
  488. --enet-smac=00:22:33:44:55:66,00:12:13:14:15:16 -c test.auto_router
  489. $(TCPREWRITE) -i test.pcap -o test.rewrite_enet_subsmac \
  490. --enet-subsmac=00:1f:f3:3c:e1:13,00:22:33:44:55:66 \
  491. --enet-subsmac=f8:1e:df:e5:84:3a,00:66:55:44:33:22
  492. $(TCPREWRITE) -i test.pcap -o test.rewrite_mac_seed --enet-mac-seed=42
  493. $(TCPREWRITE) -i test.pcap -o test.rewrite_mac_seed_keep --enet-mac-seed=42 \
  494. --enet-mac-seed-keep-bytes=3
  495. $(TCPREWRITE) -i test.pcap -o test.rewrite_layer2 \
  496. --dlt=user --user-dlink=00,50,da,5d,46,55,0,7,eb,30,a4,c3,08,0
  497. $(TCPREWRITE) -i test.pcap -o test.rewrite_config --enet-vlan=add --enet-vlan-tag=45 \
  498. --enet-vlan-cfi=1 --enet-vlan-pri=5
  499. $(TCPREWRITE) -i test.pcap -o test.rewrite_skip -b -s 55 \
  500. --enet-dmac=00:12:13:14:15:16,00:22:33:44:55:66 \
  501. --enet-smac=00:22:33:44:55:66,00:12:13:14:15:16 -c test.auto_router
  502. $(TCPREWRITE) -i test.pcap -o test.rewrite_dltuser --dlt=user \
  503. --user-dlink=0x0f,0x00,0x08,0x00 --user-dlt=104
  504. $(TCPREWRITE) -i test.pcap -o test.rewrite_dlthdlc --dlt=hdlc \
  505. --hdlc-control=0 --hdlc-address=0x0F
  506. $(TCPREWRITE) -i test.rewrite_config -o test.rewrite_vlandel \
  507. --enet-vlan=del
  508. $(TCPREWRITE) -i test.pcap -o test.rewrite_efcs --efcs
  509. $(TCPREWRITE) -i test.pcap -o test.rewrite_1ttl --ttl=58
  510. $(TCPREWRITE) -i test.pcap -o test.rewrite_2ttl --ttl=+58
  511. $(TCPREWRITE) -i test.pcap -o test.rewrite_3ttl --ttl=-58
  512. $(TCPREWRITE) -i test.pcap -o test.rewrite_mtutrunc --mtu-trunc --mtu=300
  513. $(TCPREWRITE) -i test.pcap -o test.rewrite_l7fuzzing --fuzz-seed=42
  514. standard_littleendian:
  515. $(TCPREWRITE) -i test.pcap -o test2.rewrite_seed -s 55
  516. $(TCPREWRITE) -i test.pcap -o test2.rewrite_tos --tos=50
  517. $(TCPREWRITE) -i test.pcap -o test2.rewrite_portmap -r 80:8080
  518. $(TCPREWRITE) -i test.pcap -o test2.rewrite_endpoint \
  519. -e 10.10.0.1:10.10.0.2 -c test.auto_router
  520. $(TCPREWRITE) -i test.pcap -o test2.rewrite_pnat \
  521. -N 216.27.178.0/24:172.16.0.0/24
  522. $(TCPREWRITE) -i test.pcap -o test2.rewrite_pad -F pad
  523. $(TCPREWRITE) -i test.pcap -o test2.rewrite_trunc -F trunc
  524. $(TCPREWRITE) -i test.pcap -o test2.rewrite_mac \
  525. --enet-dmac=00:12:13:14:15:16,00:22:33:44:55:66 \
  526. --enet-smac=00:22:33:44:55:66,00:12:13:14:15:16 -c test.auto_router
  527. $(TCPREWRITE) -i test.pcap -o test2.rewrite_enet_subsmac \
  528. --enet-subsmac=00:1f:f3:3c:e1:13,00:22:33:44:55:66 \
  529. --enet-subsmac=f8:1e:df:e5:84:3a,00:66:55:44:33:22
  530. $(TCPREWRITE) -i test.pcap -o test2.rewrite_mac_seed --enet-mac-seed=42
  531. $(TCPREWRITE) -i test.pcap -o test2.rewrite_mac_seed_keep --enet-mac-seed=42 \
  532. --enet-mac-seed-keep-bytes=3
  533. $(TCPREWRITE) -i test.pcap -o test2.rewrite_layer2 \
  534. --dlt=user --user-dlink=00,50,da,5d,46,55,0,7,eb,30,a4,c3,08,0
  535. $(TCPREWRITE) -i test.pcap -o test2.rewrite_config --enet-vlan=add --enet-vlan-tag=45 \
  536. --enet-vlan-cfi=1 --enet-vlan-pri=5
  537. $(TCPREWRITE) -i test.pcap -o test2.rewrite_skip -b -s 55 \
  538. --enet-dmac=00:12:13:14:15:16,00:22:33:44:55:66 \
  539. --enet-smac=00:22:33:44:55:66,00:12:13:14:15:16 -c test.auto_router
  540. $(TCPREWRITE) -i test.pcap -o test2.rewrite_dltuser --dlt=user \
  541. --user-dlink=0x0f,0x00,0x08,0x00 --user-dlt=104
  542. $(TCPREWRITE) -i test.pcap -o test2.rewrite_dlthdlc --dlt=hdlc \
  543. --hdlc-control=0 --hdlc-address=0x0F
  544. $(TCPREWRITE) -i test.rewrite_config -o test2.rewrite_vlandel \
  545. --enet-vlan=del
  546. $(TCPREWRITE) -i test.pcap -o test2.rewrite_efcs --efcs
  547. $(TCPREWRITE) -i test.pcap -o test2.rewrite_1ttl --ttl=58
  548. $(TCPREWRITE) -i test.pcap -o test2.rewrite_2ttl --ttl=+58
  549. $(TCPREWRITE) -i test.pcap -o test2.rewrite_3ttl --ttl=-58
  550. $(TCPREWRITE) -i test.pcap -o test2.rewrite_mtutrunc --mtu-trunc --mtu=300
  551. $(TCPREWRITE) -i test.pcap -o test2.rewrite_l7fuzzing --fuzz-seed=42
  552. tcpprep: auto_router auto_bridge auto_client auto_server auto_first cidr regex \
  553. port mac comment print_info print_comment prep_config \
  554. mac_reverse cidr_reverse regex_reverse
  555. tcprewrite: rewrite_portmap rewrite_endpoint rewrite_pnat rewrite_trunc \
  556. rewrite_pad rewrite_seed rewrite_mac rewrite_layer2 rewrite_config \
  557. rewrite_skip rewrite_dltuser rewrite_dlthdlc rewrite_vlandel rewrite_efcs \
  558. rewrite_1ttl rewrite_2ttl rewrite_3ttl rewrite_tos rewrite_mtutrunc \
  559. rewrite_enet_subsmac rewrite_mac_seed rewrite_mac_seed_keep rewrite_l7fuzzing
  560. tcpreplay: replay_basic replay_cache replay_pps replay_rate replay_top \
  561. replay_config replay_multi replay_pps_multi replay_precache \
  562. replay_stats replay_dualfile replay_maxsleep
  563. prep_config:
  564. $(PRINTF) "%s" "[tcpprep] Config mode test: "
  565. $(PRINTF) "%s\n" "*** [tcpprep] Config mode test: " >>test.log
  566. $(TCPPREP) $(ENABLE_DEBUG) --load-opts=config -o test.$@1 >>test.log 2>&1
  567. diff test.$@ test.$@1 >>test.log 2>&1
  568. if [ $? ] ; then $(PRINTF) "\t\t\t%s\n" "FAILED"; else $(PRINTF) "\t\t\t%s\n" "OK"; fi
  569. auto_router:
  570. $(PRINTF) "%s" "[tcpprep] Auto/Router mode test: "
  571. $(PRINTF) "%s\n" "*** [tcpprep] Auto/Router mode test: " >>test.log
  572. $(TCPPREP) $(ENABLE_DEBUG) -i test.pcap -o test.$@1 -a router >>test.log 2>&1
  573. diff test.$@ test.$@1 >>test.log 2>&1
  574. if [ $? ] ; then $(PRINTF) "\t\t%s\n" "FAILED"; else $(PRINTF) "\t\t%s\n" "OK"; fi
  575. auto_bridge:
  576. $(PRINTF) "%s" "[tcpprep] Auto/Bridge mode test: "
  577. $(PRINTF) "%s\n" "*** [tcpprep] Auto/Bridge mode test: " >>test.log
  578. $(TCPPREP) $(ENABLE_DEBUG) -i test.pcap -o test.$@1 -a bridge >>test.log 2>&1
  579. diff test.$@ test.$@1 >>test.log 2>&1
  580. if [ $? ] ; then $(PRINTF) "\t\t%s\n" "FAILED"; else $(PRINTF) "\t\t%s\n" "OK"; fi
  581. auto_client:
  582. $(PRINTF) "%s" "[tcpprep] Auto/Client mode test: "
  583. $(PRINTF) "%s\n" "*** [tcpprep] Auto/Client mode test: " >>test.log
  584. $(TCPPREP) $(ENABLE_DEBUG) -i test.pcap -o test.$@1 -a client >>test.log 2>&1
  585. diff test.$@ test.$@1 >>test.log 2>&1
  586. if [ $? ] ; then $(PRINTF) "\t\t%s\n" "FAILED"; else $(PRINTF) "\t\t%s\n" "OK"; fi
  587. auto_server:
  588. $(PRINTF) "%s" "[tcpprep] Auto/Server mode test: "
  589. $(PRINTF) "%s\n" "*** [tcpprep] Auto/Server mode test: " >>test.log
  590. $(TCPPREP) $(ENABLE_DEBUG) -i test.pcap -o test.$@1 -a server >>test.log 2>&1
  591. diff test.$@ test.$@1 >>test.log 2>&1
  592. if [ $? ] ; then $(PRINTF) "\t\t%s\n" "FAILED"; else $(PRINTF) "\t\t%s\n" "OK"; fi
  593. auto_first:
  594. $(PRINTF) "%s" "[tcpprep] Auto/First mode test: "
  595. $(PRINTF) "%s\n" "*** [tcpprep] Auto/First mode test: " >>test.log
  596. $(TCPPREP) $(ENABLE_DEBUG) -i test.pcap -o test.$@1 -a first >>test.log 2>&1
  597. diff test.$@ test.$@1 >>test.log 2>&1
  598. if [ $? ] ; then $(PRINTF) "\t\t%s\n" "FAILED"; else $(PRINTF) "\t\t%s\n" "OK"; fi
  599. regex:
  600. $(PRINTF) "%s" "[tcpprep] Regex mode test: "
  601. $(PRINTF) "%s\n" "*** [tcpprep] Regex mode test: " >>test.log
  602. $(TCPPREP) $(ENABLE_DEBUG) -i test.pcap -o test.$@1 -r '216.27.178.*' >>test.log 2>&1
  603. diff test.$@ test.$@1 >>test.log 2>&1
  604. if [ $? ] ; then $(PRINTF) "\t\t\t%s\n" "FAILED"; else $(PRINTF) "\t\t\t%s\n" "OK"; fi
  605. cidr:
  606. $(PRINTF) "%s" "[tcpprep] CIDR mode test: "
  607. $(PRINTF) "%s\n" "*** [tcpprep] CIDR mode test: " >>test.log
  608. $(TCPPREP) $(ENABLE_DEBUG) -i test.pcap -o test.$@1 -c '216.27.178.0/24' >>test.log 2>&1
  609. diff test.$@ test.$@1 >>test.log 2>&1
  610. if [ $? ] ; then $(PRINTF) "\t\t\t%s\n" "FAILED"; else $(PRINTF) "\t\t\t%s\n" "OK"; fi
  611. port:
  612. $(PRINTF) "%s" "[tcpprep] Port mode test: "
  613. $(PRINTF) "%s\n" "*** [tcpprep] Port mode test: " >>test.log
  614. $(TCPPREP) $(ENABLE_DEBUG) -i test.pcap -o test.$@1 -p >>test.log 2>&1
  615. diff test.$@ test.$@1 >>test.log 2>&1
  616. if [ $? ] ; then $(PRINTF) "\t\t\t%s\n" "FAILED"; else $(PRINTF) "\t\t\t%s\n" "OK"; fi
  617. mac:
  618. $(PRINTF) "%s" "[tcpprep] MAC mode test: "
  619. $(PRINTF) "%s\n" "*** [tcpprep] MAC mode test: " >>test.log
  620. $(TCPPREP) $(ENABLE_DEBUG) -i test.pcap -o test.$@1 -e 00:02:3b:00:3d:ce >>test.log 2>&1
  621. diff test.$@ test.$@1 >>test.log 2>&1
  622. if [ $? ] ; then $(PRINTF) "\t\t\t%s\n" "FAILED"; else $(PRINTF) "\t\t\t%s\n" "OK"; fi
  623. comment:
  624. $(PRINTF) "%s" "[tcpprep] Comment mode test: "
  625. $(PRINTF) "%s\n" "*** [tcpprep] Comment mode test: " >>test.log
  626. $(TCPPREP) $(ENABLE_DEBUG) -i test.pcap -o test.$@1 -C "This is a comment" -p >>test.log 2>&1
  627. if [ $? ] ; then $(PRINTF) "\t\t\t%s\n" "FAILED"; else $(PRINTF) "\t\t\t%s\n" "OK"; fi
  628. print_comment:
  629. $(PRINTF) "%s" "[tcpprep] Print comment mode test: "
  630. $(PRINTF) "%s\n" "*** [tcpprep] Print comment mode test: " >>test.log
  631. $(TCPPREP) $(ENABLE_DEBUG) -P test.comment >test.$@1 >>test.log 2>&1
  632. if [ $? ] ; then $(PRINTF) "\t\t%s\n" "FAILED"; else $(PRINTF) "\t\t%s\n" "OK"; fi
  633. print_info:
  634. $(PRINTF) "%s" "[tcpprep] Print info mode test: "
  635. $(PRINTF) "%s\n" "*** [tcpprep] Print info mode test: " >>test.log
  636. $(TCPPREP) $(ENABLE_DEBUG) -I test.comment >test.$@1 >>test.log 2>&1
  637. if [ $? ] ; then $(PRINTF) "\t\t%s\n" "FAILED"; else $(PRINTF) "\t\t%s\n" "OK"; fi
  638. regex_reverse:
  639. $(PRINTF) "%s" "[tcpprep] Regex reverse mode test: "
  640. $(PRINTF) "%s\n" "*** [tcpprep] Regex reverse mode test: " >>test.log
  641. $(TCPPREP) $(ENABLE_DEBUG) -i test.pcap -o test.$@1 -r '216.27.178.*' --reverse >>test.log 2>&1
  642. diff test.$@ test.$@1 >>test.log 2>&1
  643. if [ $? ] ; then $(PRINTF) "\t\t%s\n" "FAILED"; else $(PRINTF) "\t\t%s\n" "OK"; fi
  644. cidr_reverse:
  645. $(PRINTF) "%s" "[tcpprep] CIDR reverse mode test: "
  646. $(PRINTF) "%s\n" "*** [tcpprep] CIDR reverse mode test: " >>test.log
  647. $(TCPPREP) $(ENABLE_DEBUG) -i test.pcap -o test.$@1 -c '216.27.178.0/24' --reverse >>test.log 2>&1
  648. diff test.$@ test.$@1 >>test.log 2>&1
  649. if [ $? ] ; then $(PRINTF) "\t\t%s\n" "FAILED"; else $(PRINTF) "\t\t%s\n" "OK"; fi
  650. mac_reverse:
  651. $(PRINTF) "%s" "[tcpprep] MAC reverse mode test: "
  652. $(PRINTF) "%s\n" "*** [tcpprep] MAC reverse mode test: " >>test.log
  653. $(TCPPREP) $(ENABLE_DEBUG) -i test.pcap -o test.$@1 -e 00:02:3b:00:3d:ce --reverse >>test.log 2>&1
  654. diff test.$@ test.$@1 >>test.log 2>&1
  655. if [ $? ] ; then $(PRINTF) "\t\t%s\n" "FAILED"; else $(PRINTF) "\t\t%s\n" "OK"; fi
  656. replay_basic:
  657. $(PRINTF) "%s" "[tcpreplay] Basic test: "
  658. $(PRINTF) "%s\n" "*** [tcpreplay] Basic test: " >>test.log
  659. $(TCPREPLAY) $(ENABLE_DEBUG) -i $(nic1) -t test.pcap >>test.log 2>&1
  660. if [ $? ] ; then $(PRINTF) "\t\t\t%s\n" "FAILED"; else $(PRINTF) "\t\t\t%s\n" "OK"; fi
  661. replay_cache:
  662. $(PRINTF) "%s" "[tcpreplay] Cache test: "
  663. $(PRINTF) "%s\n" "*** [tcpreplay] Cache test: " >>test.log
  664. $(TCPREPLAY) $(ENABLE_DEBUG) -c test.cidr -i $(nic1) -I $(nic2) -t test.pcap >>test.log 2>&1
  665. if [ $? ] ; then $(PRINTF) "\t\t\t%s\n" "FAILED"; else $(PRINTF) "\t\t\t%s\n" "OK"; fi
  666. replay_accurate:
  667. $(PRINTF) "%s" "[tcpreplay] Accurate test: "
  668. $(PRINTF) "%s\n" "*** [tcpreplay] Accurate test: " >>test.log
  669. $(TCPREPLAY) $(ENABLE_DEBUG) -a -i $(nic1) test.pcap >>test.log 2>&1
  670. if [ $? ] ; then $(PRINTF) "\t\t\t%s\n" "FAILED"; else $(PRINTF) "\t\t\t%s\n" "OK"; fi
  671. replay_stats:
  672. $(PRINTF) "%s" "[tcpreplay] Statistics test: "
  673. $(PRINTF) "%s\n" "*** [tcpreplay] Statistics test: " >>test.log
  674. $(TCPREPLAY) $(ENABLE_DEBUG) --stats=1 -i $(nic1) test.pcap >>test.log 2>&1
  675. if [ $? ] ; then $(PRINTF) "\t\t\t%s\n" "FAILED"; else $(PRINTF) "\t\t\t%s\n" "OK"; fi
  676. rewrite_portmap:
  677. $(PRINTF) "%s" "[tcprewrite] Portmap test: "
  678. $(PRINTF) "%s\n" "*** [tcprewrite] Portmap test: " >>test.log
  679. $(TCPREWRITE) $(ENABLE_DEBUG) -i test.pcap -o test.$@1 -r 80:8080 >>test.log 2>&1
  680. @WORDS_BIGENDIAN_TRUE@ diff test.$@ test.$@1 >>test.log 2>&1
  681. @WORDS_BIGENDIAN_FALSE@ diff test2.$@ test.$@1 >>test.log 2>&1
  682. if [ $? ] ; then $(PRINTF) "\t\t\t%s\n" "FAILED"; else $(PRINTF) "\t\t\t%s\n" "OK"; fi
  683. rewrite_endpoint:
  684. $(PRINTF) "%s" "[tcprewrite] Endpoint test: "
  685. $(PRINTF) "%s\n" "*** [tcprewrite] Endpoint test: " >>test.log
  686. $(TCPREWRITE) $(ENABLE_DEBUG) -i test.pcap -o test.$@1 -e 10.10.0.1:10.10.0.2 \
  687. -c test.auto_router >>test.log 2>&1
  688. @WORDS_BIGENDIAN_TRUE@ diff test.$@ test.$@1 >>test.log 2>&1
  689. @WORDS_BIGENDIAN_FALSE@ diff test2.$@ test.$@1 >>test.log 2>&1
  690. if [ $? ] ; then $(PRINTF) "\t\t\t%s\n" "FAILED"; else $(PRINTF) "\t\t\t%s\n" "OK"; fi
  691. rewrite_pnat:
  692. $(PRINTF) "%s" "[tcprewrite] Pseudo NAT test: "
  693. $(PRINTF) "%s\n" "*** [tcprewrite] Pseudo NAT test: " >>test.log
  694. $(TCPREWRITE) $(ENABLE_DEBUG) -i test.pcap -o test.$@1 \
  695. -N 216.27.178.0/24:172.16.0.0/24 >>test.log 2>&1
  696. @WORDS_BIGENDIAN_TRUE@ diff test.$@ test.$@1 >>test.log 2>&1
  697. @WORDS_BIGENDIAN_FALSE@ diff test2.$@ test.$@1 >>test.log 2>&1
  698. if [ $? ] ; then $(PRINTF) "\t\t\t%s\n" "FAILED"; else $(PRINTF) "\t\t\t%s\n" "OK"; fi
  699. rewrite_mac:
  700. $(PRINTF) "%s" "[tcprewrite] Src/Dst MAC test: "
  701. $(PRINTF) "%s\n" "*** [tcprewrite] Src/Dst MAC test: " >>test.log
  702. $(TCPREWRITE) $(ENABLE_DEBUG) -i test.pcap -o test.$@1 \
  703. --enet-dmac=00:12:13:14:15:16,00:22:33:44:55:66 \
  704. --enet-smac=00:22:33:44:55:66,00:12:13:14:15:16 -c test.auto_router >>test.log 2>&1
  705. @WORDS_BIGENDIAN_TRUE@ diff test.$@ test.$@1 >>test.log 2>&1
  706. @WORDS_BIGENDIAN_FALSE@ diff test2.$@ test.$@1 >>test.log 2>&1
  707. if [ $? ] ; then $(PRINTF) "\t\t\t%s\n" "FAILED"; else $(PRINTF) "\t\t\t%s\n" "OK"; fi
  708. rewrite_enet_subsmac:
  709. $(PRINTF) "%s" "[tcprewrite] Substitute Src/Dst MAC test: "
  710. $(PRINTF) "%s\n" "*** [tcprewrite] Substitute Src/Dst MAC test: " >>test.log
  711. $(TCPREWRITE) $(ENABLE_DEBUG) -i test.pcap -o test.$@1 \
  712. --enet-subsmac=00:1f:f3:3c:e1:13,00:22:33:44:55:66 \
  713. --enet-subsmac=f8:1e:df:e5:84:3a,00:66:55:44:33:22 >>test.log 2>&1
  714. @WORDS_BIGENDIAN_TRUE@ diff test.$@ test.$@1 >>test.log 2>&1
  715. @WORDS_BIGENDIAN_FALSE@ diff test2.$@ test.$@1 >>test.log 2>&1
  716. if [ $? ] ; then $(PRINTF) "\t\t\t%s\n" "FAILED"; else $(PRINTF) "\t%s\n" "OK"; fi
  717. rewrite_mac_seed:
  718. $(PRINTF) "%s" "[tcprewrite] Seeded MAC test: "
  719. $(PRINTF) "%s\n" "*** [tcprewrite] Seeded MAC test: " >>test.log
  720. $(TCPREWRITE) $(ENABLE_DEBUG) -i test.pcap -o test.$@1 \
  721. --enet-mac-seed=42 >>test.log 2>&1
  722. @WORDS_BIGENDIAN_TRUE@ diff test.$@ test.$@1 >>test.log 2>&1
  723. @WORDS_BIGENDIAN_FALSE@ diff test2.$@ test.$@1 >>test.log 2>&1
  724. if [ $? ] ; then $(PRINTF) "\t\t\t%s\n" "FAILED"; else $(PRINTF) "\t\t\t%s\n" "OK"; fi
  725. rewrite_mac_seed_keep:
  726. $(PRINTF) "%s" "[tcprewrite] Seeded Keep MAC test: "
  727. $(PRINTF) "%s\n" "*** [tcprewrite] Seeded Keep MAC test: " >>test.log
  728. $(TCPREWRITE) $(ENABLE_DEBUG) -i test.pcap -o test.$@1 \
  729. --enet-mac-seed=42 --enet-mac-seed-keep-bytes=3 >>test.log 2>&1
  730. @WORDS_BIGENDIAN_TRUE@ diff test.$@ test.$@1 >>test.log 2>&1
  731. @WORDS_BIGENDIAN_FALSE@ diff test2.$@ test.$@1 >>test.log 2>&1
  732. if [ $? ] ; then $(PRINTF) "\t\t\t%s\n" "FAILED"; else $(PRINTF) "\t\t%s\n" "OK"; fi
  733. rewrite_trunc:
  734. $(PRINTF) "%s" "[tcprewrite] Truncate test: "
  735. $(PRINTF) "%s\n" "*** [tcprewrite] Truncate test: " >>test.log
  736. $(TCPREWRITE) $(ENABLE_DEBUG) -F trunc -i test.pcap -o test.$@1 >>test.log 2>&1
  737. @WORDS_BIGENDIAN_TRUE@ diff test.$@ test.$@1 >>test.log 2>&1
  738. @WORDS_BIGENDIAN_FALSE@ diff test2.$@ test.$@1 >>test.log 2>&1
  739. if [ $? ] ; then $(PRINTF) "\t\t\t%s\n" "FAILED"; else $(PRINTF) "\t\t\t%s\n" "OK"; fi
  740. rewrite_pad:
  741. $(PRINTF) "%s" "[tcprewrite] Pad test: "
  742. $(PRINTF) "%s\n" "*** [tcprewrite] Pad test: " >>test.log
  743. $(TCPREWRITE) $(ENABLE_DEBUG) -F pad -i test.pcap -o test.$@1 >>test.log 2>&1
  744. @WORDS_BIGENDIAN_TRUE@ diff test.$@ test.$@1 >>test.log 2>&1
  745. @WORDS_BIGENDIAN_FALSE@ diff test2.$@ test.$@1 >>test.log 2>&1
  746. if [ $? ] ; then $(PRINTF) "\t\t\t\t%s\n" "FAILED"; else $(PRINTF) "\t\t\t\t%s\n" "OK"; fi
  747. rewrite_seed:
  748. $(PRINTF) "%s" "[tcprewrite] Seed IP test: "
  749. $(PRINTF) "%s\n" "*** [tcprewrite] Seed IP test: " >>test.log
  750. $(TCPREWRITE) $(ENABLE_DEBUG) -i test.pcap -o test.$@1 -s 55 >>test.log 2>&1
  751. @WORDS_BIGENDIAN_TRUE@ diff test.$@ test.$@1 >>test.log 2>&1
  752. @WORDS_BIGENDIAN_FALSE@ diff test2.$@ test.$@1 >>test.log 2>&1
  753. if [ $? ] ; then $(PRINTF) "\t\t\t%s\n" "FAILED"; else $(PRINTF) "\t\t\t%s\n" "OK"; fi
  754. rewrite_layer2:
  755. $(PRINTF) "%s" "[tcprewrite] Layer2 test: "
  756. $(PRINTF) "%s\n" "*** [tcprewrite] Layer2 test: " >>test.log
  757. $(TCPREWRITE) $(ENABLE_DEBUG) --dlt=user --user-dlink=00,50,da,5d,46,55,0,7,eb,30,a4,c3,08,0 \
  758. -i test.pcap -o test.$@1 >>test.log 2>&1
  759. @WORDS_BIGENDIAN_TRUE@ diff test.$@ test.$@1 >>test.log 2>&1
  760. @WORDS_BIGENDIAN_FALSE@ diff test2.$@ test.$@1 >>test.log 2>&1
  761. if [ $? ] ; then $(PRINTF) "\t\t\t%s\n" "FAILED"; else $(PRINTF) "\t\t\t%s\n" "OK"; fi
  762. rewrite_config:
  763. $(PRINTF) "%s" "[tcprewrite] Config/VLAN Add test: "
  764. $(PRINTF) "%s\n" "*** [tcprewrite] Config/VLAN Add test: " >>test.log
  765. $(TCPREWRITE) $(ENABLE_DEBUG) --load-opts config >>test.log 2>&1
  766. @WORDS_BIGENDIAN_TRUE@ diff test.$@ test.$@1 >>test.log 2>&1
  767. @WORDS_BIGENDIAN_FALSE@ diff test2.$@ test.$@1 >>test.log 2>&1
  768. if [ $? ] ; then $(PRINTF) "\t\t%s\n" "FAILED"; else $(PRINTF) "\t\t%s\n" "OK"; fi
  769. rewrite_skip:
  770. $(PRINTF) "%s" "[tcprewrite] Skip bcast test: "
  771. $(PRINTF) "%s\n" "*** [tcprewrite] Skip bcast test: " >>test.log
  772. $(TCPREWRITE) $(ENABLE_DEBUG) -i test.pcap -o test.$@1 -b -s 55 \
  773. --enet-dmac=00:12:13:14:15:16,00:22:33:44:55:66 \
  774. --enet-smac=00:22:33:44:55:66,00:12:13:14:15:16 -c test.auto_router >>test.log 2>&1
  775. @WORDS_BIGENDIAN_TRUE@ diff test.$@ test.$@1 >>test.log 2>&1
  776. @WORDS_BIGENDIAN_FALSE@ diff test2.$@ test.$@1 >>test.log 2>&1
  777. if [ $? ] ; then $(PRINTF) "\t\t\t%s\n" "FAILED"; else $(PRINTF) "\t\t\t%s\n" "OK"; fi
  778. rewrite_dltuser:
  779. $(PRINTF) "%s" "[tcprewrite] DLT User test: "
  780. $(PRINTF) "%s\n" "*** [tcprewrite] DLT User test: " >>test.log
  781. $(TCPREWRITE) $(ENABLE_DEBUG) -i test.pcap -o test.$@1 --dlt=user \
  782. --user-dlink=0x0f,0x00,0x08,0x00 --user-dlt=104 >>test.log 2>&1
  783. @WORDS_BIGENDIAN_TRUE@ diff test.$@ test.$@1 >>test.log 2>&1
  784. @WORDS_BIGENDIAN_FALSE@ diff test2.$@ test.$@1 >>test.log 2>&1
  785. if [ $? ] ; then $(PRINTF) "\t\t\t%s\n" "FAILED"; else $(PRINTF) "\t\t\t%s\n" "OK"; fi
  786. rewrite_dlthdlc:
  787. $(PRINTF) "%s" "[tcprewrite] DLT Cisco HDLC test: "
  788. $(PRINTF) "%s\n" "*** [tcprewrite] DLT Cisco HDLC test: " >>test.log
  789. $(TCPREWRITE) $(ENABLE_DEBUG) -i test.pcap -o test.$@1 --dlt=hdlc \
  790. --hdlc-control=0 --hdlc-address=0x0F >>test.log 2>&1
  791. @WORDS_BIGENDIAN_TRUE@ diff test.$@ test.$@1 >>test.log 2>&1
  792. @WORDS_BIGENDIAN_FALSE@ diff test2.$@ test.$@1 >>test.log 2>&1
  793. if [ $? ] ; then $(PRINTF) "\t\t%s\n" "FAILED"; else $(PRINTF) "\t\t%s\n" "OK"; fi
  794. rewrite_vlandel:
  795. $(PRINTF) "%s" "[tcprewrite] VLAN Delete test: "
  796. $(PRINTF) "%s\n" "*** [tcprewrite] VLAN Delete test: " >>test.log
  797. $(TCPREWRITE) $(ENABLE_DEBUG) -i test.rewrite_config -o test.$@1 \
  798. --enet-vlan=del >>test.log 2>&1
  799. @WORDS_BIGENDIAN_TRUE@ diff test.$@ test.$@1 >>test.log 2>&1
  800. @WORDS_BIGENDIAN_FALSE@ diff test2.$@ test.$@1 >>test.log 2>&1
  801. if [ $? ] ; then $(PRINTF) "\t\t\t%s\n" "FAILED"; else $(PRINTF) "\t\t\t%s\n" "OK"; fi
  802. rewrite_efcs:
  803. $(PRINTF) "%s" "[tcprewrite] Remove EFCS: "
  804. $(PRINTF) "%s\n" "*** [tcprewrite] Remove EFCS: " >>test.log
  805. $(TCPREWRITE) $(ENABLE_DEBUG) -i test.pcap -o test.$@1 --efcs >>test.log 2>&1
  806. @WORDS_BIGENDIAN_TRUE@ diff test.$@ test.$@1 >>test.log 2>&1
  807. @WORDS_BIGENDIAN_FALSE@ diff test2.$@ test.$@1 >>test.log 2>&1
  808. if [ $? ] ; then $(PRINTF) "\t\t\t%s\n" "FAILED"; else $(PRINTF) "\t\t\t%s\n" "OK"; fi
  809. rewrite_1ttl:
  810. $(PRINTF) "%s" "[tcprewrite] Force TTL: "
  811. $(PRINTF) "%s\n" "*** [tcprewrite] Force TTL: " >>test.log
  812. $(TCPREWRITE) $(ENABLE_DEBUG) -i test.pcap -o test.$@1 --ttl=58 >>test.log 2>&1
  813. @WORDS_BIGENDIAN_TRUE@ diff test.$@ test.$@1 >>test.log 2>&1
  814. @WORDS_BIGENDIAN_FALSE@ diff test2.$@ test.$@1 >>test.log 2>&1
  815. if [ $? ] ; then $(PRINTF) "\t\t\t%s\n" "FAILED"; else $(PRINTF) "\t\t\t%s\n" "OK"; fi
  816. rewrite_2ttl:
  817. $(PRINTF) "%s" "[tcprewrite] Increase TTL: "
  818. $(PRINTF) "%s\n" "*** [tcprewrite] Increase TTL: " >>test.log
  819. $(TCPREWRITE) $(ENABLE_DEBUG) -i test.pcap -o test.$@1 --ttl=+58 >>test.log 2>&1
  820. @WORDS_BIGENDIAN_TRUE@ diff test.$@ test.$@1 >>test.log 2>&1
  821. @WORDS_BIGENDIAN_FALSE@ diff test2.$@ test.$@1 >>test.log 2>&1
  822. if [ $? ] ; then $(PRINTF) "\t\t\t%s\n" "FAILED"; else $(PRINTF) "\t\t\t%s\n" "OK"; fi
  823. rewrite_3ttl:
  824. $(PRINTF) "%s" "[tcprewrite] Reduce TTL: "
  825. $(PRINTF) "%s\n" "*** [tcprewrite] Reduce TTL: " >>test.log
  826. $(TCPREWRITE) $(ENABLE_DEBUG) -i test.pcap -o test.$@1 --ttl=-58 >>test.log 2>&1
  827. @WORDS_BIGENDIAN_TRUE@ diff test.$@ test.$@1 >>test.log 2>&1
  828. @WORDS_BIGENDIAN_FALSE@ diff test2.$@ test.$@1 >>test.log 2>&1
  829. if [ $? ] ; then $(PRINTF) "\t\t\t%s\n" "FAILED"; else $(PRINTF) "\t\t\t%s\n" "OK"; fi
  830. rewrite_tos:
  831. $(PRINTF) "%s" "[tcprewrite] TOS test: "
  832. $(PRINTF) "%s\n" "*** [tcprewrite] TOS test: " >>test.log
  833. $(TCPREWRITE) $(ENABLE_DEBUG) -i test.pcap -o test.$@1 --tos=50 >>test.log 2>&1
  834. @WORDS_BIGENDIAN_TRUE@ diff test.$@ test.$@1 >>test.log 2>&1
  835. @WORDS_BIGENDIAN_FALSE@ diff test2.$@ test.$@1 >>test.log 2>&1
  836. if [ $? ] ; then $(PRINTF) "\t\t\t\t%s\n" "FAILED"; else $(PRINTF) "\t\t\t\t%s\n" "OK"; fi
  837. rewrite_mtutrunc:
  838. $(PRINTF) "%s" "[tcprewrite] MTU Truncate test: "
  839. $(PRINTF) "%s\n" "*** [tcprewrite] MTU Truncate test: " >>test.log
  840. $(TCPREWRITE) $(ENABLE_DEBUG) -i test.pcap -o test.$@1 --mtu-trunc --mtu=300 >>test.log 2>&1
  841. @WORDS_BIGENDIAN_TRUE@ diff test.$@ test.$@1 >>test.log 2>&1
  842. @WORDS_BIGENDIAN_FALSE@ diff test2.$@ test.$@1 >>test.log 2>&1
  843. if [ $? ] ; then $(PRINTF) "\t\t%s\n" "FAILED"; else $(PRINTF) "\t\t%s\n" "OK"; fi
  844. rewrite_l7fuzzing:
  845. $(PRINTF) "%s" "[tcprewrite] L7 fuzzing test: "
  846. $(PRINTF) "%s\n" "*** [tcprewrite] L7 fuzzing test: " >>test.log
  847. $(TCPREWRITE) $(ENABLE_DEBUG) -i test.pcap -o test.$@1 --fuzz-seed=42 >>test.log 2>&1
  848. @WORDS_BIGENDIAN_TRUE@ diff test.$@ test.$@1 >>test.log 2>&1
  849. @WORDS_BIGENDIAN_FALSE@ diff test2.$@ test.$@1 >>test.log 2>&1
  850. if [ $? ] ; then $(PRINTF) "\t\t%s\n" "FAILED"; else $(PRINTF) "\t\t\t%s\n" "OK"; fi
  851. replay_pps:
  852. $(PRINTF) "%s" "[tcpreplay] Packets/sec test: "
  853. $(PRINTF) "%s\n" "*** [tcpreplay] Packets/sec test: " >>test.log
  854. $(TCPREPLAY) $(ENABLE_DEBUG) -i $(nic1) -p 25 test.pcap >>test.log 2>&1
  855. if [ $? ] ; then $(PRINTF) "\t\t\t%s\n" "FAILED"; else $(PRINTF) "\t\t\t%s\n" "OK"; fi
  856. replay_rate:
  857. $(PRINTF) "%s" "[tcpreplay] Mbps test: "
  858. $(PRINTF) "%s\n" "*** [tcpreplay] Mbps test: " >>test.log
  859. $(TCPREPLAY) $(ENABLE_DEBUG) -i $(nic1) -M 25.0 test.pcap >>test.log 2>&1
  860. if [ $? ] ; then $(PRINTF) "\t\t\t\t%s\n" "FAILED"; else $(PRINTF) "\t\t\t\t%s\n" "OK"; fi
  861. replay_multi:
  862. $(PRINTF) "%s" "[tcpreplay] Multiplier test: "
  863. $(PRINTF) "%s\n" "*** [tcpreplay] Multiplier test: " >>test.log
  864. $(TCPREPLAY) $(ENABLE_DEBUG) -i $(nic1) -x 25.0 test.pcap >>test.log 2>&1
  865. if [ $? ] ; then $(PRINTF) "\t\t\t%s\n" "FAILED"; else $(PRINTF) "\t\t\t%s\n" "OK"; fi
  866. replay_pps_multi:
  867. $(PRINTF) "%s" "[tcpreplay] Packets/sec Multiplier test: "
  868. $(PRINTF) "%s\n" "*** [tcpreplay] Packets/sec Multiplier test: " >>test.log
  869. $(TCPREPLAY) $(ENABLE_DEBUG) -i $(nic1) -p 100 --pps-multi=5 test.pcap >>test.log 2>&1
  870. if [ $? ] ; then $(PRINTF) "\t%s\n" "FAILED"; else $(PRINTF) "\t%s\n" "OK"; fi
  871. replay_top:
  872. $(PRINTF) "%s" "[tcpreplay] Topspeed test: "
  873. $(PRINTF) "%s\n" "*** [tcpreplay] Topspeed test: " >>test.log
  874. $(TCPREPLAY) $(ENABLE_DEBUG) -i $(nic1) -t test.pcap >>test.log 2>&1
  875. if [ $? ] ; then $(PRINTF) "\t\t\t%s\n" "FAILED"; else $(PRINTF) "\t\t\t%s\n" "OK"; fi
  876. replay_precache:
  877. $(PRINTF) "%s" "[tcpreplay] Precache test: "
  878. $(PRINTF) "%s\n" "*** [tcpreplay] Precache test: " >>test.log
  879. $(TCPREPLAY) $(ENABLE_DEBUG) -i $(nic1) --preload-pcap test.pcap >>test.log 2>&1
  880. if [ $? ] ; then $(PRINTF) "\t\t\t%s\n" "FAILED"; else $(PRINTF) "\t\t\t%s\n" "OK"; fi
  881. datadump_mode:
  882. $(PRINTF) "%s" "[tcpreplay] Data dump test: "
  883. $(PRINTF) "%s\n" "*** [tcpreplay] Data dump mode test: " >>test.log
  884. $(TCPREPLAY) $(ENABLE_DEBUG) -D -i $(nic1) -I $(nic2) -w primary.data -W secondary.data -c test.cidr -R test.pcap >>test.log 2>&1
  885. if [ $? ] ; then $(PRINTF) "\t\t\t%s\n" "FAILED"; else $(PRINTF) "\t\t\t%s\n" "OK"; fi
  886. replay_config:
  887. $(PRINTF) "%s" "[tcpreplay] Config file/VLAN add test: "
  888. $(PRINTF) "%s\n" "*** [tcpreplay] Config file/VLAN add test: " >>test.log
  889. $(TCPREPLAY) $(ENABLE_DEBUG) --load-opts=config test.pcap >>test.log 2>&1
  890. if [ $? ] ; then $(PRINTF) "\t\t%s\n" "FAILED"; else $(PRINTF) "\t\t%s\n" "OK"; fi
  891. replay_dualfile:
  892. $(PRINTF) "%s" "[tcpreplay] Dual file test: "
  893. $(PRINTF) "%s\n" "*** [tcpreplay] Dual file test: " >>test.log
  894. $(TCPREPLAY) $(ENABLE_DEBUG) -i $(nic1) -I $(nic2) --dualfile test.pcap test.pcap >>test.log 2>&1
  895. if [ $? ] ; then $(PRINTF) "\t\t\t%s\n" "FAILED"; else $(PRINTF) "\t\t\t%s\n" "OK"; fi
  896. replay_maxsleep:
  897. $(PRINTF) "%s" "[tcpreplay] Maximum sleep test: "
  898. $(PRINTF) "%s\n" "*** [tcpreplay] Maximum sleep test: " >>test.log
  899. $(TCPREPLAY) $(ENABLE_DEBUG) -i $(nic1) --maxsleep=20 test.pcap test.pcap >>test.log 2>&1
  900. if [ $? ] ; then $(PRINTF) "\t\t%s\n" "FAILED"; else $(PRINTF) "\t\t%s\n" "OK"; fi
  901. clean:
  902. rm -f *1 test.log core* *~ primary.data secondary.data
  903. distclean: clean
  904. rm -f Makefile config
  905. maintainer-clean: distclean
  906. # Tell versions [3.59,3.63) of GNU make to not export all variables.
  907. # Otherwise a system limit (for SysV at least) may be exceeded.
  908. .NOEXPORT: