https://github.com/vmxdev/net-dup
Send copies of network datagrams to multiple receivers via VXLANs
https://github.com/vmxdev/net-dup
Last synced: 4 months ago
JSON representation
Send copies of network datagrams to multiple receivers via VXLANs
- Host: GitHub
- URL: https://github.com/vmxdev/net-dup
- Owner: vmxdev
- License: isc
- Created: 2024-10-09T19:20:58.000Z (over 1 year ago)
- Default Branch: master
- Last Pushed: 2024-11-28T08:57:48.000Z (over 1 year ago)
- Last Synced: 2024-11-28T09:35:04.747Z (over 1 year ago)
- Language: C
- Size: 6.84 KB
- Stars: 1
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# net-dup
This very simple program receives datagrams on a given network interface using pcap, adds VXLAN header and resends those datagrams to a specified set of receivers.
The receiving side can configure the VXLAN interface and receive datagrams with no source addresses changed.
This can be useful when duplicating Netflow/IPFIX/sFlow datagrams where it is important to know the address of the sending router or switch.
The utility is similar to the well-known [samplicator](https://github.com/sleinen/samplicator) utility, but instead of spoofing source addresses, it delivers the datagram to the receivers via VXLAN "as is".
Note that the receiving side must be able to handle datagrams that are not destined for this host (for example, using pcap). This utility is designed to work with [xenoeye](https://github.com/vmxdev/xenoeye), which can capture `*`flow-datagrams using pcap. But for various reasons we want to distribute the utility separately from xenoeye.
## Compile
```sh
$ cc -g -Wall -pedantic -Wextra netdup.c -o netdup -lpcap
```
## Use
```sh
$ sudo ./netdup -i eth0 -o 1.2.3.4:4789.12345 -f "udp and port 6543"
```