2021-01-11 08:54:33 +01:00
|
|
|
{ lib, stdenv, fetchurl, libpcap, tcpdump, Carbon, CoreServices }:
|
2017-05-20 08:51:36 +02:00
|
|
|
|
|
|
|
stdenv.mkDerivation rec {
|
2019-08-15 14:41:18 +02:00
|
|
|
pname = "tcpreplay";
|
2021-05-02 10:33:21 +02:00
|
|
|
version = "4.3.4";
|
2017-05-20 08:51:36 +02:00
|
|
|
|
|
|
|
src = fetchurl {
|
|
|
|
url = "https://github.com/appneta/tcpreplay/releases/download/v${version}/tcpreplay-${version}.tar.gz";
|
2021-05-02 10:33:21 +02:00
|
|
|
sha256 = "sha256-7gZTEIBsIuL9NvAU4euzMbmKfsTblY6Rw9nL2gZA2Sw=";
|
2017-05-20 08:51:36 +02:00
|
|
|
};
|
|
|
|
|
2020-11-18 07:02:58 +01:00
|
|
|
buildInputs = [ libpcap ]
|
2021-01-15 10:19:50 +01:00
|
|
|
++ lib.optionals stdenv.hostPlatform.isDarwin [
|
2020-11-18 07:02:58 +01:00
|
|
|
Carbon CoreServices
|
|
|
|
];
|
|
|
|
|
2017-05-20 08:51:36 +02:00
|
|
|
|
|
|
|
configureFlags = [
|
|
|
|
"--disable-local-libopts"
|
|
|
|
"--disable-libopts-install"
|
|
|
|
"--enable-dynamic-link"
|
|
|
|
"--enable-shared"
|
|
|
|
"--enable-tcpreplay-edit"
|
|
|
|
"--with-libpcap=${libpcap}"
|
|
|
|
"--with-tcpdump=${tcpdump}/bin"
|
|
|
|
];
|
|
|
|
|
2021-01-11 08:54:33 +01:00
|
|
|
meta = with lib; {
|
2017-05-20 08:51:36 +02:00
|
|
|
description = "A suite of utilities for editing and replaying network traffic";
|
2021-05-02 10:33:21 +02:00
|
|
|
homepage = "https://tcpreplay.appneta.com/";
|
|
|
|
license = with licenses; [ bsdOriginalUC gpl3Only ];
|
2017-05-20 08:51:36 +02:00
|
|
|
maintainers = with maintainers; [ eleanor ];
|
2020-11-18 07:02:58 +01:00
|
|
|
platforms = platforms.unix;
|
2017-05-20 08:51:36 +02:00
|
|
|
};
|
|
|
|
}
|