aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--README.md3
-rw-r--r--libs/libndpi-master/Makefile74
-rw-r--r--libs/libndpi/Makefile125
-rw-r--r--net/nDPId-master/Makefile13
-rw-r--r--net/nDPId/Makefile25
-rw-r--r--net/nDPId/patches/001-enable-in-source-build.patch17
-rw-r--r--net/potd/Makefile39
-rw-r--r--utils/tools/Makefile8
8 files changed, 167 insertions, 137 deletions
diff --git a/README.md b/README.md
index 0f7d281..79762c2 100644
--- a/README.md
+++ b/README.md
@@ -26,11 +26,10 @@ Packages
* btop: https://github.com/aristocratos/btop
* rust: https://github.com/Itus-Shield/packages/tree/rust
* rust_host: https://github.com/Itus-Shield/packages/tree/rust_host
- * libndpi-master: https://github.com/ntop/nDPI/commits/master
+ * libndpi: https://github.com/ntop/nDPI/commits/master
* td: https://github.com/tdlib/td
* nDPId: https://github.com/utoni/nDPId
* nDPId-master: https://github.com/utoni/nDPId/commits/main
- * potd: https://github.com/utoni/potd/commits/master
* shadowsocks-libev: https://github.com/shadowsocks/shadowsocks-libev/commits/master
* suricata6: https://github.com/Itus-Shield/packages/tree/suricata6
* suricata-update: https://github.com/Itus-Shield/packages/tree/suricata6
diff --git a/libs/libndpi-master/Makefile b/libs/libndpi-master/Makefile
deleted file mode 100644
index bf020ac..0000000
--- a/libs/libndpi-master/Makefile
+++ /dev/null
@@ -1,74 +0,0 @@
-include $(TOPDIR)/rules.mk
-
-PKG_NAME:=libndpi-master
-PKG_VERSION:=1.0
-PKG_RELEASE:=$(PKT_SOURCE_VERSION)
-
-PKG_SOURCE_PROTO:=git
-PKG_SOURCE_URL:=https://github.com/ntop/nDPI.git
-PKG_SOURCE_VERSION:=f19937c8c9fd4e1c21988f523d9e78b954f6fcc8
-PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)-$(PKG_SOURCE_VERSION).tar.gz
-PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_VERSION)
-
-PKG_MAINTAINER:=Toni Uhlig <matzeton@gmail.com>
-PKG_LICENSE:=LGPL-3.0-or-later
-PKG_LICENSE_FILES:=COPYING
-
-PKG_FIXUP:=autoreconf
-PKG_REMOVE_FILES:=autogen.sh
-PKG_BUILD_DEPENDS:=libpcap
-PKG_BUILD_PARALLEL:=1
-PKG_INSTALL:=0
-
-include $(INCLUDE_DIR)/package.mk
-
-ifeq ($(CONFIG_LIBNDPI_MASTER_GCRYPT),)
-CONFIGURE_ARGS += --disable-gcrypt
-endif
-
-define Package/libndpi-master
- SECTION:=libs
- CATEGORY:=Libraries
- TITLE:=Library for deep-packet inspection (unstable development version)
- URL:=https://github.com/ntop/nDPI
- DEPENDS:=+LIBNDPI_MASTER_GCRYPT:libgcrypt +libpcap +libjson-c
-endef
-
-define Package/libndpi-master/description
- nDPI is an open source LGPLv3 library for deep-packet inspection.
- Based on OpenDPI it includes ntop extensions.
-endef
-
-define Package/libndpi-master/config
-config LIBNDPI_MASTER_GCRYPT
- bool "GCrypt support"
- depends on PACKAGE_libndpi-master
- default n
- help
- This option enables QUIC client hello decryption.
- Disabled by default.
-endef
-
-define Build/Prepare
- $(PKG_UNPACK)
- $(Build/Patch)
- mv $(PKG_BUILD_DIR)/configure.seed $(PKG_BUILD_DIR)/configure.ac
- $(SED) "s/@NDPI_MAJOR@/3/g" \
- -e "s/@NDPI_MINOR@/5/g" \
- -e "s/@NDPI_PATCH@/0/g" \
- -e "s/@NDPI_VERSION_SHORT@/3.5.0/g" \
- -e "s/@FUZZY@/dnl> /g" \
- $(PKG_BUILD_DIR)/configure.ac
-endef
-
-define Build/InstallDev
- $(INSTALL_DIR) $(1)/usr/include/ndpi-master
- $(CP) $(PKG_BUILD_DIR)/src/include/*.h \
- $(1)/usr/include/ndpi-master/
-
- $(INSTALL_DIR) $(1)/usr/lib
- $(CP) $(PKG_BUILD_DIR)/src/lib/libndpi.a \
- $(1)/usr/lib/libndpi-master.a
-endef
-
-$(eval $(call BuildPackage,libndpi-master))
diff --git a/libs/libndpi/Makefile b/libs/libndpi/Makefile
new file mode 100644
index 0000000..3adb191
--- /dev/null
+++ b/libs/libndpi/Makefile
@@ -0,0 +1,125 @@
+#
+# Copyright (C) 2017 OpenWrt.org
+#
+# This is free software, licensed under the GNU General Public License v2.
+# See /LICENSE for more information.
+#
+
+include $(TOPDIR)/rules.mk
+
+PKG_NAME:=libndpi
+PKG_VERSION:=4.4
+PKG_RELEASE:=$(PKT_SOURCE_VERSION)
+
+PKG_SOURCE_PROTO:=git
+PKG_SOURCE_URL:=https://github.com/ntop/nDPI.git
+PKG_SOURCE_VERSION:=678dd61866944eae011fa96f1c6d39d0c201858e
+PKG_MIRROR_HASH:=aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
+PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)-$(PKG_SOURCE_VERSION).tar.gz
+PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_VERSION)
+
+PKG_MAINTAINER:=Banglang Huang <banglang.huang@foxmail.com>, Toni Uhlig <matzeton@googlemail.com>
+PKG_LICENSE:=LGPL-3.0-or-later
+PKG_LICENSE_FILES:=COPYING
+
+PKG_INSTALL:=1
+PKG_FIXUP:=autoreconf
+PKG_REMOVE_FILES:=autogen.sh
+PKG_BUILD_DEPENDS:=libpcap
+PKG_BUILD_PARALLEL:=1
+
+include $(INCLUDE_DIR)/package.mk
+
+ifeq ($(LIBNDPI_NDPIREADER),)
+CONFIGURE_ARGS += --with-only-libndpi
+endif
+
+ifneq ($(CONFIG_LIBNDPI_GCRYPT),)
+CONFIGURE_ARGS += --with-local-libgcrypt
+endif
+
+ifneq ($(CONFIG_LIBNDPI_PCRE),)
+CONFIGURE_ARGS += --with-pcre
+endif
+
+ifneq ($(CONFIG_LIBNDPI_MAXMINDDB),)
+CONFIGURE_ARGS += --with-maxminddb
+endif
+
+define Package/libndpi
+ SECTION:=libs
+ CATEGORY:=Libraries
+ TITLE:=Library for deep-packet inspection
+ URL:=https://github.com/ntop/nDPI
+ DEPENDS:=+LIBNDPI_GCRYPT:libgcrypt +LIBNDPI_PCRE:libpcre +LIBNDPI_MAXMINDDB:libmaxminddb +LIBNDPI_NDPIREADER:libpcap
+endef
+
+define Package/libndpi/description
+ nDPI is an open source LGPLv3 library for deep-packet inspection.
+ Based on OpenDPI it includes ntop extensions.
+endef
+
+define Package/libndpi/config
+config LIBNDPI_NDPIREADER
+ bool "Enable ndpiReader"
+ depends on PACKAGE_libndpi
+ default n
+ help
+ This option builds and installs ndpiReader,
+ an example application that show some nDPI features.
+
+config LIBNDPI_GCRYPT
+ bool "Use host GCrypt"
+ depends on PACKAGE_libndpi
+ default n
+ help
+ This option enables the use of libgcrypt to decrypt QUIC client hello's.
+ If disabled, nDPI will use a builtin lightweight libgcrypt version to
+ decrypt QUIC client hello's.
+ Disabled by default.
+
+config LIBNDPI_PCRE
+ bool "pcre support"
+ depends on PACKAGE_libndpi
+ default n
+ help
+ This option enables the use of regular expressions.
+ Used by nDPI to detect RCE injection.
+ Disabled by default.
+
+config LIBNDPI_MAXMINDDB
+ bool "Maxmind GeoIP support"
+ depends on PACKAGE_libndpi
+ default n
+ help
+ This options enables geographical information processing
+ and serialization based on IP addresses.
+ Disabled by default.
+endef
+
+define Build/InstallDev
+ $(INSTALL_DIR) $(1)/usr/include/ndpi
+ $(CP) $(PKG_BUILD_DIR)/src/include/*.h \
+ $(1)/usr/include/ndpi/
+
+ $(INSTALL_DIR) $(1)/usr/lib
+ $(CP) $(PKG_BUILD_DIR)/src/lib/libndpi.so* \
+ $(1)/usr/lib/
+
+ $(INSTALL_DIR) $(1)/usr/lib/pkgconfig
+ $(CP) $(PKG_BUILD_DIR)/libndpi.pc \
+ $(1)/usr/lib/pkgconfig/
+endef
+
+define Package/libndpi/install
+ $(INSTALL_DIR) $(1)/usr/lib/
+ $(CP) $(PKG_BUILD_DIR)/src/lib/libndpi.so* \
+ $(1)/usr/lib/
+ $(INSTALL_DIR) $(1)/usr/bin/
+ifneq ($(LIBNDPI_NDPIREADER),)
+ $(CP) $(PKG_BUILD_DIR)/example/ndpiReader \
+ $(1)/usr/bin/
+endif
+endef
+
+$(eval $(call BuildPackage,libndpi))
diff --git a/net/nDPId-master/Makefile b/net/nDPId-master/Makefile
index f26f327..5566306 100644
--- a/net/nDPId-master/Makefile
+++ b/net/nDPId-master/Makefile
@@ -1,12 +1,13 @@
include $(TOPDIR)/rules.mk
PKG_NAME:=nDPId-master
-PKG_VERSION:=1.4
+PKG_VERSION:=1.5
PKG_RELEASE:=$(AUTORELEASE)
PKG_SOURCE_PROTO:=git
PKG_SOURCE_URL:=https://github.com/lnslbrty/nDPId.git
-PKG_SOURCE_VERSION:=9e07a57566cc45bf92a845d8cee968d72e0f314e
+PKG_SOURCE_VERSION:=83409e5b79ab224372dd8486249c668b2998a0a4
+PKG_HASH:=aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)-$(PKG_SOURCE_VERSION).tar.gz
PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_VERSION)
@@ -65,14 +66,14 @@ endif
define Build/Prepare
$(PKG_UNPACK)
$(Build/Patch)
- $(SED) 's/^#define NDPI_API_VERSION.*/#define NDPI_API_VERSION 1/' \
- $(PKG_BUILD_DIR)/libnDPI/src/include/ndpi_api.h.in
env \
+ CC="$(TARGET_CC)" \
+ AR="$(TARGET_AR)" \
+ RANLIB="$(TARGET_RANLIB)" \
CFLAGS="$(TARGET_CFLAGS)" \
CPPFLAGS="$(TARGET_CPPFLAGS)" \
LDFLAGS="$(TARGET_LDFLAGS)" \
- CROSS_COMPILE_TRIPLET="$(GNU_TARGET_NAME)" \
- MAKE_PROGRAM="env -uCFLAGS -uCPPFLAGS $(MAKE)" \
+ MAKE_PROGRAM="$(MAKE)" \
$(PKG_BUILD_DIR)/scripts/get-and-build-libndpi.sh
endef
diff --git a/net/nDPId/Makefile b/net/nDPId/Makefile
index 5952ea3..e9b328b 100644
--- a/net/nDPId/Makefile
+++ b/net/nDPId/Makefile
@@ -1,23 +1,27 @@
include $(TOPDIR)/rules.mk
PKG_NAME:=nDPId
-PKG_VERSION:=1.4
+PKG_VERSION:=1.5
PKG_RELEASE:=$(AUTORELEASE)
-PKG_SOURCE:=$(PKG_VERSION).tar.gz
-PKG_SOURCE_URL:=https://github.com/lnslbrty/nDPId/archive/refs/tags
-PKG_HASH:=b2a95d7ea1798e48bccabf879f7327c7cc27db83301dafc483e01bff7dc2b4f4
+#PKG_SOURCE:=$(PKG_VERSION).tar.gz
+#PKG_SOURCE_URL:=https://github.com/lnslbrty/nDPId/archive/refs/tags
+#PKG_HASH:=a512d5fbdcdaef01a0c3ee7f6b8870ac9c6c870e11c1a30b782550e2cd247de7
+
+# 1.5 Release does not work with current libndpi builds.
+PKG_SOURCE_PROTO:=git
+PKG_SOURCE_URL:=https://github.com/lnslbrty/nDPId.git
+PKG_SOURCE_VERSION:=83409e5b79ab224372dd8486249c668b2998a0a4
+PKG_HASH:=aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
+PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)-$(PKG_SOURCE_VERSION).tar.gz
+PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_VERSION)
PKG_MAINTAINER:=Toni
PKG_LICENSE:=GPL-3
PKG_LICENSE_FILES:=COPYING
-PKG_BUILD_DEPENDS:=libndpi-master
CMAKE_INSTALL:=1
-NDPI_STATIC_LIB="$(STAGING_DIR)/usr/lib/libndpi-master.a"
-NDPI_INC="$(STAGING_DIR)/usr/include/ndpi-master"
-
include $(INCLUDE_DIR)/package.mk
include $(INCLUDE_DIR)/cmake.mk
@@ -25,7 +29,7 @@ define Package/nDPId
TITLE:=nDPId is a tiny nDPI based daemons / toolkit
SECTION:=net
CATEGORY:=Network
- DEPENDS:=+libpcap +LIBNDPI_GCRYPT:libgcrypt
+ DEPENDS:=+libpcap +LIBNDPI_GCRYPT:libgcrypt +libndpi
URL:=http://github.com/lnslbrty/nDPId
endef
@@ -46,11 +50,8 @@ endef
CMAKE_OPTIONS += -DBUILD_EXAMPLES=ON
CMAKE_OPTIONS += -DBUILD_NDPI=OFF
-CMAKE_OPTIONS += -DNDPI_NO_PKGCONFIG=ON
CMAKE_OPTIONS += -DENABLE_SANITIZER=OFF
CMAKE_OPTIONS += -DENABLE_MEMORY_PROFILING=OFF
-CMAKE_OPTIONS += -DLIBNDPI_INC="$(NDPI_INC)"
-CMAKE_OPTIONS += -DLIBNDPI_LIB="$(NDPI_STATIC_LIB)"
ifneq ($(CONFIG_LIBNDPI_GCRYPT),)
CMAKE_OPTIONS += -DNDPI_WIDTH_GCRYPT=ON
diff --git a/net/nDPId/patches/001-enable-in-source-build.patch b/net/nDPId/patches/001-enable-in-source-build.patch
new file mode 100644
index 0000000..86432dc
--- /dev/null
+++ b/net/nDPId/patches/001-enable-in-source-build.patch
@@ -0,0 +1,17 @@
+diff --git a/CMakeLists.txt b/CMakeLists.txt
+index 9045237..83f72b3 100644
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -1,12 +1,5 @@
+ cmake_minimum_required(VERSION 3.12.4)
+ project(nDPId C)
+-if("${PROJECT_SOURCE_DIR}" STREQUAL "${PROJECT_BINARY_DIR}")
+- message(FATAL_ERROR "In-source builds are not allowed.\n"
+- "Please remove ${PROJECT_SOURCE_DIR}/CMakeCache.txt\n"
+- "and\n"
+- "${PROJECT_SOURCE_DIR}/CMakeFiles\n"
+- "Create a build directory somewhere and run CMake again.")
+-endif()
+ set(CMAKE_MODULE_PATH ${CMAKE_SOURCE_DIR}/cmake)
+ find_package(PkgConfig REQUIRED)
+
diff --git a/net/potd/Makefile b/net/potd/Makefile
deleted file mode 100644
index 49604fa..0000000
--- a/net/potd/Makefile
+++ /dev/null
@@ -1,39 +0,0 @@
-include $(TOPDIR)/rules.mk
-
-PKG_NAME:=potd
-PKG_VERSION:=1.0
-PKG_RELEASE:=1
-
-PKG_SOURCE_PROTO:=git
-PKG_SOURCE_URL:=https://github.com/lnslbrty/potd.git
-PKG_SOURCE_VERSION:=f8497db5d14eb139820173dccba58989c4f9ca5c
-PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)-$(PKG_SOURCE_VERSION).tar.gz
-PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_VERSION)
-PKG_MIRROR_HASH:=ca26c057cb3de0ddd25a5b91c3daeffcfb692e603d22c4c70c3681db0e5f7f33
-PKG_MAINTAINER:=Toni Uhlig <matzeton@googlemail.com>
-
-PKG_INSTALL:=1
-PKG_FIXUP:=autoreconf
-PKG_BUILD_PARALLEL:=1
-
-include $(INCLUDE_DIR)/package.mk
-
-define Package/potd
- SECTION:=net
- CATEGORY:=Network
- DEPENDS:=+libseccomp +libssh @KERNEL_NAMESPACES @KERNEL_UTS_NS @KERNEL_IPC_NS \
- @KERNEL_PID_NS @KERNEL_NET_NS @KERNEL_CGROUPS @KERNEL_CGROUP_PIDS
- TITLE:=low to medium interactive SSH/TCP honeypot
-endef
-
-define Package/potd/description
- A high scalable low to medium interactive SSH/TCP honeypot using Linux
- Namespaces, capabilities, seccomp, cgroups designed for OpenWrt and IoT devices.
-endef
-
-define Package/potd/install
- $(INSTALL_DIR) $(1)/usr/sbin
- $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/sbin/potd $(1)/usr/sbin/
-endef
-
-$(eval $(call BuildPackage,potd))
diff --git a/utils/tools/Makefile b/utils/tools/Makefile
index cdf06e0..9f79750 100644
--- a/utils/tools/Makefile
+++ b/utils/tools/Makefile
@@ -5,10 +5,10 @@ PKG_VERSION:=1.0
PKG_RELEASE:=$(PKT_SOURCE_VERSION)
PKG_SOURCE_PROTO:=git
-PKG_SOURCE_URL:=git://github.com/lnslbrty/tools.git
-PKG_SOURCE_VERSION:=fcf4582f7967ae17b33bf8649ba55cc73bafc1d3
+PKG_SOURCE_URL:=https://github.com/utoni/tools.git
+PKG_SOURCE_VERSION:=6a7eabbfee8c8df1a21f3da6e0fd5643c40ee607
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)-$(PKG_SOURCE_VERSION).tar.gz
-PKG_MIRROR_HASH:=ccff5d4a64af9bc5d67b838c20ef1c85ce9182cf3db69c87755535a0fd972843
+PKG_MIRROR_HASH:=aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_VERSION)
PKG_MAINTAINER:=Toni Uhlig <matzeton@gmail.com>
@@ -38,7 +38,7 @@ endef
define Package/tools/install
$(INSTALL_DIR) $(1)/usr/bin
$(INSTALL_BIN) \
- $(addprefix $(PKG_BUILD_DIR)/,aes asciihexer dummyshell suidcmd scrambler gol) \
+ $(addprefix $(PKG_BUILD_DIR)/,aes asciihexer ascii85 dummyshell suidcmd progressbar gol) \
$(1)/usr/bin/
endef