summaryrefslogtreecommitdiffstats
path: root/ldpd
diff options
context:
space:
mode:
authorDavid Lamparter <equinox@opensourcerouting.org>2017-08-06 07:35:50 +0200
committerDavid Lamparter <equinox@opensourcerouting.org>2017-08-08 11:14:05 +0200
commit689f5a8c84b95dbd31ecab481f8f2977965fe741 (patch)
tree7c2a2b69908b3c3ac60e0de41b5a3f85caec2ef5 /ldpd
parentMerge pull request #924 from qlyoung/deprecate-ospf-lsa-min-arrival (diff)
downloadfrr-689f5a8c84b95dbd31ecab481f8f2977965fe741.tar.xz
frr-689f5a8c84b95dbd31ecab481f8f2977965fe741.zip
*: remove --enable-tcp-zebra, rework ZAPI path
This adds "@tcp" as new choice on the -z option present in zebra and the protocol daemons. The --enable-tcp-zebra option on configure is no longer needed, both UNIX and TCP socket support is always available. Note that @tcp should not be used by default (e.g. in an init script), and --enable-tcp-zebra should never have been in any distro package builds, because **** TCP-ZEBRA IS A SECURITY PROBLEM **** It allows arbitrary local users to mess with the routing table and inject bogus data -- and also ZAPI is not designed to be robust against attacks. Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
Diffstat (limited to 'ldpd')
-rw-r--r--ldpd/lde.c4
-rw-r--r--ldpd/ldpd.c2
2 files changed, 4 insertions, 2 deletions
diff --git a/ldpd/lde.c b/ldpd/lde.c
index 77643ff48..11fcbfa46 100644
--- a/ldpd/lde.c
+++ b/ldpd/lde.c
@@ -37,6 +37,7 @@
#include "zclient.h"
#include "stream.h"
#include "network.h"
+#include "libfrr.h"
static void lde_shutdown(void);
static int lde_dispatch_imsg(struct thread *);
@@ -170,7 +171,8 @@ lde_init(struct ldpd_init *init)
lde_gc_start_timer();
/* Init synchronous zclient and label list */
- zclient_serv_path_set(init->zclient_serv_path);
+ frr_zclient_addr(&zclient_addr, &zclient_addr_len,
+ init->zclient_serv_path);
zclient_sync_init(init->instance);
lde_label_list_init();
}
diff --git a/ldpd/ldpd.c b/ldpd/ldpd.c
index abcad79d6..abf584484 100644
--- a/ldpd/ldpd.c
+++ b/ldpd/ldpd.c
@@ -256,7 +256,7 @@ main(int argc, char *argv[])
strlcpy(init.user, ldpd_privs.user, sizeof(init.user));
strlcpy(init.group, ldpd_privs.group, sizeof(init.group));
strlcpy(init.ctl_sock_path, ctl_sock_path, sizeof(init.ctl_sock_path));
- strlcpy(init.zclient_serv_path, zclient_serv_path_get(),
+ strlcpy(init.zclient_serv_path, frr_zclientpath,
sizeof(init.zclient_serv_path));
argc -= optind;