From b521f426ab228b003e1e87348e116291d23dc88b Mon Sep 17 00:00:00 2001 From: Thomas Haller Date: Thu, 27 Dec 2018 16:48:30 +0100 Subject: libnm,cli: add NMSettingWireGuard For now only add the core settings, no peers' data. To support peers and the allowed-ips of the peers is more complicated and will be done later. It's more complicated because these are nested lists (allowed-ips) inside a list (peers). That is quite unusual and to conveniently support that in D-Bus API, in keyfile format, in libnm, and nmcli, is a effort. Also, it's further complicated by the fact that each peer has a secret (the preshared-key). Thus we probably need secret flags for each peer, which is a novelty as well (until now we require a fixed set of secrets per profile that is well known). --- shared/nm-meta-setting.c | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'shared/nm-meta-setting.c') diff --git a/shared/nm-meta-setting.c b/shared/nm-meta-setting.c index e7e73bd88e..e666e0b2a2 100644 --- a/shared/nm-meta-setting.c +++ b/shared/nm-meta-setting.c @@ -65,6 +65,7 @@ #include "nm-setting-wifi-p2p.h" #include "nm-setting-wimax.h" #include "nm-setting-wired.h" +#include "nm-setting-wireguard.h" #include "nm-setting-wireless-security.h" #include "nm-setting-wireless.h" #include "nm-setting-wpan.h" @@ -402,6 +403,12 @@ const NMMetaSettingInfo nm_meta_setting_infos[] = { .setting_name = NM_SETTING_WIRED_SETTING_NAME, .get_setting_gtype = nm_setting_wired_get_type, }, + [NM_META_SETTING_TYPE_WIREGUARD] = { + .meta_type = NM_META_SETTING_TYPE_WIREGUARD, + .setting_priority = NM_SETTING_PRIORITY_HW_BASE, + .setting_name = NM_SETTING_WIREGUARD_SETTING_NAME, + .get_setting_gtype = nm_setting_wireguard_get_type, + }, [NM_META_SETTING_TYPE_WIRELESS] = { .meta_type = NM_META_SETTING_TYPE_WIRELESS, .setting_priority = NM_SETTING_PRIORITY_HW_BASE, -- cgit v1.2.1