Browse Source

fastd: update to v19

Signed-off-by: Matthias Schiffer <mschiffer@universe-factory.net>
lilik-openwrt-22.03
Matthias Schiffer 5 years ago
parent
commit
598d4baa02
No known key found for this signature in database GPG Key ID: 16EF3F64CB201D9C
4 changed files with 4 additions and 88 deletions
  1. +0
    -10
      net/fastd/Config.in
  2. +4
    -14
      net/fastd/Makefile
  3. +0
    -35
      net/fastd/patches/0001-resolve-fix-segmentation-fault-with-musl-1.1.20.patch
  4. +0
    -29
      net/fastd/patches/0002-doc-examples-openwrt-fix-init-script-wasn-t-working-.patch

+ 0
- 10
net/fastd/Config.in View File

@ -36,16 +36,6 @@ config FASTD_ENABLE_METHOD_NULL
depends on PACKAGE_fastd depends on PACKAGE_fastd
default y default y
config FASTD_ENABLE_METHOD_XSALSA20_POLY1305
bool "Enable xsalsa20-poly1305 method"
depends on PACKAGE_fastd
default n
config FASTD_ENABLE_CIPHER_AES128_CTR
bool "Enable the AES128-CTR cipher"
depends on PACKAGE_fastd
default n
config FASTD_ENABLE_CIPHER_NULL config FASTD_ENABLE_CIPHER_NULL
bool "Enable the null cipher" bool "Enable the null cipher"


+ 4
- 14
net/fastd/Makefile View File

@ -8,13 +8,13 @@
include $(TOPDIR)/rules.mk include $(TOPDIR)/rules.mk
PKG_NAME:=fastd PKG_NAME:=fastd
PKG_VERSION:=18
PKG_RELEASE:=4
PKG_VERSION:=19
PKG_RELEASE:=1
PKG_MAINTAINER:=Matthias Schiffer <mschiffer@universe-factory.net> PKG_MAINTAINER:=Matthias Schiffer <mschiffer@universe-factory.net>
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.xz PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.xz
PKG_SOURCE_URL:=https://github.com/NeoRaider/fastd/releases/download/v$(PKG_VERSION) PKG_SOURCE_URL:=https://github.com/NeoRaider/fastd/releases/download/v$(PKG_VERSION)
PKG_HASH:=714ff09d7bd75f79783f744f6f8c5af2fe456c8cf876feaa704c205a73e043c9
PKG_HASH:=6054608e2103b634c9d19ecd1ae058d4ec694747047130719db180578729783a
PKG_LICENSE:=BSD-2-Clause PKG_LICENSE:=BSD-2-Clause
PKG_LICENSE_FILES:=COPYRIGHT PKG_LICENSE_FILES:=COPYRIGHT
@ -27,8 +27,6 @@ PKG_CONFIG_DEPENDS:=\
CONFIG_FASTD_ENABLE_METHOD_GENERIC_POLY1305 \ CONFIG_FASTD_ENABLE_METHOD_GENERIC_POLY1305 \
CONFIG_FASTD_ENABLE_METHOD_GENERIC_UMAC \ CONFIG_FASTD_ENABLE_METHOD_GENERIC_UMAC \
CONFIG_FASTD_ENABLE_METHOD_NULL \ CONFIG_FASTD_ENABLE_METHOD_NULL \
CONFIG_FASTD_ENABLE_METHOD_XSALSA20_POLY1305 \
CONFIG_FASTD_ENABLE_CIPHER_AES128_CTR \
CONFIG_FASTD_ENABLE_CIPHER_NULL \ CONFIG_FASTD_ENABLE_CIPHER_NULL \
CONFIG_FASTD_ENABLE_CIPHER_SALSA20 \ CONFIG_FASTD_ENABLE_CIPHER_SALSA20 \
CONFIG_FASTD_ENABLE_CIPHER_SALSA2012 \ CONFIG_FASTD_ENABLE_CIPHER_SALSA2012 \
@ -44,6 +42,7 @@ PKG_CONFIG_DEPENDS:=\
PKG_BUILD_DEPENDS:=nacl PKG_BUILD_DEPENDS:=nacl
PKG_BUILD_PARALLEL:=1
include $(INCLUDE_DIR)/package.mk include $(INCLUDE_DIR)/package.mk
include $(INCLUDE_DIR)/cmake.mk include $(INCLUDE_DIR)/cmake.mk
@ -73,7 +72,6 @@ CMAKE_OPTIONS += \
-DWITH_METHOD_GENERIC_POLY1305:BOOL=FALSE \ -DWITH_METHOD_GENERIC_POLY1305:BOOL=FALSE \
-DWITH_METHOD_GENERIC_UMAC:BOOL=FALSE \ -DWITH_METHOD_GENERIC_UMAC:BOOL=FALSE \
-DWITH_METHOD_NULL:BOOL=FALSE \ -DWITH_METHOD_NULL:BOOL=FALSE \
-DWITH_METHOD_XSALSA20_POLY1305:BOOL=FALSE \
-DWITH_CIPHER_AES128_CTR:BOOL=FALSE \ -DWITH_CIPHER_AES128_CTR:BOOL=FALSE \
-DWITH_CIPHER_NULL:BOOL=FALSE \ -DWITH_CIPHER_NULL:BOOL=FALSE \
-DWITH_CIPHER_SALSA20:BOOL=FALSE \ -DWITH_CIPHER_SALSA20:BOOL=FALSE \
@ -120,14 +118,6 @@ ifeq ($(CONFIG_FASTD_ENABLE_METHOD_NULL),y)
CMAKE_OPTIONS += -DWITH_METHOD_NULL:BOOL=TRUE CMAKE_OPTIONS += -DWITH_METHOD_NULL:BOOL=TRUE
endif endif
ifeq ($(CONFIG_FASTD_ENABLE_METHOD_XSALSA20_POLY1305),y)
CMAKE_OPTIONS += -DWITH_METHOD_XSALSA20_POLY1305:BOOL=TRUE
endif
ifeq ($(CONFIG_FASTD_ENABLE_CIPHER_AES128_CTR),y)
CMAKE_OPTIONS += -DWITH_CIPHER_AES128_CTR:BOOL=TRUE
endif
ifeq ($(CONFIG_FASTD_ENABLE_CIPHER_NULL),y) ifeq ($(CONFIG_FASTD_ENABLE_CIPHER_NULL),y)
CMAKE_OPTIONS += -DWITH_CIPHER_NULL:BOOL=TRUE CMAKE_OPTIONS += -DWITH_CIPHER_NULL:BOOL=TRUE


+ 0
- 35
net/fastd/patches/0001-resolve-fix-segmentation-fault-with-musl-1.1.20.patch View File

@ -1,35 +0,0 @@
From 9710132c04cd378bd36f16a2a3d98d9c4c5fdbac Mon Sep 17 00:00:00 2001
From: David Bauer <mail@david-bauer.net>
Date: Thu, 25 Jul 2019 18:51:25 +0200
Subject: [PATCH] resolve: fix segmentation fault with musl >1.1.20
When compiled with musl >1.1.20, fastd will crash in case it can't
resolve a peers hostname. This is due to a changed implementation of
freeaddrinfo in musl 1.1.21 onwards.
This segfault is fixed by not calling freeaddrinfo in case the supplied
pointer is null.
Signed-off-by: David Bauer <mail@david-bauer.net>
---
src/resolve.c | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/src/resolve.c b/src/resolve.c
index 9bdfa1c..bfd2a59 100644
--- a/src/resolve.c
+++ b/src/resolve.c
@@ -104,7 +104,9 @@ static void * resolve_peer(void *varg) {
fastd_async_enqueue(ASYNC_TYPE_RESOLVE_RETURN, ret, sizeof(fastd_async_resolve_return_t) + n_addr*sizeof(fastd_peer_address_t));
- freeaddrinfo(res);
+ if (res)
+ freeaddrinfo(res);
+
free(arg->hostname);
free(arg);
--
2.20.1

+ 0
- 29
net/fastd/patches/0002-doc-examples-openwrt-fix-init-script-wasn-t-working-.patch View File

@ -1,29 +0,0 @@
From c29b4b0e3cc5bf68129fd0f94f424950b7888deb Mon Sep 17 00:00:00 2001
Message-Id: <c29b4b0e3cc5bf68129fd0f94f424950b7888deb.1567630068.git.mschiffer@universe-factory.net>
From: Wilfried Klaebe <wklaebe@users.noreply.github.com>
Date: Sat, 31 Aug 2019 21:44:13 +0200
Subject: [PATCH] doc: examples/openwrt: fix init script, wasn't working with
two VPNs
If two VPNs were configured via uci, the init script complained about
the peer group of its peers not matching its net.
---
doc/examples/openwrt/fastd.init | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/doc/examples/openwrt/fastd.init b/doc/examples/openwrt/fastd.init
index 15737b403ec2..4ba69ece9887 100644
--- a/doc/examples/openwrt/fastd.init
+++ b/doc/examples/openwrt/fastd.init
@@ -233,7 +233,7 @@ generate_peer_group_config() {
config_get group_parent "$group" parent
[ "$parent" = "$group_parent" ] || return 0
- if [ "$net" != "$peer_net" ]; then
+ if [ "$net" != "$group_net" ]; then
[ -z "$parent" ] || error "warning: the parent of peer group '$group' doesn't match its net, the peer group will be ignored"
return 0
fi
--
2.23.0

Loading…
Cancel
Save