diff options
-rw-r--r-- | net/bird/Makefile | 2 | ||||
-rw-r--r-- | net/bird/files/bird.in | 2 | ||||
-rw-r--r-- | net/bird/files/bird6.in | 2 | ||||
-rw-r--r-- | net/bird/files/firewall_support.patch | 9 | ||||
-rw-r--r-- | net/bird/files/patch-sysdep-bsd-setkey.h | 19 |
5 files changed, 27 insertions, 7 deletions
diff --git a/net/bird/Makefile b/net/bird/Makefile index d1e9ef07dca8..b129b81b820e 100644 --- a/net/bird/Makefile +++ b/net/bird/Makefile @@ -3,7 +3,7 @@ PORTNAME?= bird PORTVERSION= 1.6.3 -PORTREVISION= 1 +PORTREVISION= 2 CATEGORIES= net MASTER_SITES= ftp://bird.network.cz/pub/bird/ \ http://bird.mpls.in/distfiles/bird/ diff --git a/net/bird/files/bird.in b/net/bird/files/bird.in index 9b6bf8f9189d..e2f7223be393 100644 --- a/net/bird/files/bird.in +++ b/net/bird/files/bird.in @@ -29,6 +29,6 @@ extra_commands="reload" : ${bird_enable="NO"} : ${bird_config="%%PREFIX%%/etc/bird.conf"} -command_args="-c $bird_config" +command_args="-P /var/run/${name}.pid -c $bird_config" run_rc_command "$1" diff --git a/net/bird/files/bird6.in b/net/bird/files/bird6.in index 2a19e4a526df..8fab16e013df 100644 --- a/net/bird/files/bird6.in +++ b/net/bird/files/bird6.in @@ -29,6 +29,6 @@ extra_commands="reload" : ${bird6_enable="NO"} : ${bird6_config="%%PREFIX%%/etc/bird6.conf"} -command_args="-c $bird6_config" +command_args="-P /var/run/${name}.pid -c $bird6_config" run_rc_command "$1" diff --git a/net/bird/files/firewall_support.patch b/net/bird/files/firewall_support.patch index 697957d561f9..1d84cfabe8e5 100644 --- a/net/bird/files/firewall_support.patch +++ b/net/bird/files/firewall_support.patch @@ -161,7 +161,7 @@ index 0000000..aefc606 +CF_ADDTO(proto, firewall_proto '}') + +firewall_proto_start: proto_start FIREWALL { -+ this_proto = proto_config_new(&proto_firewall, sizeof(struct firewall_config), $1); ++ this_proto = proto_config_new(&proto_firewall, $1); + this_proto->preference = 0; + FIREWALL_CFG->flush_start = 1; + FIREWALL_CFG->flush_shutdown = 1; @@ -217,7 +217,7 @@ new file mode 100644 index 0000000..e447470 --- /dev/null +++ proto/firewall/firewall.c -@@ -0,0 +1,198 @@ +@@ -0,0 +1,199 @@ +/* + * BIRD -- Firewall Protocol Configuration + * @@ -247,7 +247,7 @@ index 0000000..e447470 +#include "firewall.h" + +static int init_done = 0; -+struct rate_limit rl_fw_err; ++struct tbf rl_fw_err; + +static void +firewall_collect(void) @@ -408,6 +408,7 @@ index 0000000..e447470 + name: "Firewall", + template: "fw%d", + attr_class: EAP_FIREWALL, ++ config_size: sizeof(struct firewall_config), + init: firewall_init, + start: firewall_start, + shutdown: firewall_shutdown, @@ -472,7 +473,7 @@ index 0000000..c97ed38 +extern struct protocol proto_firewall; + +extern struct firewall_control fw_ipfw, fw_pf, fw_ipset; -+extern struct rate_limit rl_fw_err; ++extern struct tbf rl_fw_err; +#define FW_ERR(x, y...) log_rl(&rl_fw_err, L_ERR x, ##y) + +#endif diff --git a/net/bird/files/patch-sysdep-bsd-setkey.h b/net/bird/files/patch-sysdep-bsd-setkey.h new file mode 100644 index 000000000000..9eb12f81e92e --- /dev/null +++ b/net/bird/files/patch-sysdep-bsd-setkey.h @@ -0,0 +1,19 @@ +--- sysdep/bsd/setkey.h 2017-05-15 14:04:47.215628000 +0300 ++++ sysdep/bsd/setkey.h 2017-05-15 14:05:36.850028000 +0300 +@@ -158,12 +158,14 @@ sk_set_md5_in_sasp_db(sock *s, ip_addr local, ip_addr + if (len > TCP_KEYLEN_MAX) + ERR_MSG("The password for TCP MD5 Signature is too long"); + +- if (setkey_md5(&src, &dst, passwd, SADB_ADD) < 0) ++ if (setkey_md5(&src, &dst, passwd, SADB_ADD) < 0 || ++ setkey_md5(&dst, &src, passwd, SADB_ADD) < 0) + ERR_MSG("Cannot add TCP-MD5 password into the IPsec SA/SP database"); + } + else + { +- if (setkey_md5(&src, &dst, NULL, SADB_DELETE) < 0) ++ if (setkey_md5(&src, &dst, NULL, SADB_DELETE) < 0 || ++ setkey_md5(&dst, &src, NULL, SADB_DELETE) < 0) + ERR_MSG("Cannot delete TCP-MD5 password from the IPsec SA/SP database"); + } + return 0; |