tcpbridge.1 23 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732
  1. .de1 NOP
  2. . it 1 an-trap
  3. . if \\n[.$] \,\\$*\/
  4. ..
  5. .ie t \
  6. .ds B-Font [CB]
  7. .ds I-Font [CI]
  8. .ds R-Font [CR]
  9. .el \
  10. .ds B-Font B
  11. .ds I-Font I
  12. .ds R-Font R
  13. .TH tcpbridge 1 "26 Apr 2017" "tcpbridge" "User Commands"
  14. .\"
  15. .\" DO NOT EDIT THIS FILE (in-mem file)
  16. .\"
  17. .\" It has been AutoGen-ed
  18. .\" From the definitions tcpbridge_opts.def
  19. .\" and the template file agman-cmd.tpl
  20. .SH NAME
  21. \f\*[B-Font]tcpbridge\fP
  22. \- Bridge network traffic across two interfaces
  23. .SH SYNOPSIS
  24. \f\*[B-Font]tcpbridge\fP
  25. .\" Mixture of short (flag) options and long options
  26. [\f\*[B-Font]\-flags\f[]]
  27. [\f\*[B-Font]\-flag\f[] [\f\*[I-Font]value\f[]]]
  28. [\f\*[B-Font]\-\-option-name\f[][[=| ]\f\*[I-Font]value\f[]]]
  29. .sp \n(Ppu
  30. .ne 2
  31. All arguments must be options.
  32. .sp \n(Ppu
  33. .ne 2
  34. tcpbridge is a tool for selectively briding network traffic across two interfaces
  35. and optionally modifying the packets in between
  36. .SH "DESCRIPTION"
  37. The basic operation of tcpbridge is to be a network bridge between two
  38. subnets. All packets received on one interface are sent via the other.
  39. .sp
  40. Optionally, packets can be edited in a variety of ways according to your needs.
  41. .sp
  42. For more details, please see the Tcpreplay Manual at:
  43. http://tcpreplay.appneta.com
  44. .SH "OPTIONS"
  45. .SS ""
  46. .TP
  47. .NOP \f\*[B-Font]\-r\f[] \f\*[I-Font]string\f[], \f\*[B-Font]\-\-portmap\f[]=\f\*[I-Font]string\f[]
  48. Rewrite TCP/UDP ports.
  49. This option may appear up to \-1 times.
  50. .sp
  51. Specify a list of comma delimited port mappingings consisting of
  52. colon delimited port number pairs. Each colon delimited port pair
  53. consists of the port to match followed by the port number to rewrite.
  54. .sp
  55. Examples:
  56. .nf
  57. \--portmap=80:8000 \--portmap=8080:80 # 80->8000 and 8080->80
  58. \--portmap=8000,8080,88888:80 # 3 different ports become 80
  59. \--portmap=8000-8999:80 # ports 8000 to 8999 become 80
  60. .fi
  61. .TP
  62. .NOP \f\*[B-Font]\-s\f[] \f\*[I-Font]number\f[], \f\*[B-Font]\-\-seed\f[]=\f\*[I-Font]number\f[]
  63. Randomize src/dst IPv4/v6 addresses w/ given seed.
  64. This option may appear up to 1 times.
  65. This option must not appear in combination with any of the following options:
  66. fuzz-seed.
  67. This option takes an integer number as its argument.
  68. .sp
  69. Causes the source and destination IPv4/v6 addresses to be pseudo
  70. randomized but still maintain client/server relationships.
  71. Since the randomization is deterministic based on the seed,
  72. you can reuse the same seed value to recreate the traffic.
  73. .TP
  74. .NOP \f\*[B-Font]\-N\f[] \f\*[I-Font]string\f[], \f\*[B-Font]\-\-pnat\f[]=\f\*[I-Font]string\f[]
  75. Rewrite IPv4/v6 addresses using pseudo-NAT.
  76. This option may appear up to 2 times.
  77. This option must not appear in combination with any of the following options:
  78. srcipmap.
  79. .sp
  80. Takes a comma delimited series of colon delimited CIDR
  81. netblock pairs. Each netblock pair is evaluated in order against
  82. the IP addresses. If the IP address in the packet matches the
  83. first netblock, it is rewritten using the second netblock as a
  84. mask against the high order bits.
  85. .sp
  86. IPv4 Example:
  87. .nf
  88. \--pnat=192.168.0.0/16:10.77.0.0/16,172.16.0.0/12:10.1.0.0/24
  89. .fi
  90. IPv6 Example:
  91. .nf
  92. \--pnat=[2001:db8::/32]:[dead::/16],[2001:db8::/32]:[::ffff:0:0/96]
  93. .fi
  94. .TP
  95. .NOP \f\*[B-Font]\-S\f[] \f\*[I-Font]string\f[], \f\*[B-Font]\-\-srcipmap\f[]=\f\*[I-Font]string\f[]
  96. Rewrite source IPv4/v6 addresses using pseudo-NAT.
  97. This option may appear up to 1 times.
  98. This option must not appear in combination with any of the following options:
  99. pnat.
  100. .sp
  101. Works just like the \--pnat option, but only affects the source IP
  102. addresses in the IPv4/v6 header.
  103. .TP
  104. .NOP \f\*[B-Font]\-D\f[] \f\*[I-Font]string\f[], \f\*[B-Font]\-\-dstipmap\f[]=\f\*[I-Font]string\f[]
  105. Rewrite destination IPv4/v6 addresses using pseudo-NAT.
  106. This option may appear up to 1 times.
  107. This option must not appear in combination with any of the following options:
  108. pnat.
  109. .sp
  110. Works just like the \--pnat option, but only affects the destination IP
  111. addresses in the IPv4/v6 header.
  112. .TP
  113. .NOP \f\*[B-Font]\-e\f[] \f\*[I-Font]string\f[], \f\*[B-Font]\-\-endpoints\f[]=\f\*[I-Font]string\f[]
  114. Rewrite IP addresses to be between two endpoints.
  115. This option may appear up to 1 times.
  116. This option must appear in combination with the following options:
  117. cachefile.
  118. .sp
  119. Takes a pair of colon delimited IPv4/v6 addresses which will be used to rewrite
  120. all traffic to appear to be between the two IP addresses.
  121. .sp
  122. IPv4 Example:
  123. .nf
  124. \--endpoints=172.16.0.1:172.16.0.2
  125. .fi
  126. IPv6 Example:
  127. .nf
  128. \--endpoints=[2001:db8::dead:beef]:[::ffff:0:0:ac:f:0:2]
  129. .fi
  130. .TP
  131. .NOP \f\*[B-Font]\-b\f[], \f\*[B-Font]\-\-skipbroadcast\f[]
  132. Skip rewriting broadcast/multicast IPv4/v6 addresses.
  133. .sp
  134. By default \--seed, \--pnat and \--endpoints will rewrite
  135. broadcast and multicast IPv4/v6 and MAC addresses. Setting this flag
  136. will keep broadcast/multicast IPv4/v6 and MAC addresses from being rewritten.
  137. .TP
  138. .NOP \f\*[B-Font]\-C\f[], \f\*[B-Font]\-\-fixcsum\f[]
  139. Force recalculation of IPv4/TCP/UDP header checksums.
  140. .sp
  141. Causes each IPv4/v6 packet to have their checksums recalculated and
  142. fixed. Automatically enabled for packets modified with \fB--seed\fP,
  143. \fB--pnat\fP, \fB--endpoints\fP or \fB--fixlen\fP.
  144. .TP
  145. .NOP \f\*[B-Font]\-m\f[] \f\*[I-Font]number\f[], \f\*[B-Font]\-\-mtu\f[]=\f\*[I-Font]number\f[]
  146. Override default MTU length (1500 bytes).
  147. This option may appear up to 1 times.
  148. This option takes an integer number as its argument.
  149. The value of
  150. \f\*[I-Font]number\f[]
  151. is constrained to being:
  152. .in +4
  153. .nf
  154. .na
  155. in the range 1 through MAXPACKET
  156. .fi
  157. .in -4
  158. .sp
  159. Override the default 1500 byte MTU size for determining the maximum padding length
  160. (--fixlen=pad) or when truncating (--mtu-trunc).
  161. .TP
  162. .NOP \f\*[B-Font]\-\-mtu\-trunc\f[]
  163. Truncate packets larger then specified MTU.
  164. This option may appear up to 1 times.
  165. .sp
  166. Similar to \--fixlen, this option will truncate data in packets from Layer 3 and above to be
  167. no larger then the MTU.
  168. .TP
  169. .NOP \f\*[B-Font]\-E\f[], \f\*[B-Font]\-\-efcs\f[]
  170. Remove Ethernet checksums (FCS) from end of frames.
  171. .sp
  172. Note, this option is pretty dangerous! We do not actually check to see if a FCS
  173. actually exists in the frame, we just blindly delete the last 4 bytes. Hence,
  174. you should only use this if you know know that your OS provides the FCS when
  175. reading raw packets.
  176. .TP
  177. .NOP \f\*[B-Font]\-\-ttl\f[]=\f\*[I-Font]string\f[]
  178. Modify the IPv4/v6 TTL/Hop Limit.
  179. .sp
  180. Allows you to modify the TTL/Hop Limit of all the IPv4/v6 packets. Specify a number to hard-code
  181. the value or +/-value to increase or decrease by the value provided (limited to 1-255).
  182. .sp
  183. Examples:
  184. .nf
  185. \--ttl=10
  186. \--ttl=+7
  187. \--ttl=-64
  188. .fi
  189. .TP
  190. .NOP \f\*[B-Font]\-\-tos\f[]=\f\*[I-Font]number\f[]
  191. Set the IPv4 TOS/DiffServ/ECN byte.
  192. This option may appear up to 1 times.
  193. This option takes an integer number as its argument.
  194. The value of
  195. \f\*[I-Font]number\f[]
  196. is constrained to being:
  197. .in +4
  198. .nf
  199. .na
  200. in the range 0 through 255
  201. .fi
  202. .in -4
  203. .sp
  204. Allows you to override the TOS (also known as DiffServ/ECN) value in IPv4.
  205. .TP
  206. .NOP \f\*[B-Font]\-\-tclass\f[]=\f\*[I-Font]number\f[]
  207. Set the IPv6 Traffic Class byte.
  208. This option may appear up to 1 times.
  209. This option takes an integer number as its argument.
  210. The value of
  211. \f\*[I-Font]number\f[]
  212. is constrained to being:
  213. .in +4
  214. .nf
  215. .na
  216. in the range 0 through 255
  217. .fi
  218. .in -4
  219. .sp
  220. Allows you to override the IPv6 Traffic Class field.
  221. .TP
  222. .NOP \f\*[B-Font]\-\-flowlabel\f[]=\f\*[I-Font]number\f[]
  223. Set the IPv6 Flow Label.
  224. This option may appear up to 1 times.
  225. This option takes an integer number as its argument.
  226. The value of
  227. \f\*[I-Font]number\f[]
  228. is constrained to being:
  229. .in +4
  230. .nf
  231. .na
  232. in the range 0 through 1048575
  233. .fi
  234. .in -4
  235. .sp
  236. Allows you to override the 20bit IPv6 Flow Label field. Has no effect on IPv4
  237. packets.
  238. .TP
  239. .NOP \f\*[B-Font]\-F\f[] \f\*[I-Font]string\f[], \f\*[B-Font]\-\-fixlen\f[]=\f\*[I-Font]string\f[]
  240. Pad or truncate packet data to match header length.
  241. This option may appear up to 1 times.
  242. .sp
  243. Packets may be truncated during capture if the snaplen is smaller then the
  244. packet. This option allows you to modify the packet to pad the packet back
  245. out to the size stored in the IPv4/v6 header or rewrite the IP header total length
  246. to reflect the stored packet length.
  247. .sp 1
  248. \fBpad\fP
  249. Truncated packets will be padded out so that the packet length matches the
  250. IPv4 total length
  251. .sp 1
  252. \fBtrunc\fP
  253. Truncated packets will have their IPv4 total length field rewritten to match
  254. the actual packet length
  255. .sp 1
  256. \fBdel\fP
  257. Delete the packet
  258. .TP
  259. .NOP \f\*[B-Font]\-\-fuzz\-seed\f[]=\f\*[I-Font]number\f[]
  260. Fuzz 1/8 packet. Edit Bytes, length, or emulate packet drop.
  261. This option takes an integer number as its argument.
  262. The value of
  263. \f\*[I-Font]number\f[]
  264. is constrained to being:
  265. .in +4
  266. .nf
  267. .na
  268. greater than or equal to 0
  269. .fi
  270. .in -4
  271. The default
  272. \f\*[I-Font]number\f[]
  273. for this option is:
  274. .ti +4
  275. 0
  276. .sp
  277. This fuzzing was designed as to test layer 7 protocols such as voip protocols.
  278. It modifies randomly 1 out of 8 packets in order for stateful protocols to cover
  279. more of their code. The random fuzzing actions focus on data start and end
  280. because it often is the part of the data application protocols base their
  281. decisions on.
  282. .sp
  283. Possible fuzzing actions list:
  284. * drop packet
  285. * reduce packet size
  286. * edit packet Bytes:
  287. * Not all Bytes have the same probability of appearance in real life.
  288. Replace with 0x00, 0xFF, or a random byte with equal likelyhook
  289. * Not all Bytes have the same significance in a packet.
  290. Replace the start, the end, or the middle of the packet with equal likelihood.
  291. * do nothing (7 out of 8 packets)
  292. .TP
  293. .NOP \f\*[B-Font]\-\-skipl2broadcast\f[]
  294. Skip rewriting broadcast/multicast Layer 2 addresses.
  295. .sp
  296. By default, editing Layer 2 addresses will rewrite
  297. broadcast and multicast MAC addresses. Setting this flag
  298. will keep broadcast/multicast MAC addresses from being rewritten.
  299. .TP
  300. .NOP \f\*[B-Font]\-\-dlt\f[]=\f\*[I-Font]string\f[]
  301. Override output DLT encapsulation.
  302. This option may appear up to 1 times.
  303. .sp
  304. By default, no DLT (data link type) conversion will be made.
  305. To change the DLT type of the output pcap, select one of the following values:
  306. .sp 1
  307. \fBenet\fP
  308. Ethernet aka DLT_EN10MB
  309. .sp 1
  310. \fBhdlc\fP
  311. Cisco HDLC aka DLT_C_HDLC
  312. .sp 1
  313. \fBjnpr_ether\fP
  314. Juniper Ethernet DLT_C_JNPR_ETHER
  315. .sp 1
  316. \fBpppserial\fP
  317. PPP Serial aka DLT_PPP_SERIAL
  318. .sp 1
  319. \fBuser\fP
  320. User specified Layer 2 header and DLT type
  321. .br
  322. .TP
  323. .NOP \f\*[B-Font]\-\-enet\-dmac\f[]=\f\*[I-Font]string\f[]
  324. Override destination ethernet MAC addresses.
  325. This option may appear up to 1 times.
  326. .sp
  327. Takes a pair of comma deliminated ethernet MAC addresses which
  328. will replace the destination MAC address of outbound packets.
  329. The first MAC address will be used for the server to client traffic
  330. and the optional second MAC address will be used for the client
  331. to server traffic.
  332. .sp
  333. Example:
  334. .nf
  335. \--enet-dmac=00:12:13:14:15:16,00:22:33:44:55:66
  336. .fi
  337. .TP
  338. .NOP \f\*[B-Font]\-\-enet\-smac\f[]=\f\*[I-Font]string\f[]
  339. Override source ethernet MAC addresses.
  340. This option may appear up to 1 times.
  341. .sp
  342. Takes a pair of comma deliminated ethernet MAC addresses which
  343. will replace the source MAC address of outbound packets.
  344. The first MAC address will be used for the server to client traffic
  345. and the optional second MAC address will be used for the client
  346. to server traffic.
  347. .sp
  348. Example:
  349. .nf
  350. \--enet-smac=00:12:13:14:15:16,00:22:33:44:55:66
  351. .fi
  352. .TP
  353. .NOP \f\*[B-Font]\-\-enet\-subsmac\f[]=\f\*[I-Font]string\f[]
  354. Substitute MAC addresses.
  355. This option may appear up to 9999 times.
  356. .sp
  357. Allows you to rewrite ethernet MAC addresses of packets. It takes
  358. comma delimited pair or MACs address and rewrites all occurrences of
  359. the first MAC with the value of the second MAC.
  360. Example:
  361. .nf
  362. \--enet-subsmac=00:12:13:14:15:16,00:22:33:44:55:66
  363. .fi
  364. .TP
  365. .NOP \f\*[B-Font]\-\-enet\-mac\-seed\f[]=\f\*[I-Font]number\f[]
  366. Randomize MAC addresses.
  367. This option may appear up to 1 times.
  368. This option must not appear in combination with any of the following options:
  369. enet-smac, enet-dmac, enet-subsmac.
  370. This option takes an integer number as its argument.
  371. .sp
  372. Allows you to randomize ethernet MAC addresses of packets, mostly
  373. like what \fB--seed\fP option does for IPv4/IPv6 addresses.
  374. .TP
  375. .NOP \f\*[B-Font]\-\-enet\-mac\-seed\-keep\-bytes\f[]=\f\*[I-Font]number\f[]
  376. Randomize MAC addresses.
  377. This option may appear up to 1 times.
  378. This option must appear in combination with the following options:
  379. enet-mac-seed.
  380. This option takes an integer number as its argument.
  381. The value of
  382. \f\*[I-Font]number\f[]
  383. is constrained to being:
  384. .in +4
  385. .nf
  386. .na
  387. in the range 1 through 6
  388. .fi
  389. .in -4
  390. .sp
  391. Keep some bytes untouched when usinging \fB--enet-mac-seed\fP option.
  392. .TP
  393. .NOP \f\*[B-Font]\-\-enet\-vlan\f[]=\f\*[I-Font]string\f[]
  394. Specify ethernet 802.1q VLAN tag mode.
  395. This option may appear up to 1 times.
  396. .sp
  397. Allows you to rewrite ethernet frames to add a 802.1q header to standard 802.3
  398. ethernet headers or remove the 802.1q VLAN tag information.
  399. .sp 1
  400. \fBadd\fP
  401. Rewrites the existing 802.3 ethernet header as an 802.1q VLAN header
  402. .sp 1
  403. \fBdel\fP
  404. Rewrites the existing 802.1q VLAN header as an 802.3 ethernet header
  405. .TP
  406. .NOP \f\*[B-Font]\-\-enet\-vlan\-tag\f[]=\f\*[I-Font]number\f[]
  407. Specify the new ethernet 802.1q VLAN tag value.
  408. This option may appear up to 1 times.
  409. This option must appear in combination with the following options:
  410. enet-vlan.
  411. This option takes an integer number as its argument.
  412. The value of
  413. \f\*[I-Font]number\f[]
  414. is constrained to being:
  415. .in +4
  416. .nf
  417. .na
  418. in the range 0 through 4095
  419. .fi
  420. .in -4
  421. .sp
  422. .TP
  423. .NOP \f\*[B-Font]\-\-enet\-vlan\-cfi\f[]=\f\*[I-Font]number\f[]
  424. Specify the ethernet 802.1q VLAN CFI value.
  425. This option may appear up to 1 times.
  426. This option must appear in combination with the following options:
  427. enet-vlan.
  428. This option takes an integer number as its argument.
  429. The value of
  430. \f\*[I-Font]number\f[]
  431. is constrained to being:
  432. .in +4
  433. .nf
  434. .na
  435. in the range 0 through 1
  436. .fi
  437. .in -4
  438. .sp
  439. .TP
  440. .NOP \f\*[B-Font]\-\-enet\-vlan\-pri\f[]=\f\*[I-Font]number\f[]
  441. Specify the ethernet 802.1q VLAN priority.
  442. This option may appear up to 1 times.
  443. This option must appear in combination with the following options:
  444. enet-vlan.
  445. This option takes an integer number as its argument.
  446. The value of
  447. \f\*[I-Font]number\f[]
  448. is constrained to being:
  449. .in +4
  450. .nf
  451. .na
  452. in the range 0 through 7
  453. .fi
  454. .in -4
  455. .sp
  456. .TP
  457. .NOP \f\*[B-Font]\-\-hdlc\-control\f[]=\f\*[I-Font]number\f[]
  458. Specify HDLC control value.
  459. This option may appear up to 1 times.
  460. This option takes an integer number as its argument.
  461. .sp
  462. The Cisco HDLC header has a 1 byte "control" field. Apparently this should
  463. always be 0, but if you can use any 1 byte value.
  464. .TP
  465. .NOP \f\*[B-Font]\-\-hdlc\-address\f[]=\f\*[I-Font]number\f[]
  466. Specify HDLC address.
  467. This option may appear up to 1 times.
  468. This option takes an integer number as its argument.
  469. .sp
  470. The Cisco HDLC header has a 1 byte "address" field which has two valid
  471. values:
  472. .sp 1
  473. \fB0x0F\fP
  474. Unicast
  475. .sp 1
  476. \fB0xBF\fP
  477. Broadcast
  478. .br
  479. You can however specify any single byte value.
  480. .TP
  481. .NOP \f\*[B-Font]\-\-user\-dlt\f[]=\f\*[I-Font]number\f[]
  482. Set output file DLT type.
  483. This option may appear up to 1 times.
  484. This option takes an integer number as its argument.
  485. .sp
  486. Set the DLT value of the output pcap file.
  487. .TP
  488. .NOP \f\*[B-Font]\-\-user\-dlink\f[]=\f\*[I-Font]string\f[]
  489. Rewrite Data-Link layer with user specified data.
  490. This option may appear up to 2 times.
  491. .sp
  492. Provide a series of comma deliminated hex values which will be
  493. used to rewrite or create the Layer 2 header of the packets.
  494. The first instance of this argument will rewrite both server
  495. and client traffic, but if this argument is specified a second
  496. time, it will be used for the client traffic.
  497. .sp
  498. Example:
  499. .nf
  500. \--user-dlink=01,02,03,04,05,06,00,1A,2B,3C,4D,5E,6F,08,00
  501. .fi
  502. .TP
  503. .NOP \f\*[B-Font]\-d\f[] \f\*[I-Font]number\f[], \f\*[B-Font]\-\-dbug\f[]=\f\*[I-Font]number\f[]
  504. Enable debugging output.
  505. This option may appear up to 1 times.
  506. This option takes an integer number as its argument.
  507. The value of
  508. \f\*[I-Font]number\f[]
  509. is constrained to being:
  510. .in +4
  511. .nf
  512. .na
  513. in the range 0 through 5
  514. .fi
  515. .in -4
  516. The default
  517. \f\*[I-Font]number\f[]
  518. for this option is:
  519. .ti +4
  520. 0
  521. .sp
  522. If configured with \--enable-debug, then you can specify a verbosity
  523. level for debugging output. Higher numbers increase verbosity.
  524. .TP
  525. .NOP \f\*[B-Font]\-i\f[] \f\*[I-Font]string\f[], \f\*[B-Font]\-\-intf1\f[]=\f\*[I-Font]string\f[]
  526. Primary interface (listen in uni-directional mode).
  527. This option may appear up to 1 times.
  528. .sp
  529. .TP
  530. .NOP \f\*[B-Font]\-I\f[] \f\*[I-Font]string\f[], \f\*[B-Font]\-\-intf2\f[]=\f\*[I-Font]string\f[]
  531. Secondary interface (send in uni-directional mode).
  532. This option may appear up to 1 times.
  533. .sp
  534. .TP
  535. .NOP \f\*[B-Font]\-u\f[], \f\*[B-Font]\-\-unidir\f[]
  536. Send and receive in only one direction.
  537. This option may appear up to 1 times.
  538. .sp
  539. Normally, tcpbridge will send and receive traffic in both directions
  540. (bi-directionally). However, if you choose this option, traffic will
  541. be sent uni-directionally.
  542. .TP
  543. .NOP \f\*[B-Font]\-\-listnics\f[]
  544. List available network interfaces and exit.
  545. .sp
  546. .TP
  547. .NOP \f\*[B-Font]\-L\f[] \f\*[I-Font]number\f[], \f\*[B-Font]\-\-limit\f[]=\f\*[I-Font]number\f[]
  548. Limit the number of packets to send.
  549. This option may appear up to 1 times.
  550. This option takes an integer number as its argument.
  551. The value of
  552. \f\*[I-Font]number\f[]
  553. is constrained to being:
  554. .in +4
  555. .nf
  556. .na
  557. greater than or equal to 1
  558. .fi
  559. .in -4
  560. The default
  561. \f\*[I-Font]number\f[]
  562. for this option is:
  563. .ti +4
  564. \-1
  565. .sp
  566. By default, tcpbridge will send packets forever or until Ctrl-C. Alternatively,
  567. you can specify a maximum number of packets to send.
  568. .TP
  569. .NOP \f\*[B-Font]\-M\f[] \f\*[I-Font]string\f[], \f\*[B-Font]\-\-mac\f[]=\f\*[I-Font]string\f[]
  570. MAC addresses of local NIC's.
  571. This option may appear up to 2 times.
  572. .sp
  573. tcpbridge does not support detecting the MAC addresses of the local network
  574. interfaces under Windows. Please specify both MAC addresses of the interfaces
  575. used in the bridge: \-M <intf1 mac> \-M <intf2 mac>
  576. .TP
  577. .NOP \f\*[B-Font]\-x\f[] \f\*[I-Font]string\f[], \f\*[B-Font]\-\-include\f[]=\f\*[I-Font]string\f[]
  578. Include only packets matching rule.
  579. This option may appear up to 1 times.
  580. This option must not appear in combination with any of the following options:
  581. exclude.
  582. .sp
  583. Override default of sending all packets stored in the capture file and only
  584. send packets which match the provided rule. Rules can be one of:
  585. .sp
  586. .sp
  587. .IR "S:<CIDR1>,..."
  588. - Source IP must match specified CIDR(s)
  589. .sp
  590. .IR "D:<CIDR1>,..."
  591. - Destination IP must match specified CIDR(s)
  592. .sp
  593. .IR "B:<CIDR1>,..."
  594. - Both source and destination IP must match specified CIDR(s)
  595. .sp
  596. .IR "E:<CIDR1>,..."
  597. - Either IP must match specified CIDR(s)
  598. .sp
  599. .IR "P:<LIST>"
  600. - Must be one of the listed packets where the list
  601. corresponds to the packet number in the capture file.
  602. .nf
  603. \--include=P:1-5,9,15,72-
  604. .fi
  605. would send packets 1 thru 5, the 9th and 15th packet, and packets 72 until the
  606. end of the file
  607. .sp
  608. .IR "F:'<bpf>'"
  609. - BPF filter. See the \fItcpdump(8)\fP man page for syntax.
  610. .br
  611. .TP
  612. .NOP \f\*[B-Font]\-X\f[] \f\*[I-Font]string\f[], \f\*[B-Font]\-\-exclude\f[]=\f\*[I-Font]string\f[]
  613. Exclude any packet matching this rule.
  614. This option may appear up to 1 times.
  615. This option must not appear in combination with any of the following options:
  616. include.
  617. .sp
  618. Override default of sending all packets stored in the capture file and only
  619. send packets which do not match the provided rule. Rules can be one of:
  620. .sp
  621. .sp
  622. .IR "S:<CIDR1>,..."
  623. - Source IP must not match specified CIDR(s)
  624. .sp
  625. .IR "D:<CIDR1>,..."
  626. - Destination IP must not match specified CIDR(s)
  627. .sp
  628. .IR "B:<CIDR1>,..."
  629. - Both source and destination IP must not match specified CIDR(s)
  630. .sp
  631. .IR "E:<CIDR1>,..."
  632. - Either IP must not match specified CIDR(s)
  633. .sp
  634. .IR "P:<LIST>"
  635. - Must not be one of the listed packets where the list
  636. corresponds to the packet number in the capture file.
  637. .nf
  638. \--exclude=P:1-5,9,15,72-
  639. .fi
  640. would drop packets 1 thru 5, the 9th and 15th packet, and packets 72 until the
  641. end of the file
  642. .br
  643. .TP
  644. .NOP \f\*[B-Font]\-P\f[], \f\*[B-Font]\-\-pid\f[]
  645. Print the PID of tcpbridge at startup.
  646. .sp
  647. .TP
  648. .NOP \f\*[B-Font]\-v\f[], \f\*[B-Font]\-\-verbose\f[]
  649. Print decoded packets via tcpdump to STDOUT.
  650. This option may appear up to 1 times.
  651. .sp
  652. .TP
  653. .NOP \f\*[B-Font]\-A\f[] \f\*[I-Font]string\f[], \f\*[B-Font]\-\-decode\f[]=\f\*[I-Font]string\f[]
  654. Arguments passed to tcpdump decoder.
  655. This option may appear up to 1 times.
  656. This option must appear in combination with the following options:
  657. verbose.
  658. .sp
  659. When enabling verbose mode (\fB-v\fP) you may also specify one or more
  660. additional arguments to pass to \fBtcpdump\fP to modify the way packets
  661. are decoded. By default, \-n and \-l are used. Be sure to
  662. quote the arguments like: \--verbose="-axxx" so that they are not interpreted
  663. by tcpbridge. The following arguments are valid:
  664. [ \-aAeNqRStuvxX ]
  665. [ \-E spi@ipaddr algo:secret,... ]
  666. [ \-s snaplen ]
  667. .TP
  668. .NOP \f\*[B-Font]\-V\f[], \f\*[B-Font]\-\-version\f[]
  669. Print version information.
  670. .sp
  671. .TP
  672. .NOP \f\*[B-Font]\-h\f[], \f\*[B-Font]\-\-less\-help\f[]
  673. Display less usage information and exit.
  674. .sp
  675. .TP
  676. .NOP \f\*[B-Font]\-H\f[], \f\*[B-Font]\-\-help\f[]
  677. Display usage information and exit.
  678. .TP
  679. .NOP \f\*[B-Font]\-\&!\f[], \f\*[B-Font]\-\-more-help\f[]
  680. Pass the extended usage information through a pager.
  681. .TP
  682. .NOP \f\*[B-Font]\-\-save-opts\f[] [=\f\*[I-Font]cfgfile\f[]]
  683. Save the option state to \fIcfgfile\fP. The default is the \fIlast\fP
  684. configuration file listed in the \fBOPTION PRESETS\fP section, below.
  685. The command will exit after updating the config file.
  686. .TP
  687. .NOP \f\*[B-Font]\-\-load-opts\f[]=\f\*[I-Font]cfgfile\f[], \f\*[B-Font]\-\-no-load-opts\f[]
  688. Load options from \fIcfgfile\fP.
  689. The \fIno-load-opts\fP form will disable the loading
  690. of earlier config/rc/ini files. \fI\-\-no-load-opts\fP is handled early,
  691. out of order.
  692. .PP
  693. .SH "OPTION PRESETS"
  694. Any option that is not marked as \fInot presettable\fP may be preset
  695. by loading values from configuration ("RC" or ".INI") file(s).
  696. The \fIhomerc\fP file is "\fI$$/\fP", unless that is a directory.
  697. In that case, the file "\fI.tcpbridgerc\fP"
  698. is searched for within that directory.
  699. .SH "FILES"
  700. See \fBOPTION PRESETS\fP for configuration files.
  701. .SH "EXIT STATUS"
  702. One of the following exit values will be returned:
  703. .TP
  704. .NOP 0 " (EXIT_SUCCESS)"
  705. Successful program execution.
  706. .TP
  707. .NOP 1 " (EXIT_FAILURE)"
  708. The operation failed or the command syntax was not valid.
  709. .TP
  710. .NOP 66 " (EX_NOINPUT)"
  711. A specified configuration file could not be loaded.
  712. .TP
  713. .NOP 70 " (EX_SOFTWARE)"
  714. libopts had an internal operational error. Please report
  715. it to autogen-users@lists.sourceforge.net. Thank you.
  716. .PP
  717. .SH "AUTHORS"
  718. Copyright 2013-2017 Fred Klassen \- AppNeta
  719. Copyright 2000-2012 Aaron Turner
  720. For support please use the tcpreplay-users@lists.sourceforge.net mailing list.
  721. The latest version of this software is always available from:
  722. http://tcpreplay.appneta.com/
  723. .SH "COPYRIGHT"
  724. Copyright (C) 2000-2017 Aaron Turner and Fred Klassen all rights reserved.
  725. This program is released under the terms of the GNU General Public License, version 3 or later.
  726. .SH "BUGS"
  727. Please send bug reports to: tcpreplay-users@lists.sourceforge.net
  728. .SH "NOTES"
  729. This manual page was \fIAutoGen\fP-erated from the \fBtcpbridge\fP
  730. option definitions.