import ports/net/neighbot, from Renaud Allard, ok matthieu

Neighbot passively monitors ARP (IPv4) and NDP (IPv6) traffic on all
Ethernet interfaces. It maintains a CSV database of IP-to-MAC address
mappings and sends email alerts when new stations appear or existing
mappings change.

On OpenBSD, neighbot uses pledge(2) and unveil(2) to restrict its
privileges after initialization.
This commit is contained in:
sthen
2026-03-05 11:34:51 +00:00
parent 2bbd08d6b2
commit 8b2cdbe2df
5 changed files with 69 additions and 0 deletions
+34
View File
@@ -0,0 +1,34 @@
COMMENT = network neighbor monitoring daemon
V = 0.5.5
DISTNAME = neighbot-${V}
CATEGORIES = net
HOMEPAGE = https://github.com/renaudallard/neighbot
SITES = https://github.com/renaudallard/neighbot/releases/download/v${V}/
MAINTAINER = Renaud Allard <renaud@allard.it>
# BSD
PERMIT_PACKAGE = Yes
# uses pledge() and unveil()
WANTLIB = c pcap
RUN_DEPENDS = net/arp-scan,-mac
NO_TEST = Yes
MAKE_FLAGS = CC="${CC}" CFLAGS="${CFLAGS}" PREFIX="${PREFIX}"
ALL_TARGET = all
do-install:
${INSTALL_PROGRAM} ${WRKSRC}/neighbot ${PREFIX}/sbin/neighbot
${INSTALL_MAN} ${WRKSRC}/neighbot.8 ${PREFIX}/man/man8/neighbot.8
${INSTALL_DATA_DIR} ${PREFIX}/share/examples/neighbot
${INSTALL_DATA} /dev/null \
${PREFIX}/share/examples/neighbot/neighbot.csv
.include <bsd.port.mk>
+2
View File
@@ -0,0 +1,2 @@
SHA256 (neighbot-0.5.5.tar.gz) = JIuTdzAHXdew/QdcJvt3c5gFBnt+N541dzbOtTXGIhA=
SIZE (neighbot-0.5.5.tar.gz) = 44884
+7
View File
@@ -0,0 +1,7 @@
Neighbot passively monitors ARP (IPv4) and NDP (IPv6) traffic on all
Ethernet interfaces. It maintains a CSV database of IP-to-MAC address
mappings and sends email alerts when new stations appear or existing
mappings change.
On OpenBSD, neighbot uses pledge(2) and unveil(2) to restrict its
privileges after initialization.
+12
View File
@@ -0,0 +1,12 @@
@newgroup _neighbot:904
@newuser _neighbot:904:_neighbot::neighbot daemon:/var/empty:/sbin/nologin
@rcscript ${RCDIR}/neighbot
@man man/man8/neighbot.8
@bin sbin/neighbot
share/examples/neighbot/
@owner _neighbot
@group _neighbot
@sample /var/neighbot/
share/examples/neighbot/neighbot.csv
@mode 644
@sample /var/neighbot/neighbot.csv
+14
View File
@@ -0,0 +1,14 @@
#!/bin/ksh
daemon="${TRUEPREFIX}/sbin/neighbot -d"
daemon_flags="-u _neighbot -o ${TRUEPREFIX}/share/arp-scan/ieee-oui.txt"
. /etc/rc.d/rc.subr
rc_reload=NO
rc_pre() {
install -d -o _neighbot -g _neighbot ${LOCALSTATEDIR}/neighbot
}
rc_cmd $1