You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
77 lines
2.4 KiB
77 lines
2.4 KiB
/****************************************************************************
|
|
****************************************************************************
|
|
***
|
|
*** This header was automatically generated from a Linux kernel header
|
|
*** of the same name, to make information necessary for userspace to
|
|
*** call into the kernel available to libc. It contains only constants,
|
|
*** structures, and macros generated from the original header, and thus,
|
|
*** contains no copyrightable information.
|
|
***
|
|
*** To edit the content of this header, modify the corresponding
|
|
*** source file (e.g. under external/kernel-headers/original/) then
|
|
*** run bionic/libc/kernel/tools/update_all.py
|
|
***
|
|
*** Any manual change here will be lost the next time this script will
|
|
*** be run. You've been warned!
|
|
***
|
|
****************************************************************************
|
|
****************************************************************************/
|
|
#ifndef _WG_UAPI_WIREGUARD_H
|
|
#define _WG_UAPI_WIREGUARD_H
|
|
#define WG_GENL_NAME "wireguard"
|
|
#define WG_GENL_VERSION 1
|
|
#define WG_KEY_LEN 32
|
|
enum wg_cmd {
|
|
WG_CMD_GET_DEVICE,
|
|
WG_CMD_SET_DEVICE,
|
|
__WG_CMD_MAX
|
|
};
|
|
#define WG_CMD_MAX (__WG_CMD_MAX - 1)
|
|
enum wgdevice_flag {
|
|
WGDEVICE_F_REPLACE_PEERS = 1U << 0,
|
|
__WGDEVICE_F_ALL = WGDEVICE_F_REPLACE_PEERS
|
|
};
|
|
enum wgdevice_attribute {
|
|
WGDEVICE_A_UNSPEC,
|
|
WGDEVICE_A_IFINDEX,
|
|
WGDEVICE_A_IFNAME,
|
|
WGDEVICE_A_PRIVATE_KEY,
|
|
WGDEVICE_A_PUBLIC_KEY,
|
|
WGDEVICE_A_FLAGS,
|
|
WGDEVICE_A_LISTEN_PORT,
|
|
WGDEVICE_A_FWMARK,
|
|
WGDEVICE_A_PEERS,
|
|
__WGDEVICE_A_LAST
|
|
};
|
|
#define WGDEVICE_A_MAX (__WGDEVICE_A_LAST - 1)
|
|
enum wgpeer_flag {
|
|
WGPEER_F_REMOVE_ME = 1U << 0,
|
|
WGPEER_F_REPLACE_ALLOWEDIPS = 1U << 1,
|
|
WGPEER_F_UPDATE_ONLY = 1U << 2,
|
|
__WGPEER_F_ALL = WGPEER_F_REMOVE_ME | WGPEER_F_REPLACE_ALLOWEDIPS | WGPEER_F_UPDATE_ONLY
|
|
};
|
|
enum wgpeer_attribute {
|
|
WGPEER_A_UNSPEC,
|
|
WGPEER_A_PUBLIC_KEY,
|
|
WGPEER_A_PRESHARED_KEY,
|
|
WGPEER_A_FLAGS,
|
|
WGPEER_A_ENDPOINT,
|
|
WGPEER_A_PERSISTENT_KEEPALIVE_INTERVAL,
|
|
WGPEER_A_LAST_HANDSHAKE_TIME,
|
|
WGPEER_A_RX_BYTES,
|
|
WGPEER_A_TX_BYTES,
|
|
WGPEER_A_ALLOWEDIPS,
|
|
WGPEER_A_PROTOCOL_VERSION,
|
|
__WGPEER_A_LAST
|
|
};
|
|
#define WGPEER_A_MAX (__WGPEER_A_LAST - 1)
|
|
enum wgallowedip_attribute {
|
|
WGALLOWEDIP_A_UNSPEC,
|
|
WGALLOWEDIP_A_FAMILY,
|
|
WGALLOWEDIP_A_IPADDR,
|
|
WGALLOWEDIP_A_CIDR_MASK,
|
|
__WGALLOWEDIP_A_LAST
|
|
};
|
|
#define WGALLOWEDIP_A_MAX (__WGALLOWEDIP_A_LAST - 1)
|
|
#endif
|