tcpreplay.html 31 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050
  1. <!-- Creator : groff version 1.18.1 -->
  2. <!-- CreationDate: Wed Dec 22 15:16:48 2004 -->
  3. <html>
  4. <head>
  5. <meta name="generator" content="groff -Thtml, see www.gnu.org">
  6. <meta name="Content-Style" content="text/css">
  7. <title>TCPREPLAY</title>
  8. </head>
  9. <body>
  10. <h1 align=center>TCPREPLAY</h1>
  11. <a href="#NAME">NAME</a><br>
  12. <a href="#SYNTAX">SYNTAX</a><br>
  13. <a href="#DESCRIPTION">DESCRIPTION</a><br>
  14. <a href="#OPTIONS">OPTIONS</a><br>
  15. <a href="#SIGNALS">SIGNALS</a><br>
  16. <a href="#SEE ALSO">SEE ALSO</a><br>
  17. <a href="#AUTHORS">AUTHORS</a><br>
  18. <a href="#AVAILABILITY">AVAILABILITY</a><br>
  19. <a href="#LIMITATIONS">LIMITATIONS</a><br>
  20. <hr>
  21. <a name="NAME"></a>
  22. <h2>NAME</h2>
  23. <!-- INDENTATION -->
  24. <table width="100%" border=0 rules="none" frame="void"
  25. cols="2" cellspacing="0" cellpadding="0">
  26. <tr valign="top" align="left">
  27. <td width="10%"></td>
  28. <td width="89%">
  29. <p>tcpreplay &minus; replay packets back out onto the
  30. network from pcap files</p>
  31. </td>
  32. </table>
  33. <a name="SYNTAX"></a>
  34. <h2>SYNTAX</h2>
  35. <!-- INDENTATION -->
  36. <table width="100%" border=0 rules="none" frame="void"
  37. cols="2" cellspacing="0" cellpadding="0">
  38. <tr valign="top" align="left">
  39. <td width="10%"></td>
  40. <td width="89%">
  41. <p><b>tcpreplay &minus;i</b> <i>intf</i> [ <b>options</b> ]
  42. [ <i>&lt;file1&gt; &lt;file2&gt; ...</i> | &minus; ]</p>
  43. </td>
  44. </table>
  45. <a name="DESCRIPTION"></a>
  46. <h2>DESCRIPTION</h2>
  47. <!-- INDENTATION -->
  48. <table width="100%" border=0 rules="none" frame="void"
  49. cols="2" cellspacing="0" cellpadding="0">
  50. <tr valign="top" align="left">
  51. <td width="10%"></td>
  52. <td width="89%">
  53. <p><b>tcpreplay</b> is a tool for replaying network traffic
  54. from files saved with <b>tcpdump</b> or other tools which
  55. write <b>pcap(3)</b> files.</p>
  56. <!-- INDENTATION -->
  57. <p>The basic operation of <b>tcpreplay</b> is to resend all
  58. packets from the input file(s) at the speed at which they
  59. were recorded, or a specified data rate, up to as fast as
  60. the hardware is capable.</p>
  61. <!-- INDENTATION -->
  62. <p>Optionally, the traffic can be split between two
  63. interfaces, written to files, filtered and edited in various
  64. ways, providing the means to test firewalls, NIDS and other
  65. network devices.</p>
  66. </td>
  67. </table>
  68. <a name="OPTIONS"></a>
  69. <h2>OPTIONS</h2>
  70. <!-- INDENTATION -->
  71. <table width="100%" border=0 rules="none" frame="void"
  72. cols="2" cellspacing="0" cellpadding="0">
  73. <tr valign="top" align="left">
  74. <td width="10%"></td>
  75. <td width="89%">
  76. <p><b>&minus;A or tcpdump_args</b></p></td>
  77. </table>
  78. <!-- INDENTATION -->
  79. <table width="100%" border=0 rules="none" frame="void"
  80. cols="2" cellspacing="0" cellpadding="0">
  81. <tr valign="top" align="left">
  82. <td width="21%"></td>
  83. <td width="77%">
  84. <p>When enabling verbose mode (&minus;v) you may also
  85. specify one or more additional arguments to pass to
  86. <b>tcpdump</b> to modify the way packets are decoded. By
  87. default, &minus;n and &minus;l are used. Be sure to quote
  88. the arguments like: &minus;A &quot;&minus;axxx&quot; so that
  89. they are not interpreted by tcpreplay. The following
  90. arguments are vaild:<br>
  91. [ &minus;aAeNqRStuvxX ]<br>
  92. [ &minus;E spi@ipaddr algo:secret,...]<br>
  93. [ &minus;s snaplen ]</p>
  94. </td>
  95. </table>
  96. <p><b>&minus;c or cachefile</b></p>
  97. <!-- INDENTATION -->
  98. <table width="100%" border=0 rules="none" frame="void"
  99. cols="2" cellspacing="0" cellpadding="0">
  100. <tr valign="top" align="left">
  101. <td width="21%"></td>
  102. <td width="77%">
  103. <p>Specify the <i>tcpprep cache</i> to use to process
  104. packets.</p>
  105. </td>
  106. </table>
  107. <!-- INDENTATION -->
  108. <table width="100%" border=0 rules="none" frame="void"
  109. cols="2" cellspacing="0" cellpadding="0">
  110. <tr valign="top" align="left">
  111. <td width="10%"></td>
  112. <td width="89%">
  113. <p><b>&minus;C or cidr</b></p></td>
  114. </table>
  115. <!-- INDENTATION -->
  116. <table width="100%" border=0 rules="none" frame="void"
  117. cols="2" cellspacing="0" cellpadding="0">
  118. <tr valign="top" align="left">
  119. <td width="21%"></td>
  120. <td width="77%">
  121. <p>Given a list of CIDR networks, packets with a source
  122. address matching an entry in the list are sent out the
  123. primary interface. All other packets are sent via the
  124. secondary interface. CIDR lists are comma&minus;separated
  125. and do not contain spaces, <i>192.168.0.0/28,10.0.0.0/16</i>
  126. and <i>10.1.1.0/29</i>, for example. Overrides the &minus;c
  127. option.</p>
  128. </td>
  129. </table>
  130. <!-- INDENTATION -->
  131. <table width="100%" border=0 rules="none" frame="void"
  132. cols="2" cellspacing="0" cellpadding="0">
  133. <tr valign="top" align="left">
  134. <td width="10%"></td>
  135. <td width="89%">
  136. <p><b>&minus;D or datadump_mode</b></p></td>
  137. </table>
  138. <!-- INDENTATION -->
  139. <table width="100%" border=0 rules="none" frame="void"
  140. cols="2" cellspacing="0" cellpadding="0">
  141. <tr valign="top" align="left">
  142. <td width="21%"></td>
  143. <td width="77%">
  144. <p>When used in conjunction with &minus;w and &minus;W,
  145. rather then dumping the entire packets to the files, only
  146. the layer 7 data is dumped.</p>
  147. </td>
  148. </table>
  149. <!-- INDENTATION -->
  150. <table width="100%" border=0 rules="none" frame="void"
  151. cols="2" cellspacing="0" cellpadding="0">
  152. <tr valign="top" align="left">
  153. <td width="10%"></td>
  154. <td width="89%">
  155. <p><b>&minus;e or endpoints</b></p></td>
  156. </table>
  157. <!-- INDENTATION -->
  158. <table width="100%" border=0 rules="none" frame="void"
  159. cols="2" cellspacing="0" cellpadding="0">
  160. <tr valign="top" align="left">
  161. <td width="21%"></td>
  162. <td width="77%">
  163. <p>Specifies a pair of IP addresses seperated by a colon
  164. which are then used to rewrite all IP traffic to appear to
  165. be between the two IP&rsquo;s.</p>
  166. </td>
  167. </table>
  168. <!-- TABS -->
  169. <table width="100%" border=0 rules="none" frame="void"
  170. cols="4" cellspacing="0" cellpadding="0">
  171. <tr valign="top" align="left">
  172. <td width="13%"></td>
  173. <td width="2%">
  174. <p><b>&minus;f</b></p>
  175. </td>
  176. <td width="5%"></td>
  177. <td width="77%">
  178. <p>Specify a file that contains configuration options.
  179. Option tokens are listed next to the corresponding
  180. command&minus;line flag.</p>
  181. </td>
  182. </table>
  183. <!-- INDENTATION -->
  184. <table width="100%" border=0 rules="none" frame="void"
  185. cols="2" cellspacing="0" cellpadding="0">
  186. <tr valign="top" align="left">
  187. <td width="10%"></td>
  188. <td width="89%">
  189. <p><b>&minus;F or fixchecksums</b></p></td>
  190. </table>
  191. <!-- INDENTATION -->
  192. <table width="100%" border=0 rules="none" frame="void"
  193. cols="2" cellspacing="0" cellpadding="0">
  194. <tr valign="top" align="left">
  195. <td width="21%"></td>
  196. <td width="77%">
  197. <p>Fixes IP and TCP/UDP checksums in packets.
  198. Auto&minus;forced with &minus;s, &minus;u, &minus;T &minus;N
  199. or &minus;4</p>
  200. </td>
  201. </table>
  202. <!-- TABS -->
  203. <table width="100%" border=0 rules="none" frame="void"
  204. cols="5" cellspacing="0" cellpadding="0">
  205. <tr valign="top" align="left">
  206. <td width="11%"></td>
  207. <td width="2%">
  208. <p><b>&minus;h</b></p>
  209. </td>
  210. <td width="13%"></td>
  211. <td width="25%">
  212. <p>Prints help/usage</p>
  213. </td>
  214. <td width="46%">
  215. </td>
  216. </table>
  217. <!-- INDENTATION -->
  218. <table width="100%" border=0 rules="none" frame="void"
  219. cols="2" cellspacing="0" cellpadding="0">
  220. <tr valign="top" align="left">
  221. <td width="10%"></td>
  222. <td width="89%">
  223. <p><b>&minus;i or intf</b></p></td>
  224. </table>
  225. <!-- INDENTATION -->
  226. <table width="100%" border=0 rules="none" frame="void"
  227. cols="2" cellspacing="0" cellpadding="0">
  228. <tr valign="top" align="left">
  229. <td width="21%"></td>
  230. <td width="77%">
  231. <p>Specify the prmary interface in which to send
  232. packets.</p>
  233. </td>
  234. </table>
  235. <!-- INDENTATION -->
  236. <table width="100%" border=0 rules="none" frame="void"
  237. cols="2" cellspacing="0" cellpadding="0">
  238. <tr valign="top" align="left">
  239. <td width="10%"></td>
  240. <td width="89%">
  241. <p><b>&minus;I or primary_mac</b></p></td>
  242. </table>
  243. <!-- INDENTATION -->
  244. <table width="100%" border=0 rules="none" frame="void"
  245. cols="2" cellspacing="0" cellpadding="0">
  246. <tr valign="top" align="left">
  247. <td width="21%"></td>
  248. <td width="77%">
  249. <p>Specify the <i>destination MAC</i> to use for packets
  250. being sent out the primary interface.</p>
  251. </td>
  252. </table>
  253. <!-- INDENTATION -->
  254. <table width="100%" border=0 rules="none" frame="void"
  255. cols="2" cellspacing="0" cellpadding="0">
  256. <tr valign="top" align="left">
  257. <td width="10%"></td>
  258. <td width="89%">
  259. <p><b>&minus;j or second_intf</b></p></td>
  260. </table>
  261. <!-- INDENTATION -->
  262. <table width="100%" border=0 rules="none" frame="void"
  263. cols="2" cellspacing="0" cellpadding="0">
  264. <tr valign="top" align="left">
  265. <td width="21%"></td>
  266. <td width="77%">
  267. <p>Specify the <i>secondary interface</i> in which to send
  268. packets.</p>
  269. </td>
  270. </table>
  271. <!-- INDENTATION -->
  272. <table width="100%" border=0 rules="none" frame="void"
  273. cols="2" cellspacing="0" cellpadding="0">
  274. <tr valign="top" align="left">
  275. <td width="10%"></td>
  276. <td width="89%">
  277. <p><b>&minus;J or second_mac</b></p></td>
  278. </table>
  279. <!-- INDENTATION -->
  280. <table width="100%" border=0 rules="none" frame="void"
  281. cols="2" cellspacing="0" cellpadding="0">
  282. <tr valign="top" align="left">
  283. <td width="21%"></td>
  284. <td width="77%">
  285. <p>Specify the <i>destination MAC</i> to use for packets
  286. being sent out the secondary interface.</p>
  287. </td>
  288. </table>
  289. <!-- INDENTATION -->
  290. <table width="100%" border=0 rules="none" frame="void"
  291. cols="2" cellspacing="0" cellpadding="0">
  292. <tr valign="top" align="left">
  293. <td width="10%"></td>
  294. <td width="89%">
  295. <p><b>&minus;k or primary_smac</b></p></td>
  296. </table>
  297. <!-- INDENTATION -->
  298. <table width="100%" border=0 rules="none" frame="void"
  299. cols="2" cellspacing="0" cellpadding="0">
  300. <tr valign="top" align="left">
  301. <td width="21%"></td>
  302. <td width="77%">
  303. <p>Specify the <i>source MAC</i> to use for packets being
  304. sent out the primary interface.</p>
  305. </td>
  306. </table>
  307. <!-- INDENTATION -->
  308. <table width="100%" border=0 rules="none" frame="void"
  309. cols="2" cellspacing="0" cellpadding="0">
  310. <tr valign="top" align="left">
  311. <td width="10%"></td>
  312. <td width="89%">
  313. <p><b>&minus;K or second_smac</b></p></td>
  314. </table>
  315. <!-- INDENTATION -->
  316. <table width="100%" border=0 rules="none" frame="void"
  317. cols="2" cellspacing="0" cellpadding="0">
  318. <tr valign="top" align="left">
  319. <td width="21%"></td>
  320. <td width="77%">
  321. <p>Specify the <i>source MAC</i> to use for packets being
  322. sent out the secondary interface.</p>
  323. </td>
  324. </table>
  325. <!-- INDENTATION -->
  326. <table width="100%" border=0 rules="none" frame="void"
  327. cols="2" cellspacing="0" cellpadding="0">
  328. <tr valign="top" align="left">
  329. <td width="10%"></td>
  330. <td width="89%">
  331. <p><b>&minus;l or loop</b></p></td>
  332. </table>
  333. <!-- INDENTATION -->
  334. <table width="100%" border=0 rules="none" frame="void"
  335. cols="2" cellspacing="0" cellpadding="0">
  336. <tr valign="top" align="left">
  337. <td width="21%"></td>
  338. <td width="77%">
  339. <p>Resend the capture file(s) <i>loop count</i> times.
  340. Setting this to 0 (zero) will cause tcpreplay to loop
  341. infinitely.</p>
  342. </td>
  343. </table>
  344. <!-- INDENTATION -->
  345. <table width="100%" border=0 rules="none" frame="void"
  346. cols="2" cellspacing="0" cellpadding="0">
  347. <tr valign="top" align="left">
  348. <td width="10%"></td>
  349. <td width="89%">
  350. <p><b>&minus;L or limit_send</b></p></td>
  351. </table>
  352. <!-- INDENTATION -->
  353. <table width="100%" border=0 rules="none" frame="void"
  354. cols="2" cellspacing="0" cellpadding="0">
  355. <tr valign="top" align="left">
  356. <td width="21%"></td>
  357. <td width="77%">
  358. <p>Causes tcpreplay to exit after sending the specified
  359. number of packets</p>
  360. </td>
  361. </table>
  362. <!-- INDENTATION -->
  363. <table width="100%" border=0 rules="none" frame="void"
  364. cols="2" cellspacing="0" cellpadding="0">
  365. <tr valign="top" align="left">
  366. <td width="10%"></td>
  367. <td width="89%">
  368. <p><b>&minus;m or multiplier</b></p></td>
  369. </table>
  370. <!-- INDENTATION -->
  371. <table width="100%" border=0 rules="none" frame="void"
  372. cols="2" cellspacing="0" cellpadding="0">
  373. <tr valign="top" align="left">
  374. <td width="21%"></td>
  375. <td width="77%">
  376. <p>Resend the packets at a <i>multiple</i> of the speed at
  377. which they were recorded, specified as a
  378. floating&minus;point number.</p>
  379. </td>
  380. </table>
  381. <!-- INDENTATION -->
  382. <table width="100%" border=0 rules="none" frame="void"
  383. cols="2" cellspacing="0" cellpadding="0">
  384. <tr valign="top" align="left">
  385. <td width="10%"></td>
  386. <td width="89%">
  387. <p><b>&minus;M or no_martians</b></p></td>
  388. </table>
  389. <!-- INDENTATION -->
  390. <table width="100%" border=0 rules="none" frame="void"
  391. cols="2" cellspacing="0" cellpadding="0">
  392. <tr valign="top" align="left">
  393. <td width="21%"></td>
  394. <td width="77%">
  395. <p>Disable sending martian packets (source networks: 0/8,
  396. 127/8, 255/8)</p>
  397. </td>
  398. </table>
  399. <!-- INDENTATION -->
  400. <table width="100%" border=0 rules="none" frame="void"
  401. cols="2" cellspacing="0" cellpadding="0">
  402. <tr valign="top" align="left">
  403. <td width="10%"></td>
  404. <td width="89%">
  405. <p><b>&minus;n or not_nosy</b></p></td>
  406. </table>
  407. <!-- INDENTATION -->
  408. <table width="100%" border=0 rules="none" frame="void"
  409. cols="2" cellspacing="0" cellpadding="0">
  410. <tr valign="top" align="left">
  411. <td width="21%"></td>
  412. <td width="77%">
  413. <p>Don&rsquo;t listen in promiscuous mode when sniffing with
  414. &minus;S</p>
  415. </td>
  416. </table>
  417. <!-- INDENTATION -->
  418. <table width="100%" border=0 rules="none" frame="void"
  419. cols="2" cellspacing="0" cellpadding="0">
  420. <tr valign="top" align="left">
  421. <td width="10%"></td>
  422. <td width="89%">
  423. <p><b>&minus;N or nat</b></p></td>
  424. </table>
  425. <!-- INDENTATION -->
  426. <table width="100%" border=0 rules="none" frame="void"
  427. cols="2" cellspacing="0" cellpadding="0">
  428. <tr valign="top" align="left">
  429. <td width="21%"></td>
  430. <td width="77%">
  431. <p>Specify the nat transation table(s) where a table is one
  432. or more pairs of CIDR&rsquo;s seperated by a colon and each
  433. pair is sererated by a comma:<br>
  434. &lt;FROMCIDR1&gt;:&lt;TOCIDR1&gt;,&lt;FROMCIDR2&gt;:&lt;TOCIDR2&gt;<br>
  435. The first instance of this argument is used for the primary
  436. interface while the second instance is used for the
  437. secondary interface. If no second instance of this argument
  438. exists, then the NAT table is used for both.</p>
  439. </td>
  440. </table>
  441. <!-- INDENTATION -->
  442. <table width="100%" border=0 rules="none" frame="void"
  443. cols="2" cellspacing="0" cellpadding="0">
  444. <tr valign="top" align="left">
  445. <td width="10%"></td>
  446. <td width="89%">
  447. <p><b>&minus;o or offset</b></p></td>
  448. </table>
  449. <!-- INDENTATION -->
  450. <table width="100%" border=0 rules="none" frame="void"
  451. cols="2" cellspacing="0" cellpadding="0">
  452. <tr valign="top" align="left">
  453. <td width="21%"></td>
  454. <td width="77%">
  455. <p>Jump to packet at the nearest specified byte offset and
  456. start replaying packets from there.</p>
  457. </td>
  458. </table>
  459. <!-- INDENTATION -->
  460. <table width="100%" border=0 rules="none" frame="void"
  461. cols="2" cellspacing="0" cellpadding="0">
  462. <tr valign="top" align="left">
  463. <td width="10%"></td>
  464. <td width="89%">
  465. <p><b>&minus;O or one_output</b></p></td>
  466. </table>
  467. <!-- INDENTATION -->
  468. <table width="100%" border=0 rules="none" frame="void"
  469. cols="2" cellspacing="0" cellpadding="0">
  470. <tr valign="top" align="left">
  471. <td width="21%"></td>
  472. <td width="77%">
  473. <p>Processes packets internally for dual interfaces/files
  474. for purposes of NAT and MAC rewriting, but only write
  475. packets to a single interface or file.</p>
  476. </td>
  477. </table>
  478. <!-- INDENTATION -->
  479. <table width="100%" border=0 rules="none" frame="void"
  480. cols="2" cellspacing="0" cellpadding="0">
  481. <tr valign="top" align="left">
  482. <td width="10%"></td>
  483. <td width="89%">
  484. <p><b>&minus;p or packetrate</b></p></td>
  485. </table>
  486. <!-- INDENTATION -->
  487. <table width="100%" border=0 rules="none" frame="void"
  488. cols="2" cellspacing="0" cellpadding="0">
  489. <tr valign="top" align="left">
  490. <td width="21%"></td>
  491. <td width="77%">
  492. <p>Specify the replay rate in packets per second. Negates
  493. all other speed options.</p>
  494. </td>
  495. </table>
  496. <!-- TABS -->
  497. <table width="100%" border=0 rules="none" frame="void"
  498. cols="3" cellspacing="0" cellpadding="0">
  499. <tr valign="top" align="left">
  500. <td width="11%"></td>
  501. <td width="2%">
  502. <p><b>&minus;P</b></p>
  503. </td>
  504. <td width="85%">
  505. </td>
  506. </table>
  507. <!-- INDENTATION -->
  508. <table width="100%" border=0 rules="none" frame="void"
  509. cols="2" cellspacing="0" cellpadding="0">
  510. <tr valign="top" align="left">
  511. <td width="21%"></td>
  512. <td width="77%">
  513. <p>Print the PID of the tcpreplay process at startup. Useful
  514. when wanting to use SIGUSR1 and SIGCONT to
  515. pause/restart.</p>
  516. </td>
  517. </table>
  518. <!-- INDENTATION -->
  519. <table width="100%" border=0 rules="none" frame="void"
  520. cols="2" cellspacing="0" cellpadding="0">
  521. <tr valign="top" align="left">
  522. <td width="10%"></td>
  523. <td width="89%">
  524. <p><b>&minus;r or rate</b></p></td>
  525. </table>
  526. <!-- INDENTATION -->
  527. <table width="100%" border=0 rules="none" frame="void"
  528. cols="2" cellspacing="0" cellpadding="0">
  529. <tr valign="top" align="left">
  530. <td width="21%"></td>
  531. <td width="77%">
  532. <p>Resend the packets at <i>rate</i> megabits
  533. per&minus;second, specified as a floating&minus;point
  534. number.</p>
  535. </td>
  536. </table>
  537. <!-- INDENTATION -->
  538. <table width="100%" border=0 rules="none" frame="void"
  539. cols="2" cellspacing="0" cellpadding="0">
  540. <tr valign="top" align="left">
  541. <td width="10%"></td>
  542. <td width="89%">
  543. <p><b>&minus;R or topspeed</b></p></td>
  544. </table>
  545. <!-- INDENTATION -->
  546. <table width="100%" border=0 rules="none" frame="void"
  547. cols="2" cellspacing="0" cellpadding="0">
  548. <tr valign="top" align="left">
  549. <td width="21%"></td>
  550. <td width="77%">
  551. <p>Resend the packets as fast as possible. Negates all other
  552. speed options.</p>
  553. </td>
  554. </table>
  555. <!-- INDENTATION -->
  556. <table width="100%" border=0 rules="none" frame="void"
  557. cols="2" cellspacing="0" cellpadding="0">
  558. <tr valign="top" align="left">
  559. <td width="10%"></td>
  560. <td width="89%">
  561. <p><b>&minus;s or seed</b></p></td>
  562. </table>
  563. <!-- INDENTATION -->
  564. <table width="100%" border=0 rules="none" frame="void"
  565. cols="2" cellspacing="0" cellpadding="0">
  566. <tr valign="top" align="left">
  567. <td width="21%"></td>
  568. <td width="77%">
  569. <p>Specify a seed value to allow rewriting the source and
  570. destination IP addresses (only in IP header) to
  571. pseudo&minus;random values. Will also recalculate the IP
  572. header as necessary.</p>
  573. </td>
  574. </table>
  575. <!-- INDENTATION -->
  576. <table width="100%" border=0 rules="none" frame="void"
  577. cols="2" cellspacing="0" cellpadding="0">
  578. <tr valign="top" align="left">
  579. <td width="10%"></td>
  580. <td width="89%">
  581. <p><b>&minus;S or sniff_snaplen</b></p></td>
  582. </table>
  583. <!-- INDENTATION -->
  584. <table width="100%" border=0 rules="none" frame="void"
  585. cols="2" cellspacing="0" cellpadding="0">
  586. <tr valign="top" align="left">
  587. <td width="21%"></td>
  588. <td width="77%">
  589. <p>Instead of reading from a saved tcpdump file, perform
  590. live capture. The argument is the number of bytes to capture
  591. off the wire. The name of the capture interface will be the
  592. nominal filename. Please read the FAQ for more
  593. details/warnings about this feature.</p>
  594. </td>
  595. </table>
  596. <!-- INDENTATION -->
  597. <table width="100%" border=0 rules="none" frame="void"
  598. cols="2" cellspacing="0" cellpadding="0">
  599. <tr valign="top" align="left">
  600. <td width="10%"></td>
  601. <td width="89%">
  602. <p><b>&minus;t or mtu</b></p></td>
  603. </table>
  604. <!-- INDENTATION -->
  605. <table width="100%" border=0 rules="none" frame="void"
  606. cols="2" cellspacing="0" cellpadding="0">
  607. <tr valign="top" align="left">
  608. <td width="21%"></td>
  609. <td width="77%">
  610. <p>Specify the MTU in bytes of the interface(s) being used.
  611. Default is 1500 which is standard for 10/100 Ethernet.</p>
  612. </td>
  613. </table>
  614. <!-- INDENTATION -->
  615. <table width="100%" border=0 rules="none" frame="void"
  616. cols="2" cellspacing="0" cellpadding="0">
  617. <tr valign="top" align="left">
  618. <td width="10%"></td>
  619. <td width="89%">
  620. <p><b>&minus;T or truncate</b></p></td>
  621. </table>
  622. <!-- INDENTATION -->
  623. <table width="100%" border=0 rules="none" frame="void"
  624. cols="2" cellspacing="0" cellpadding="0">
  625. <tr valign="top" align="left">
  626. <td width="21%"></td>
  627. <td width="77%">
  628. <p>If a packet is larger then the MTU of the interface, the
  629. frame will be truncated so that it can be sent. With out
  630. this, these frames are skipped. Not to be confused with
  631. &minus;u which pads/truncates packets which are larger then
  632. the snaplen used to capture the packet.</p>
  633. </td>
  634. </table>
  635. <!-- INDENTATION -->
  636. <table width="100%" border=0 rules="none" frame="void"
  637. cols="2" cellspacing="0" cellpadding="0">
  638. <tr valign="top" align="left">
  639. <td width="10%"></td>
  640. <td width="89%">
  641. <p><b>&minus;u or untruncate</b></p></td>
  642. </table>
  643. <!-- INDENTATION -->
  644. <table width="100%" border=0 rules="none" frame="void"
  645. cols="2" cellspacing="0" cellpadding="0">
  646. <tr valign="top" align="left">
  647. <td width="21%"></td>
  648. <td width="77%">
  649. <p>When a packet is truncated in the capture file because
  650. the snaplen was too small, this option will <i>pad</i> the
  651. end of the packet with zeros, or truncate (<i>trunc</i>) it
  652. by re&minus;adjusting the length in the IP header. The
  653. <i>trunc</i> option will only alter IPv4 packets, all others
  654. will be sent unmodified.</p>
  655. </td>
  656. </table>
  657. <!-- INDENTATION -->
  658. <table width="100%" border=0 rules="none" frame="void"
  659. cols="2" cellspacing="0" cellpadding="0">
  660. <tr valign="top" align="left">
  661. <td width="10%"></td>
  662. <td width="89%">
  663. <p><b>&minus;v or verbose</b></p></td>
  664. </table>
  665. <!-- INDENTATION -->
  666. <table width="100%" border=0 rules="none" frame="void"
  667. cols="2" cellspacing="0" cellpadding="0">
  668. <tr valign="top" align="left">
  669. <td width="21%"></td>
  670. <td width="77%">
  671. <p>Verbose mode, dump decoded packets via tcpdump to
  672. STDOUT.</p>
  673. </td>
  674. </table>
  675. <!-- TABS -->
  676. <table width="100%" border=0 rules="none" frame="void"
  677. cols="5" cellspacing="0" cellpadding="0">
  678. <tr valign="top" align="left">
  679. <td width="11%"></td>
  680. <td width="2%">
  681. <p><b>&minus;V</b></p>
  682. </td>
  683. <td width="13%"></td>
  684. <td width="41%">
  685. <p>Print version info and exit.</p>
  686. </td>
  687. <td width="30%">
  688. </td>
  689. </table>
  690. <!-- INDENTATION -->
  691. <table width="100%" border=0 rules="none" frame="void"
  692. cols="2" cellspacing="0" cellpadding="0">
  693. <tr valign="top" align="left">
  694. <td width="10%"></td>
  695. <td width="89%">
  696. <p><b>&minus;w or write</b></p></td>
  697. </table>
  698. <!-- INDENTATION -->
  699. <table width="100%" border=0 rules="none" frame="void"
  700. cols="2" cellspacing="0" cellpadding="0">
  701. <tr valign="top" align="left">
  702. <td width="21%"></td>
  703. <td width="77%">
  704. <p>Specify the output file to write the primary packets to
  705. instead of the network. You still must specify the primary
  706. interface via &minus;i. If &minus;D is set before it, it
  707. will write only the layer 7 data.</p>
  708. </td>
  709. </table>
  710. <!-- INDENTATION -->
  711. <table width="100%" border=0 rules="none" frame="void"
  712. cols="2" cellspacing="0" cellpadding="0">
  713. <tr valign="top" align="left">
  714. <td width="10%"></td>
  715. <td width="89%">
  716. <p><b>&minus;W or secondary_write</b></p></td>
  717. </table>
  718. <!-- INDENTATION -->
  719. <table width="100%" border=0 rules="none" frame="void"
  720. cols="2" cellspacing="0" cellpadding="0">
  721. <tr valign="top" align="left">
  722. <td width="21%"></td>
  723. <td width="77%">
  724. <p>Specify the output file to write the secondary packets to
  725. instead of the network. You still must specify the secondary
  726. interface via &minus;j. If &minus;D is set before it, it
  727. will write only the layer 7 data.</p>
  728. </td>
  729. </table>
  730. <!-- INDENTATION -->
  731. <table width="100%" border=0 rules="none" frame="void"
  732. cols="2" cellspacing="0" cellpadding="0">
  733. <tr valign="top" align="left">
  734. <td width="10%"></td>
  735. <td width="89%">
  736. <p><b>&minus;x or include</b></p></td>
  737. </table>
  738. <!-- INDENTATION -->
  739. <table width="100%" border=0 rules="none" frame="void"
  740. cols="2" cellspacing="0" cellpadding="0">
  741. <tr valign="top" align="left">
  742. <td width="21%"></td>
  743. <td width="77%">
  744. <p>Specifies which packets from the capture file(s) to send.
  745. Can be one of:</p>
  746. </td>
  747. </table>
  748. <!-- INDENTATION -->
  749. <table width="100%" border=0 rules="none" frame="void"
  750. cols="2" cellspacing="0" cellpadding="0">
  751. <tr valign="top" align="left">
  752. <td width="10%"></td>
  753. <td width="89%">
  754. <p>S:&lt;CIDR1&gt;,... Src IP must match specified
  755. CIDR(s)</p></td>
  756. </table>
  757. <!-- INDENTATION -->
  758. <table width="100%" border=0 rules="none" frame="void"
  759. cols="2" cellspacing="0" cellpadding="0">
  760. <tr valign="top" align="left">
  761. <td width="10%"></td>
  762. <td width="89%">
  763. <p>D:&lt;CIDR1&gt;,... Dst IP must match specified
  764. CIDR(s)</p></td>
  765. </table>
  766. <!-- INDENTATION -->
  767. <table width="100%" border=0 rules="none" frame="void"
  768. cols="2" cellspacing="0" cellpadding="0">
  769. <tr valign="top" align="left">
  770. <td width="10%"></td>
  771. <td width="89%">
  772. <p>B:&lt;CIDR1&gt;,... Both src and dst addresses must
  773. match</p></td>
  774. </table>
  775. <!-- INDENTATION -->
  776. <table width="100%" border=0 rules="none" frame="void"
  777. cols="2" cellspacing="0" cellpadding="0">
  778. <tr valign="top" align="left">
  779. <td width="10%"></td>
  780. <td width="89%">
  781. <p>E:&lt;CIDR1&gt;,... Either src or dst address must
  782. match</p></td>
  783. </table>
  784. <!-- INDENTATION -->
  785. <table width="100%" border=0 rules="none" frame="void"
  786. cols="2" cellspacing="0" cellpadding="0">
  787. <tr valign="top" align="left">
  788. <td width="10%"></td>
  789. <td width="89%">
  790. <p>P:&lt;list&gt; Must be one of the listed packets where
  791. the list corresponds to the packet number in the capture
  792. file. Ex: &minus;x P:1&minus;5,9,15 would only send packets
  793. 1 through 5, 9 and 15.</p></td>
  794. </table>
  795. <!-- INDENTATION -->
  796. <table width="100%" border=0 rules="none" frame="void"
  797. cols="2" cellspacing="0" cellpadding="0">
  798. <tr valign="top" align="left">
  799. <td width="10%"></td>
  800. <td width="89%">
  801. <p>F:&quot;&lt;filter&gt;&quot; BPF filter. See the
  802. <b>tcpdump(1)</b> man page for syntax.</p></td>
  803. </table>
  804. <!-- INDENTATION -->
  805. <table width="100%" border=0 rules="none" frame="void"
  806. cols="2" cellspacing="0" cellpadding="0">
  807. <tr valign="top" align="left">
  808. <td width="10%"></td>
  809. <td width="89%">
  810. <p><b>&minus;X or exclude</b></p></td>
  811. </table>
  812. <!-- INDENTATION -->
  813. <table width="100%" border=0 rules="none" frame="void"
  814. cols="2" cellspacing="0" cellpadding="0">
  815. <tr valign="top" align="left">
  816. <td width="21%"></td>
  817. <td width="77%">
  818. <p>Specifies which packets from the capture file(s) to NOT
  819. send. Can be one of:</p>
  820. </td>
  821. </table>
  822. <!-- INDENTATION -->
  823. <table width="100%" border=0 rules="none" frame="void"
  824. cols="2" cellspacing="0" cellpadding="0">
  825. <tr valign="top" align="left">
  826. <td width="10%"></td>
  827. <td width="89%">
  828. <p>S:&lt;CIDR1&gt;,... Src IP must match specified
  829. CIDR(s)</p></td>
  830. </table>
  831. <!-- INDENTATION -->
  832. <table width="100%" border=0 rules="none" frame="void"
  833. cols="2" cellspacing="0" cellpadding="0">
  834. <tr valign="top" align="left">
  835. <td width="10%"></td>
  836. <td width="89%">
  837. <p>D:&lt;CIDR1&gt;,... Dst IP must match specified
  838. CIDR(s)</p></td>
  839. </table>
  840. <!-- INDENTATION -->
  841. <table width="100%" border=0 rules="none" frame="void"
  842. cols="2" cellspacing="0" cellpadding="0">
  843. <tr valign="top" align="left">
  844. <td width="10%"></td>
  845. <td width="89%">
  846. <p>B:&lt;CIDR1&gt;,... Both src and dst addresses must
  847. match</p></td>
  848. </table>
  849. <!-- INDENTATION -->
  850. <table width="100%" border=0 rules="none" frame="void"
  851. cols="2" cellspacing="0" cellpadding="0">
  852. <tr valign="top" align="left">
  853. <td width="10%"></td>
  854. <td width="89%">
  855. <p>E:&lt;CIDR1&gt;,... Either src or dst address must
  856. match</p></td>
  857. </table>
  858. <!-- INDENTATION -->
  859. <table width="100%" border=0 rules="none" frame="void"
  860. cols="2" cellspacing="0" cellpadding="0">
  861. <tr valign="top" align="left">
  862. <td width="10%"></td>
  863. <td width="89%">
  864. <p>P:&lt;list&gt; Must be one of the listed packets where
  865. the list corresponds to the packet number in the capture
  866. file. Ex: &minus;X P:1&minus;5,9,15 would send all packets
  867. except 1 through 5, 9 and 15.</p></td>
  868. </table>
  869. <!-- INDENTATION -->
  870. <table width="100%" border=0 rules="none" frame="void"
  871. cols="2" cellspacing="0" cellpadding="0">
  872. <tr valign="top" align="left">
  873. <td width="10%"></td>
  874. <td width="89%">
  875. <p><b>&minus;1 or one_at_a_time</b></p></td>
  876. </table>
  877. <!-- INDENTATION -->
  878. <table width="100%" border=0 rules="none" frame="void"
  879. cols="2" cellspacing="0" cellpadding="0">
  880. <tr valign="top" align="left">
  881. <td width="21%"></td>
  882. <td width="77%">
  883. <p>Resend one packet at a time, once for each keypress.</p>
  884. </td>
  885. </table>
  886. <!-- INDENTATION -->
  887. <table width="100%" border=0 rules="none" frame="void"
  888. cols="2" cellspacing="0" cellpadding="0">
  889. <tr valign="top" align="left">
  890. <td width="10%"></td>
  891. <td width="89%">
  892. <p><b>&minus;2 or l2data</b></p></td>
  893. </table>
  894. <!-- INDENTATION -->
  895. <table width="100%" border=0 rules="none" frame="void"
  896. cols="2" cellspacing="0" cellpadding="0">
  897. <tr valign="top" align="left">
  898. <td width="21%"></td>
  899. <td width="77%">
  900. <p>Specifies a string of comma seperated numbers in hex to
  901. be used instead of the Layer 2 header in the packet. Useful
  902. for converting between 802.x types or adding a header when
  903. the pcap file doesn&rsquo;t contain a header (as in the case
  904. of DLT_RAW). Currently this only supports the following
  905. pcap(3) types: DLT_EN10MB, DLT_LINUX_SLL, DLT_CHDLC and
  906. DLT_RAW.</p>
  907. </td>
  908. </table>
  909. <!-- INDENTATION -->
  910. <table width="100%" border=0 rules="none" frame="void"
  911. cols="2" cellspacing="0" cellpadding="0">
  912. <tr valign="top" align="left">
  913. <td width="10%"></td>
  914. <td width="89%">
  915. <p><b>&minus;4 or portmap</b></p></td>
  916. </table>
  917. <!-- INDENTATION -->
  918. <table width="100%" border=0 rules="none" frame="void"
  919. cols="2" cellspacing="0" cellpadding="0">
  920. <tr valign="top" align="left">
  921. <td width="21%"></td>
  922. <td width="77%">
  923. <p>Specify a port mapping, where the mapping looks like:<br>
  924. &lt;FROMPORT1&gt;:&lt;TOPORT1&gt;,&lt;FROMPORT2&gt;:&lt;TOPORT2&gt;<br>
  925. For example, if this mapping was specified:<br>
  926. 80:8080<br>
  927. then any packets with a source or destination port of 80
  928. would be changed to 8080. This option can be specified
  929. multiple times to specify multiple mappings. Mappings are
  930. not transitive: each source or destination port is mapped
  931. only once.</p>
  932. </td>
  933. </table>
  934. <a name="SIGNALS"></a>
  935. <h2>SIGNALS</h2>
  936. <!-- INDENTATION -->
  937. <table width="100%" border=0 rules="none" frame="void"
  938. cols="2" cellspacing="0" cellpadding="0">
  939. <tr valign="top" align="left">
  940. <td width="10%"></td>
  941. <td width="89%">
  942. <p><i>Tcpreplay</i> understands the following signals:</p>
  943. </td>
  944. </table>
  945. <!-- INDENTATION -->
  946. <table width="100%" border=0 rules="none" frame="void"
  947. cols="2" cellspacing="0" cellpadding="0">
  948. <tr valign="top" align="left">
  949. <td width="10%"></td>
  950. <td width="89%">
  951. <p><b>SIGUSR1</b></p></td>
  952. </table>
  953. <!-- INDENTATION -->
  954. <table width="100%" border=0 rules="none" frame="void"
  955. cols="2" cellspacing="0" cellpadding="0">
  956. <tr valign="top" align="left">
  957. <td width="21%"></td>
  958. <td width="77%">
  959. <p>Suspend tcpreplay.</p>
  960. </td>
  961. </table>
  962. <!-- INDENTATION -->
  963. <table width="100%" border=0 rules="none" frame="void"
  964. cols="2" cellspacing="0" cellpadding="0">
  965. <tr valign="top" align="left">
  966. <td width="10%"></td>
  967. <td width="89%">
  968. <p><b>SIGCONT</b></p></td>
  969. </table>
  970. <!-- INDENTATION -->
  971. <table width="100%" border=0 rules="none" frame="void"
  972. cols="2" cellspacing="0" cellpadding="0">
  973. <tr valign="top" align="left">
  974. <td width="21%"></td>
  975. <td width="77%">
  976. <p>Restart tcpreplay after it has been suspended.</p>
  977. </td>
  978. </table>
  979. <a name="SEE ALSO"></a>
  980. <h2>SEE ALSO</h2>
  981. <!-- INDENTATION -->
  982. <table width="100%" border=0 rules="none" frame="void"
  983. cols="2" cellspacing="0" cellpadding="0">
  984. <tr valign="top" align="left">
  985. <td width="10%"></td>
  986. <td width="89%">
  987. <p>tcpdump(1), tcpprep(1), capinfo(1), editcap(1)</p>
  988. </td>
  989. </table>
  990. <a name="AUTHORS"></a>
  991. <h2>AUTHORS</h2>
  992. <!-- INDENTATION -->
  993. <table width="100%" border=0 rules="none" frame="void"
  994. cols="2" cellspacing="0" cellpadding="0">
  995. <tr valign="top" align="left">
  996. <td width="10%"></td>
  997. <td width="89%">
  998. <p>Aaron Turner &lt;aturner@pobox.com&gt;<br>
  999. Matt Undy, Anzen Computing.<br>
  1000. Matt Bing &lt;mbing@nfr.net&gt;</p>
  1001. </td>
  1002. </table>
  1003. <a name="AVAILABILITY"></a>
  1004. <h2>AVAILABILITY</h2>
  1005. <!-- INDENTATION -->
  1006. <table width="100%" border=0 rules="none" frame="void"
  1007. cols="2" cellspacing="0" cellpadding="0">
  1008. <tr valign="top" align="left">
  1009. <td width="10%"></td>
  1010. <td width="89%">
  1011. <p>The current version is available via HTTP:</p>
  1012. </td>
  1013. </table>
  1014. <!-- INDENTATION -->
  1015. <table width="100%" border=0 rules="none" frame="void"
  1016. cols="2" cellspacing="0" cellpadding="0">
  1017. <tr valign="top" align="left">
  1018. <td width="20%"></td>
  1019. <td width="79%">
  1020. <p><i>http://www.sourceforge.net/projects/tcpreplay/</i></p></td>
  1021. </table>
  1022. <a name="LIMITATIONS"></a>
  1023. <h2>LIMITATIONS</h2>
  1024. <!-- INDENTATION -->
  1025. <table width="100%" border=0 rules="none" frame="void"
  1026. cols="2" cellspacing="0" cellpadding="0">
  1027. <tr valign="top" align="left">
  1028. <td width="10%"></td>
  1029. <td width="89%">
  1030. <p>Please see the tcpreplay FAQ for a list of limitations
  1031. and any possible work&minus;arounds:
  1032. <i>http://tcpreplay.sourceforge.net/</i></p>
  1033. </td>
  1034. </table>
  1035. <hr>
  1036. </body>
  1037. </html>