]> git.ipfire.org Git - thirdparty/openvpn.git/commit
networking: add networking API net_addr_ll_set() and use it on Linux
authorAntonio Quartulli <a@unstable.cc>
Fri, 3 Sep 2021 16:11:12 +0000 (18:11 +0200)
committerGert Doering <gert@greenie.muc.de>
Wed, 29 Sep 2021 17:31:37 +0000 (19:31 +0200)
commite2fded0f72765467fd0d602562bbf41d48c58d39
tree6f2406c5e3f434affeaa2af9f11f49f15a19bbe4
parent35c8281ef20de507dc08637bff02ce7895b48ec6
networking: add networking API net_addr_ll_set() and use it on Linux

When running in TAP mode we may need to set the LL address of the
interface, if requested by the user.

This operation was overlooked when implementing the networking API and
it still relies on iproute/net-tools being installed.

Basically this means that when compiling OpenVPN on a system without
iproute2/net-tools and the user uses the "lladdr" config directive,
OpenVPN will fail to se the LL address of the interface.

With this patch a new API is introduced, it is implemented for both
SITNL and iproute2 backends, and called on Linux (this is a combination
of three patches in master).

Reported-by: Jan Hugo Prins <jprins@betterbe.com>
Signed-off-by: Antonio Quartulli <a@unstable.cc>
Tested-by: Jan Hugo Prins <jprins@betterbe.com>
Acked-by: Gert Doering <gert@greenie.muc.de>
Message-Id: <20210903161113.30498-1-a@unstable.cc>
URL: https://www.mail-archive.com/openvpn-devel@lists.sourceforge.net/msg22792.html
Signed-off-by: Gert Doering <gert@greenie.muc.de>
(cherry picked from commit 98f524cbd58d24d09dee26160d7386d710c3564f)
(cherry picked from commit cb5d29461e6e734a2250b984b8423d39f7b9ddaa)
(cherry picked from commit 7205cdd8508be0ec9a83ea2e012e2a495157cad0)
src/openvpn/init.c
src/openvpn/lladdr.c
src/openvpn/lladdr.h
src/openvpn/misc.h
src/openvpn/networking.h
src/openvpn/networking_iproute2.c
src/openvpn/networking_sitnl.c