summaryrefslogtreecommitdiff
path: root/ldpd/socket.c
AgeCommit message (Collapse)Author
2020-04-08*: Do not cast to the same typeDonatas Abraitis
Signed-off-by: Donatas Abraitis <donatas.abraitis@gmail.com>
2020-03-11ldpd: During code inspection we are mixing data sizesDonald Sharp
As I understand it ldpd was originally developed as a standalone daemon for *BSD land. Then ported to FRR. FRR uses ifindex_t as the base type for the ifindex. Mixing `unsigned short` and `int` and `unsigned int` is going to lead to fun somewhere along the way. Especially when we get to run on a system with ifindex churn( I'm looking at you docker ). Attempt to convert all of ldpd to think of the ifindex as a `ifindex_t`. Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
2020-02-27ldpd: Cleanup set but unused variablesDonald Sharp
There existed some variables set but never used. Clean this up. Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
2019-09-03*: frr_elevate_privs -> frr_with_privsDavid Lamparter
Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
2019-01-16ldpd: fix missing return value in bindanyMark Stapp
One of the socket utilities was missing a return value in one of its ifdef'd paths. Signed-off-by: Mark Stapp <mjs@voltanet.io>
2018-12-21ldpd: add support for FreeBSD IP_BINDANYRafael Zalamena
Add yet another way to setsockopt a socket to listen to a foreign address. Signed-off-by: Rafael Zalamena <rzalamena@opensourcerouting.org>
2018-08-14*: use frr_elevate_privs() (2/2: manual)David Lamparter
Signed-off-by: David Lamparter <equinox@diac24.net>
2018-08-14*: use frr_elevate_privs() (1/2: coccinelle)David Lamparter
Signed-off-by: David Lamparter <equinox@diac24.net>
2018-07-04ldpd: buffer underflow, thread safety (PVS-Studio)F. Aragon
This commit fixes two issues: - memcpy() using containers of different sizes when using addr2sa(), mixing 'struct sockaddr_storage' and 'union sockunion'. - addr2sa() function not being thread safe (using a local static variable as container. Signed-off-by: F. Aragon <paco@voltanet.io>
2017-01-03ldpd: add missing privilege dropping on error pathRenato Westphal
Signed-off-by: Renato Westphal <renato@opensourcerouting.org>
2016-11-25*: create a helper function to set the IP_MULTICAST_LOOP sockoptionRenato Westphal
Signed-off-by: Renato Westphal <renato@opensourcerouting.org>
2016-09-23ldpd: adapt the code for QuaggaRenato Westphal
Signed-off-by: Renato Westphal <renato@opensourcerouting.org>
2016-09-23ldpd: copy original sources from OpenBSD (14/09/2016)Renato Westphal
Signed-off-by: Renato Westphal <renato@opensourcerouting.org>