unetd: update to the latest version

21360a1b1ce6 cli: fix typo
abfebece0af1 wg-linux: ship a copy of linux/wireguard.h
1cbb1a543cb3 pex: reduce unnecessary ping traffic
0c2f39e52d5d pex: remove pex event debug spam
dcf1362c2104 pex: add support for sending/receiving global PEX messages via unix socket
df5f70b8858c ubus: notify on network updates
e58a56697131 add DHT discovery service
be175767bc67 pex: keep active pex hosts after the specified timeout
543e4a3d2ed7 pex: move rx header check to callback function
395659b9c415 pex: move raw ip send code to sendto_rawudp() in utils.c
dda15ea8b3b2 pex: add utility function to get the sockets based on type / address family
e88f2cd4d3f0 utils: add support for passings address family to network_get_endpoint()
639cdcdf6eda pex: add support for figuring out the external data port via STUN servers
9144339ebe1f pex: improve handling of a longer list of PEX hosts
38212218ecdd unet-cli: add DHT support
0d37ca75434d pex: automatically create host entries from incoming endpoint port notifications
035fcc56ef60 host: keep multiple endpoint candidates, one for each type
a089e8ae7504 pex: avoid sending a query to a host more than once every 15 seconds

Signed-off-by: Felix Fietkau <nbd@nbd.name>
This commit is contained in:
Felix Fietkau 2022-09-16 21:11:05 +02:00
parent f8e3d7a4e3
commit 40874f0934
3 changed files with 23 additions and 5 deletions

View File

@ -10,9 +10,9 @@ include $(TOPDIR)/rules.mk
PKG_NAME:=unetd
PKG_SOURCE_PROTO:=git
PKG_SOURCE_URL=$(PROJECT_GIT)/project/unetd.git
PKG_SOURCE_DATE:=2022-09-01
PKG_SOURCE_VERSION:=d7fb9e5b065bf9eecb5bcbcf741b5f89695c5dcc
PKG_MIRROR_HASH:=a693c2b4b4bda5e1e44b493019e8e6e6d39c4048f417b581c801a9931e6b9b39
PKG_SOURCE_DATE:=2022-09-16
PKG_SOURCE_VERSION:=a089e8ae7504e55e05b1a88c3d8d1327460b8d4f
PKG_MIRROR_HASH:=15ebeb7ccf4fae0ac46df638999d51a8150d3b0859232537b80e6dcb03ffb165
PKG_LICENSE:=GPL-2.0
PKG_MAINTAINER:=Felix Fietkau <nbd@nbd.name>
@ -44,6 +44,13 @@ define Package/unetd/config
endef
define Package/unet-dht
SECTION:=net
CATEGORY:=Network
DEPENDS:=unetd
TITLE:=unetd DHT discovery support
endef
define Package/unet-cli
SECTION:=net
CATEGORY:=Network
@ -88,10 +95,19 @@ define Package/unetd/install
$(INSTALL_BIN) ./files/unetd.sh $(1)/lib/netifd/proto
endef
define Package/unet-dht/install
$(INSTALL_DIR) \
$(1)/etc/init.d \
$(1)/usr/sbin
$(INSTALL_BIN) $(PKG_BUILD_DIR)/unet-dht $(1)/usr/sbin
$(INSTALL_BIN) ./files/unet-dht.init $(1)/etc/init.d/unet-dht
endef
define Package/unet-cli/install
$(INSTALL_DIR) $(1)/usr/sbin
$(INSTALL_BIN) $(PKG_BUILD_DIR)/scripts/unet-cli $(1)/usr/sbin
endef
$(eval $(call BuildPackage,unetd))
$(eval $(call BuildPackage,unet-dht))
$(eval $(call BuildPackage,unet-cli))

View File

@ -10,7 +10,7 @@ start_service() {
mkdir -p /var/run/unetd /etc/unetd
procd_open_instance
procd_set_param command "$PROG" -h /var/run/unetd/hosts
procd_set_param command "$PROG" -h /var/run/unetd/hosts -u /var/run/unetd/socket
procd_set_param respawn
procd_set_param limits core="unlimited"
procd_close_instance

View File

@ -16,6 +16,7 @@ proto_unet_init_config() {
proto_config_add_string file
proto_config_add_int keepalive
proto_config_add_string domain
proto_config_add_boolean dht
proto_config_add_array "tunnels:list(string)"
proto_config_add_array "connect:list(string)"
proto_config_add_array "peer_data:list(string)"
@ -28,7 +29,7 @@ proto_unet_setup() {
local config="$1"
local device type key file keepalive domain tunnels
json_get_vars device type auth_key key file keepalive domain
json_get_vars device type auth_key key file keepalive domain dht
json_get_values tunnels tunnels
json_get_values connect connect
json_get_values peer_data peer_data
@ -45,6 +46,7 @@ proto_unet_setup() {
json_add_string key "$key"
json_add_string file "$file"
[ -n "$keepalive" ] && json_add_int keepalive "$keepalive"
[ -n "$dht" ] && json_add_boolean dht "$dht"
json_add_string domain "$domain"
json_add_object tunnels