summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBabak Farrokhi <farrokhi@FreeBSD.org>2023-06-19 16:11:44 +0200
committerBabak Farrokhi <farrokhi@FreeBSD.org>2023-06-19 16:11:44 +0200
commitd79923ed556a97cd6e0c45706c599d72b31201f6 (patch)
tree0022acaffbb62130ea05e83cfa01dfb90881717d
parentdevel/phasar: Fix build on 14 by using C++ compiler provided by llvm package (diff)
net-mgmt/fastnetmon: Update to 1.2.5
-rw-r--r--net-mgmt/fastnetmon/Makefile5
-rw-r--r--net-mgmt/fastnetmon/distinfo6
-rw-r--r--net-mgmt/fastnetmon/files/patch-src_fast__endianless.hpp10
-rw-r--r--net-mgmt/fastnetmon/files/patch-src_fast__library.cpp15
-rw-r--r--net-mgmt/fastnetmon/files/patch-src_fast__platform.h.template26
-rw-r--r--net-mgmt/fastnetmon/files/patch-src_fastnetmon.cpp19
-rw-r--r--net-mgmt/fastnetmon/files/patch-src_notify__about__attack.sh8
7 files changed, 9 insertions, 80 deletions
diff --git a/net-mgmt/fastnetmon/Makefile b/net-mgmt/fastnetmon/Makefile
index eb1c8c795456..dc9eb4a446d4 100644
--- a/net-mgmt/fastnetmon/Makefile
+++ b/net-mgmt/fastnetmon/Makefile
@@ -1,7 +1,6 @@
PORTNAME= fastnetmon
-PORTVERSION= 1.2.4
+PORTVERSION= 1.2.5
DISTVERSIONPREFIX= v
-PORTREVISION= 3
CATEGORIES= net-mgmt security
MAINTAINER= farrokhi@FreeBSD.org
@@ -58,7 +57,7 @@ post-patch:
s|"/etc/|"${PREFIX}/etc/|g; s|/root/fastnetmon|${DATADIR}|g' \
${WRKSRC}/src/fastnetmon.conf ${WRKSRC}/src/fastnetmon.cpp
@${REINPLACE_CMD} -e 's|%%PREFIX%%|${PREFIX}|g' \
- ${WRKSRC}/src/man/fastnetmon.8 ${WRKSRC}/src/fast_platform.h.template
+ ${WRKSRC}/src/man/fastnetmon.8
post-install:
${MV} ${STAGEDIR}${PREFIX}/etc/${PORTNAME}.conf \
diff --git a/net-mgmt/fastnetmon/distinfo b/net-mgmt/fastnetmon/distinfo
index ae85613297b9..ef5b9939a04a 100644
--- a/net-mgmt/fastnetmon/distinfo
+++ b/net-mgmt/fastnetmon/distinfo
@@ -1,3 +1,3 @@
-TIMESTAMP = 1677848493
-SHA256 (pavel-odintsov-fastnetmon-v1.2.4_GH0.tar.gz) = 84cd5db0e270f6c268923592eabd5cb0d1689293d9d9f6f0634af548b29f9bb4
-SIZE (pavel-odintsov-fastnetmon-v1.2.4_GH0.tar.gz) = 1056097
+TIMESTAMP = 1686746794
+SHA256 (pavel-odintsov-fastnetmon-v1.2.5_GH0.tar.gz) = d92a1f16e60b6ab6f5c5e023a215570e9352ce9d0c9a9d7209416f8cd0227ae6
+SIZE (pavel-odintsov-fastnetmon-v1.2.5_GH0.tar.gz) = 1383370
diff --git a/net-mgmt/fastnetmon/files/patch-src_fast__endianless.hpp b/net-mgmt/fastnetmon/files/patch-src_fast__endianless.hpp
deleted file mode 100644
index 3b80a205bcde..000000000000
--- a/net-mgmt/fastnetmon/files/patch-src_fast__endianless.hpp
+++ /dev/null
@@ -1,10 +0,0 @@
---- src/fast_endianless.hpp.orig 2023-03-04 15:33:46 UTC
-+++ src/fast_endianless.hpp
-@@ -12,6 +12,7 @@
- // For be64toh and htobe64
- #if defined(__FreeBSD__) || defined(__DragonFly__)
- #include <sys/endian.h>
-+#include <cstdint>
- #endif
-
- // Linux standard functions for endian conversions are ugly because there are no checks about arguments length
diff --git a/net-mgmt/fastnetmon/files/patch-src_fast__library.cpp b/net-mgmt/fastnetmon/files/patch-src_fast__library.cpp
deleted file mode 100644
index 86b2dcd4bb68..000000000000
--- a/net-mgmt/fastnetmon/files/patch-src_fast__library.cpp
+++ /dev/null
@@ -1,15 +0,0 @@
---- src/fast_library.cpp.orig 2023-03-05 11:34:07 UTC
-+++ src/fast_library.cpp
-@@ -1249,7 +1249,11 @@ bool get_interface_number_by_device_name(int socket_fd
- return false;
- }
-
-- interface_number = ifr.ifr_ifindex;
-+ #ifdef __FreeBSD__
-+ interface_number = ifr.ifr_ifru.ifru_index;
-+ #else
-+ interface_number = ifr.ifr_ifindex;
-+ #endif
- #else
- /* Fallback to if_nametoindex(3) otherwise. */
- interface_number = if_nametoindex(interface_name.c_str());
diff --git a/net-mgmt/fastnetmon/files/patch-src_fast__platform.h.template b/net-mgmt/fastnetmon/files/patch-src_fast__platform.h.template
deleted file mode 100644
index bbf14617178a..000000000000
--- a/net-mgmt/fastnetmon/files/patch-src_fast__platform.h.template
+++ /dev/null
@@ -1,26 +0,0 @@
---- src/fast_platform.h.template.orig 2023-03-01 14:23:34 UTC
-+++ src/fast_platform.h.template
-@@ -9,19 +9,19 @@ class FastnetmonPlatformConfigurtion {
- std::string fastnetmon_version = "${FASTNETMON_APPLICATION_VERSION}";
-
- std::string pid_path = "/var/run/fastnetmon.pid";
-- std::string global_config_path = "/etc/fastnetmon.conf";
-+ std::string global_config_path = "%%PREFIX%%/etc/fastnetmon.conf";
-
- std::string log_file_path = "/var/log/fastnetmon.log";
- std::string attack_details_folder = "/var/log/fastnetmon_attacks";
-
- // Default path to notify script
-- std::string notify_script_path = "/usr/local/bin/notify_about_attack.sh";
-+ std::string notify_script_path = "%%PREFIX%%/bin/notify_about_attack.sh";
-
- // Default path to file with networks for whitelising
-- std::string white_list_path = "/etc/networks_whitelist";
-+ std::string white_list_path = "%%PREFIX%%/etc/networks_whitelist";
-
- // Default path to file with all networks listing
-- std::string networks_list_path = "/etc/networks_list";
-+ std::string networks_list_path = "%%PREFIX%%/etc/networks_list";
-
- /* Platform specific paths end */
- };
diff --git a/net-mgmt/fastnetmon/files/patch-src_fastnetmon.cpp b/net-mgmt/fastnetmon/files/patch-src_fastnetmon.cpp
index b0ba26165d1b..0883c1581808 100644
--- a/net-mgmt/fastnetmon/files/patch-src_fastnetmon.cpp
+++ b/net-mgmt/fastnetmon/files/patch-src_fastnetmon.cpp
@@ -1,17 +1,6 @@
---- src/fastnetmon.cpp.orig 2023-03-01 14:23:34 UTC
+--- src/fastnetmon.cpp.orig 2023-05-23 06:20:59 UTC
+++ src/fastnetmon.cpp
-@@ -12,8 +12,8 @@
- #include <unistd.h>
-
- #include <arpa/inet.h>
--#include <net/if_arp.h> // struct arphdr
--#include <netinet/if_ether.h>
-+//#include <net/if_arp.h> // struct arphdr
-+//#include <netinet/if_ether.h>
- #include <netinet/in.h>
- #include <netinet/ip.h>
- #include <netinet/ip_icmp.h>
-@@ -161,7 +161,7 @@ unsigned int stats_thread_initial_call_delay = 30;
+@@ -156,7 +156,7 @@ unsigned int stats_thread_initial_call_delay = 30;
std::string reporting_server = "community-stats.fastnetmon.com";
// Path to temporarily store backtrace when fatal failure happened
@@ -20,7 +9,7 @@
// Each this seconds we will check about available data in bucket
unsigned int check_for_availible_for_processing_packets_buckets = 1;
-@@ -435,7 +435,7 @@ std::string exabgp_community_subnet = "";
+@@ -430,7 +430,7 @@ std::string exabgp_community_subnet = "";
std::string exabgp_community_host = "";
@@ -29,7 +18,7 @@
std::string exabgp_next_hop = "";
// Graphite monitoring
-@@ -519,7 +519,7 @@ void sigpipe_handler_for_popen(int signo) {
+@@ -514,7 +514,7 @@ void sigpipe_handler_for_popen(int signo) {
#ifdef GEOIP
bool geoip_init() {
// load GeoIP ASN database to memory
diff --git a/net-mgmt/fastnetmon/files/patch-src_notify__about__attack.sh b/net-mgmt/fastnetmon/files/patch-src_notify__about__attack.sh
deleted file mode 100644
index dc4a974f3297..000000000000
--- a/net-mgmt/fastnetmon/files/patch-src_notify__about__attack.sh
+++ /dev/null
@@ -1,8 +0,0 @@
---- src/notify_about_attack.sh.orig 2023-03-06 10:33:26 UTC
-+++ src/notify_about_attack.sh
-@@ -1,4 +1,4 @@
--#!/usr/bin/env bash
-+#!/bin/sh
-
- #
- # Hello, lovely FastNetMon customer. I'm really happy to see you here