Crate libzt[][src]

Modules

node
socket
tcp
udp
utils

Structs

zts_addr_info_t

Details about an assigned address that was added or removed

zts_event_msg_t

Callback message

zts_fd_set
zts_hostent
zts_in6_addr
zts_in_addr
zts_in_pktinfo
zts_iovec
zts_ip4_addr
zts_ip6_addr

This is the aligned version of ip6_addr_t, used as local variable, on the stack, etc.

zts_ip_addr

A union struct for both IP version’s addresses. ATTENTION: watch out for its size when adding IPv6 address scope!

zts_ip_mreq
zts_ipv6_mreq
zts_linger
zts_msghdr
zts_multicast_group_t

An Ethernet multicast group

zts_net_info_t

Virtual network configuration

zts_net_info_t__bindgen_ty_1

Multicast groups to which this network’s device is subscribed

zts_netif_info_t

Structure used to convey information about a virtual network interface (netif) to a user application.

zts_node_info_t

Runtime details about the current node

zts_path_t

Physical network path to a peer

zts_peer_info_t

Peer status result buffer

zts_pollfd
zts_root_set_t

Structure used to specify a root topology (aka a world)

zts_route_info_t

A route to be pushed on a virtual network

zts_sockaddr

Pointers to socket address structures are often cast to this type

zts_sockaddr_in

Address structure to specify an IPv4 endpoint

zts_sockaddr_in6

Address structure to specify an IPv6 endpoint

zts_sockaddr_storage

Address structure large enough to hold IPv4 and IPv6 addresses

zts_stats_counter_t

Structure containing counters for various protocol statistics

zts_timeval

Constants

LWIP_SOCKET_OFFSET
MEMP_NUM_NETCONN
SIN_ZERO_LEN
ZTS_AF_INET
ZTS_AF_INET6
ZTS_AF_UNSPEC
ZTS_C_API_ONLY
ZTS_DISABLE_CENTRAL_API
ZTS_FD_SETSIZE
ZTS_F_GETFL
ZTS_F_SETFL
ZTS_ID_STR_BUF_LEN
ZTS_INET6_ADDRSTRLEN
ZTS_INET_ADDRSTRLEN
ZTS_IOCPARM_MASK
ZTS_IOC_IN
ZTS_IOC_INOUT
ZTS_IOC_OUT
ZTS_IOC_VOID
ZTS_IPPROTO_ICMP
ZTS_IPPROTO_ICMPV6
ZTS_IPPROTO_IP
ZTS_IPPROTO_IPV6
ZTS_IPPROTO_RAW
ZTS_IPPROTO_TCP
ZTS_IPPROTO_UDP
ZTS_IPPROTO_UDPLITE
ZTS_IPTOS_LOWCOST
ZTS_IPTOS_LOWDELAY
ZTS_IPTOS_MINCOST
ZTS_IPTOS_PREC_CRITIC_ECP
ZTS_IPTOS_PREC_FLASH
ZTS_IPTOS_PREC_FLASHOVERRIDE
ZTS_IPTOS_PREC_IMMEDIATE
ZTS_IPTOS_PREC_INTERNETCONTROL
ZTS_IPTOS_PREC_MASK
ZTS_IPTOS_PREC_NETCONTROL
ZTS_IPTOS_PREC_PRIORITY
ZTS_IPTOS_PREC_ROUTINE
ZTS_IPTOS_RELIABILITY
ZTS_IPTOS_THROUGHPUT
ZTS_IPTOS_TOS_MASK
ZTS_IPV6_ADD_MEMBERSHIP
ZTS_IPV6_CHECKSUM
ZTS_IPV6_DROP_MEMBERSHIP
ZTS_IPV6_JOIN_GROUP
ZTS_IPV6_LEAVE_GROUP
ZTS_IPV6_V6ONLY
ZTS_IP_ADD_MEMBERSHIP
ZTS_IP_DROP_MEMBERSHIP
ZTS_IP_MAX_STR_LEN
ZTS_IP_MULTICAST_IF
ZTS_IP_MULTICAST_LOOP
ZTS_IP_MULTICAST_TTL
ZTS_IP_PKTINFO
ZTS_IP_TOS
ZTS_IP_TTL
ZTS_MAC_ADDRSTRLEN
ZTS_MAX_ASSIGNED_ADDRESSES
ZTS_MAX_ENDPOINTS_PER_ROOT
ZTS_MAX_ENDPOINT_STR_LEN
ZTS_MAX_MULTICAST_SUBSCRIPTIONS
ZTS_MAX_NETWORK_ROUTES
ZTS_MAX_NETWORK_SHORT_NAME_LENGTH
ZTS_MAX_NUM_ROOTS
ZTS_MAX_PEER_NETWORK_PATHS
ZTS_MSG_CTRUNC
ZTS_MSG_DONTWAIT
ZTS_MSG_MORE
ZTS_MSG_OOB
ZTS_MSG_PEEK
ZTS_MSG_TRUNC
ZTS_MSG_WAITALL
ZTS_O_NDELAY
ZTS_O_NONBLOCK
ZTS_O_RDONLY
ZTS_O_RDWR
ZTS_O_WRONLY
ZTS_PF_INET
ZTS_PF_INET6
ZTS_PF_UNSPEC
ZTS_POLLERR
ZTS_POLLHUP
ZTS_POLLIN
ZTS_POLLNVAL
ZTS_POLLOUT
ZTS_POLLPRI
ZTS_POLLRDBAND
ZTS_POLLRDNORM
ZTS_POLLWRBAND
ZTS_POLLWRNORM
ZTS_SHUT_RD
ZTS_SHUT_RDWR
ZTS_SHUT_WR
ZTS_SOCK_DGRAM
ZTS_SOCK_RAW
ZTS_SOCK_STREAM
ZTS_SOL_SOCKET
ZTS_SO_ACCEPTCONN
ZTS_SO_BINDTODEVICE
ZTS_SO_BROADCAST
ZTS_SO_CONTIMEO
ZTS_SO_DEBUG
ZTS_SO_DONTROUTE
ZTS_SO_ERROR
ZTS_SO_KEEPALIVE
ZTS_SO_LINGER
ZTS_SO_NO_CHECK
ZTS_SO_OOBINLINE
ZTS_SO_RCVBUF
ZTS_SO_RCVLOWAT
ZTS_SO_RCVTIMEO
ZTS_SO_REUSEADDR
ZTS_SO_REUSEPORT
ZTS_SO_SNDBUF
ZTS_SO_SNDLOWAT
ZTS_SO_SNDTIMEO
ZTS_SO_TYPE
ZTS_SO_USELOOPBACK
ZTS_STORE_DATA_LEN
ZTS_TCP_KEEPALIVE
ZTS_TCP_KEEPCNT
ZTS_TCP_KEEPIDLE
ZTS_TCP_KEEPINTVL
ZTS_TCP_NODELAY
ZTS_UDPLITE_RECV_CSCOV
ZTS_UDPLITE_SEND_CSCOV
zts_errno_t_ZTS_EACCES

Permission denied

zts_errno_t_ZTS_EADDRINUSE

Address already in use

zts_errno_t_ZTS_EADDRNOTAVAIL

Cannot assign requested address

zts_errno_t_ZTS_EAFNOSUPPORT

Address family not supported by protocol

zts_errno_t_ZTS_EAGAIN

Try again

zts_errno_t_ZTS_EALREADY

Operation already in progress

zts_errno_t_ZTS_EBADF

Bad file number

zts_errno_t_ZTS_EBUSY

Device or resource busy

zts_errno_t_ZTS_ECONNABORTED

Software caused connection abort

zts_errno_t_ZTS_ECONNREFUSED

Connection timed out

zts_errno_t_ZTS_ECONNRESET

Connection reset by peer

zts_errno_t_ZTS_EDESTADDRREQ

Destination address required

zts_errno_t_ZTS_EEXIST

File exists

zts_errno_t_ZTS_EFAULT

Bad address

zts_errno_t_ZTS_EHOSTUNREACH

No route to host

zts_errno_t_ZTS_EINPROGRESS

Operation now in progress

zts_errno_t_ZTS_EINTR

Interrupted system call

zts_errno_t_ZTS_EINVAL

Invalid argument

zts_errno_t_ZTS_EIO

I/O error

zts_errno_t_ZTS_EISCONN

Transport endpoint is already connected

zts_errno_t_ZTS_EMFILE

Too many open files

zts_errno_t_ZTS_EMSGSIZE

Message too long

zts_errno_t_ZTS_ENETDOWN

Network is down

zts_errno_t_ZTS_ENETUNREACH

Network is unreachable

zts_errno_t_ZTS_ENFILE

File table overflow

zts_errno_t_ZTS_ENOBUFS

No buffer space available

zts_errno_t_ZTS_ENODEV

No such device

zts_errno_t_ZTS_ENOENT

No such file or directory

zts_errno_t_ZTS_ENOMEM

Out of memory

zts_errno_t_ZTS_ENOPROTOOPT

Protocol not available

zts_errno_t_ZTS_ENOSYS

Function not implemented

zts_errno_t_ZTS_ENOTCONN

Transport endpoint is not connected

zts_errno_t_ZTS_ENOTSOCK

Socket operation on non-socket

zts_errno_t_ZTS_ENXIO

No such device or address

zts_errno_t_ZTS_EOPNOTSUPP

Operation not supported on transport endpoint

zts_errno_t_ZTS_EPERM

Operation not permitted

zts_errno_t_ZTS_EPFNOSUPPORT

Protocol family not supported

zts_errno_t_ZTS_EPROTONOSUPPORT

Protocol not supported

zts_errno_t_ZTS_EPROTOTYPE

Protocol wrong type for socket

zts_errno_t_ZTS_ESOCKTNOSUPPORT

Socket type not supported

zts_errno_t_ZTS_ESRCH

No such process

zts_errno_t_ZTS_ETIMEDOUT

Connection timed out

zts_errno_t_ZTS_EWOULDBLOCK

Operation would block

zts_error_t_ZTS_ERR_ARG

Invalid argument

zts_error_t_ZTS_ERR_GENERAL

Consider filing a bug report

zts_error_t_ZTS_ERR_NO_RESULT

No result (not necessarily an error)

zts_error_t_ZTS_ERR_OK

No error

zts_error_t_ZTS_ERR_SERVICE

This operation is not allowed at this time. Or possibly the node hasn’t been started

zts_error_t_ZTS_ERR_SOCKET

Socket error, see zts_errno

zts_event_t_ZTS_EVENT_ADDR_ADDED_IP4

A new managed IPv4 address was assigned to this peer

zts_event_t_ZTS_EVENT_ADDR_ADDED_IP6

A new managed IPv4 address was assigned to this peer

zts_event_t_ZTS_EVENT_ADDR_REMOVED_IP4

A managed IPv4 address assignment was removed from this peer

zts_event_t_ZTS_EVENT_ADDR_REMOVED_IP6

A managed IPv6 address assignment was removed from this peer

zts_event_t_ZTS_EVENT_NETIF_DOWN

lwIP netif down (for debug purposes)

zts_event_t_ZTS_EVENT_NETIF_LINK_DOWN

lwIP netif link down (for debug purposes)

zts_event_t_ZTS_EVENT_NETIF_LINK_UP

lwIP netif link up (for debug purposes)

zts_event_t_ZTS_EVENT_NETIF_REMOVED

lwIP netif removed (for debug purposes)

zts_event_t_ZTS_EVENT_NETIF_UP

lwIP netif up (for debug purposes)

zts_event_t_ZTS_EVENT_NETWORK_ACCESS_DENIED

The node is not allowed to join the network (you must authorize node)

zts_event_t_ZTS_EVENT_NETWORK_CLIENT_TOO_OLD

The version of ZeroTier inside libzt is too old

zts_event_t_ZTS_EVENT_NETWORK_DOWN

Network controller is unreachable

zts_event_t_ZTS_EVENT_NETWORK_NOT_FOUND

Network ID does not correspond to a known network

zts_event_t_ZTS_EVENT_NETWORK_OK

The node joined the network successfully (no action needed)

zts_event_t_ZTS_EVENT_NETWORK_READY_IP4

The node has received an IPv4 address from the network controller

zts_event_t_ZTS_EVENT_NETWORK_READY_IP4_IP6

Deprecated

zts_event_t_ZTS_EVENT_NETWORK_READY_IP6

The node has received an IPv6 address from the network controller

zts_event_t_ZTS_EVENT_NETWORK_REQ_CONFIG

The configuration for a network has been requested (no action needed)

zts_event_t_ZTS_EVENT_NETWORK_UPDATE

Network change received from controller

zts_event_t_ZTS_EVENT_NODE_DOWN

Node is shutting down

zts_event_t_ZTS_EVENT_NODE_FATAL_ERROR

A fatal error has occurred. One possible reason is:

zts_event_t_ZTS_EVENT_NODE_OFFLINE

Node is offline – network does not seem to be reachable by any available strategy

zts_event_t_ZTS_EVENT_NODE_ONLINE

Node is online – at least one upstream node appears reachable

zts_event_t_ZTS_EVENT_NODE_UP

Node has been initialized

zts_event_t_ZTS_EVENT_PEER_DIRECT

A direct P2P path to peer is known

zts_event_t_ZTS_EVENT_PEER_PATH_DEAD

A known path to a peer is now considered dead

zts_event_t_ZTS_EVENT_PEER_PATH_DISCOVERED

A new path to a peer was discovered

zts_event_t_ZTS_EVENT_PEER_RELAY

A direct P2P path to peer is NOT known. Traffic is now relayed

zts_event_t_ZTS_EVENT_PEER_UNREACHABLE

A peer is unreachable. Check NAT/Firewall settings

zts_event_t_ZTS_EVENT_ROUTE_ADDED

A new managed network route was added

zts_event_t_ZTS_EVENT_ROUTE_REMOVED

A managed network route was removed

zts_event_t_ZTS_EVENT_STACK_DOWN

TCP/IP stack (lwIP) id down (for debug purposes)

zts_event_t_ZTS_EVENT_STACK_UP

TCP/IP stack (lwIP) is up (for debug purposes)

zts_event_t_ZTS_EVENT_STORE_IDENTITY_PUBLIC

The node’s public key (identity)

zts_event_t_ZTS_EVENT_STORE_IDENTITY_SECRET

The node’s secret key (identity)

zts_event_t_ZTS_EVENT_STORE_NETWORK

New network config

zts_event_t_ZTS_EVENT_STORE_PEER

New reachability hints and peer configuration

zts_event_t_ZTS_EVENT_STORE_PLANET

The node has received an updated planet config

zts_net_info_type_t_ZTS_NETWORK_TYPE_PRIVATE

Private networks are authorized via certificates of membership

zts_net_info_type_t_ZTS_NETWORK_TYPE_PUBLIC

Public networks have no access control – they’ll always be AUTHORIZED

zts_network_status_t_ZTS_NETWORK_STATUS_ACCESS_DENIED

Netconf master told us ‘nope’

zts_network_status_t_ZTS_NETWORK_STATUS_CLIENT_TOO_OLD

ZeroTier core version too old

zts_network_status_t_ZTS_NETWORK_STATUS_NOT_FOUND

Netconf master exists, but this virtual network does not

zts_network_status_t_ZTS_NETWORK_STATUS_OK

Configuration received and we are authorized

zts_network_status_t_ZTS_NETWORK_STATUS_PORT_ERROR

Initialization of network failed or other internal error

zts_network_status_t_ZTS_NETWORK_STATUS_REQUESTING_CONFIGURATION

Waiting for network configuration (also means revision == 0)

zts_peer_role_t_ZTS_PEER_ROLE_LEAF

Ordinary node

zts_peer_role_t_ZTS_PEER_ROLE_MOON

Moon root

zts_peer_role_t_ZTS_PEER_ROLE_PLANET

Planetary root

Statics

zts_errno

Functions

zts_accept

@brief Accept an incoming connection

zts_addr_compute_6plane

@brief Compute a 6PLANE IPv6 address for the given Network ID and Node ID

zts_addr_compute_6plane_str

@brief Compute 6PLANE IPv6 address for the given Network ID and Node ID and copy its null-terminated human-readable string representation into destination buffer.

zts_addr_compute_rfc4193

@brief Compute RFC4193 IPv6 address for the given Network ID and Node ID

zts_addr_compute_rfc4193_str

@brief Compute RFC4193 IPv6 address for the given Network ID and Node ID and copy its null-terminated human-readable string representation into destination buffer.

zts_addr_get

@brief Get the first-assigned IP on the given network.

zts_addr_get_all

@brief Get all IP addresses assigned to this node by the given network

zts_addr_get_str

@brief Get the first-assigned IP on the given network as a null-terminated human-readable string

zts_addr_is_assigned

@brief Return whether an address of the given family has been assigned by the network

zts_bind

@brief Bind a socket to a local address

zts_bsd_accept

@brief Accept an incoming connection

zts_bsd_bind

@brief Bind a socket to a local address

zts_bsd_close

@brief Close socket.

zts_bsd_connect

@brief Connect a socket to a remote host

zts_bsd_fcntl

@brief Issue file control commands on a socket

zts_bsd_gethostbyname

@brief Resolve a host-name

zts_bsd_getpeername

@brief Get the name (address) of the remote end of the socket

zts_bsd_getsockname

@brief Get the name (address) of the local end of the socket

zts_bsd_getsockopt

@brief Get socket options.

zts_bsd_ioctl

@brief Control a device

zts_bsd_listen

@brief Listen for incoming connections on socket

zts_bsd_poll

@brief Wait for some event on a file descriptor.

zts_bsd_read

@brief Read data from socket onto buffer

zts_bsd_readv

@brief Read data from socket into multiple buffers

zts_bsd_recv

@brief Receive data from remote host

zts_bsd_recvfrom

@brief Receive data from remote host

zts_bsd_recvmsg

@brief Receive a message from remote host

zts_bsd_select

@brief Monitor multiple file descriptors for “readiness”

zts_bsd_send

@brief Send data to remote host

zts_bsd_sendmsg

@brief Send message to remote host

zts_bsd_sendto

@brief Send data to remote host

zts_bsd_setsockopt

@brief Set socket options.

zts_bsd_shutdown

@brief Shut down some aspect of a socket

zts_bsd_socket

@brief Create a socket

zts_bsd_write

@brief Write data from buffer to socket

zts_bsd_writev

@brief Write data from multiple buffers to socket.

zts_close

@brief Close socket.

zts_connect

@brief Connect a socket to a remote host

zts_core_lock_obtain

@brief Lock the core service so that queries about addresses, routes, paths, etc. can be performed.

zts_core_lock_release

@brief Lock the core service so that queries about addresses, routes, paths, etc. can be performed.

zts_core_query_addr

@brief Lock the core service so that queries about addresses, routes, paths, etc. can be performed.

zts_core_query_addr_count

@brief Lock the core service so that queries about addresses, routes, paths, etc. can be performed.

zts_core_query_mc

@brief Lock the core service so that queries about addresses, routes, paths, etc. can be performed.

zts_core_query_mc_count

@brief Lock the core service so that queries about addresses, routes, paths, etc. can be performed.

zts_core_query_path

@brief Lock the core service so that queries about addresses, routes, paths, etc. can be performed.

zts_core_query_path_count

@brief Lock the core service so that queries about addresses, routes, paths, etc. can be performed.

zts_core_query_route

@brief Lock the core service so that queries about addresses, routes, paths, etc. can be performed.

zts_core_query_route_count

@brief Lock the core service so that queries about addresses, routes, paths, etc. can be performed.

zts_dns_get_server

Obtain one of the currently configured DNS server.

zts_dns_set_server

Initialize one of the DNS servers.

zts_get_blocking

@brief Return whether blocking mode O_NONBLOCK is enabled

zts_get_data_available

@brief Return amount of data available to read from socket

zts_get_keepalive

@brief Return whether SO_KEEPALIVE is enabled

zts_get_last_socket_error

@brief Get the last error for the given socket

zts_get_linger_enabled

@brief Return whether SO_LINGER is enabled

zts_get_linger_value

@brief Return the value of SO_LINGER

zts_get_no_delay

@brief Return whether TCP_NODELAY is enabled

zts_get_pending_data_size

@brief Return the number of bytes available to read from the network buffer

zts_get_recv_buf_size

@brief Return the value of SO_RCVBUF

zts_get_recv_timeout

@brief Return the value of SO_RCVTIMEO

zts_get_reuse_addr

@brief Return whether SO_REUSEADDR is enabled

zts_get_send_buf_size

@brief Return the value of SO_SNDBUF

zts_get_send_timeout

@brief Return the value of SO_SNDTIMEO

zts_get_ttl

@brief Return the value of IP_TTL

zts_getpeername

@brief Get the name (address) of the remote end of the socket

zts_getsockname

@brief Get the name (address) of the local end of the socket

zts_id_new

@brief Generates a node identity (public/secret key-pair) and stores it in a user-provided buffer.

zts_id_pair_is_valid

@brief Verifies that a key-pair is valid. Checks formatting and pairing of key to address.

zts_inet_ntop

Convert IPv4 and IPv6 address structures to human-readable text form.

zts_inet_pton

Convert C-string IPv4 and IPv6 addresses to binary form.

zts_init_allow_id_cache

@brief Enable or disable whether the node will cache identities (enabled by default when zts_init_from_storage() is used.) Must be called before zts_node_start().

zts_init_allow_net_cache

@brief Enable or disable whether the node will cache network details (enabled by default when zts_init_from_storage() is used.) Must be called before zts_node_start().

zts_init_allow_peer_cache

@brief Enable or disable whether the node will cache peer details (enabled by default when zts_init_from_storage() is used.) Must be called before zts_node_start().

zts_init_allow_port_mapping

@brief Allow or disallow the use of port-mapping. This is enabled by default. This is an initialization function that can only be called before zts_node_start().

zts_init_allow_roots_cache

@brief Enable or disable whether the node will cache root definitions (enabled by default when zts_init_from_storage() is used.) Must be called before zts_node_start().

zts_init_allow_secondary_port

@brief Allow or disallow ZeroTier from automatically selecting a backup port to help get through buggy NAT. This is enabled by default. This port is randomly chosen and should be disabled if you want to control exactly which ports ZeroTier talks on and (iff) you know with absolute certainty that traffic on your chosen primary port is allowed. This is an initialization function that can only be called before zts_node_start().

zts_init_blacklist_if

@brief Blacklist an interface prefix (or name). This prevents ZeroTier from sending traffic over matching interfaces. This is an initialization function that can only be called before zts_node_start().

zts_init_from_memory

@brief Instruct ZeroTier to use the identity provided in key. This is an initialization function that can only be called before zts_node_start().

zts_init_from_storage

@brief Instruct ZeroTier to look for node identity files at the given location. This is an initialization function that can only be called before zts_node_start().

zts_init_set_event_handler
zts_init_set_port

@brief Set the port to which the node should bind. This is an initialization function that can only be called before zts_node_start().

zts_init_set_random_port_range

@brief Set range that random ports will be selected from. This is an initialization function that can only be called before zts_node_start().

zts_init_set_roots

@brief Present a root set definition for ZeroTier to use instead of the default. This is an initialization function that can only be called before zts_node_start().

zts_ipaddr_aton

Convert IP address string (both versions) to numeric. The version is auto-detected from the string.

zts_ipaddr_ntoa

Convert numeric IP address (both versions) into ASCII representation. returns ptr to static buffer. Not reentrant.

zts_listen

@brief Listen for incoming connections on socket

zts_moon_deorbit

@brief De-orbit a given moon (user-defined root server)

zts_moon_orbit

@brief Orbit a given moon (user-defined root server)

zts_net_compute_adhoc_id

@brief Compute RFC4193 IPv6 address for the given Network ID and Node ID

zts_net_get_broadcast

@brief Return whether broadcast is enabled on this network

zts_net_get_mac

@brief Get the MAC Address for this node on the given network

zts_net_get_mac_str

@brief Get the MAC Address for this node on the given network

zts_net_get_mtu

@brief Get the MTU of the given network

zts_net_get_name

@brief Get the nickname of the network

zts_net_get_status

@brief Get the status of the network

zts_net_get_type

@brief Get the type of network (public or private.)

zts_net_join

@brief Join a network

zts_net_leave

@brief Leave a network

zts_net_transport_is_ready

@brief Return whether this network is ready to send and receive traffic.

zts_node_free

@brief Stop all background threads, bring down all transport services, free all resources. After calling this function an application restart will be required before the library can be used again. Callable only after the node has been started.

zts_node_get_id

@brief Get the public node identity (aka node_id). Callable only after the node has been started.

zts_node_get_id_pair

@brief Copy the current node’s public (and secret!) identity into a buffer.

zts_node_get_port

@brief Get the primary port to which the node is bound. Callable only after the node has been started.

zts_node_is_online

@brief Return whether the node is online (Can reach the Internet)

zts_node_start

@brief Start the ZeroTier node. Should be called after calling the relevant zts_init_* functions for your application. To enable storage call zts_init_from_storage() before this function. To enable event callbacks call zts_init_set_event_handler() before this function.

zts_node_stop

@brief Stop the ZeroTier node and bring down all virtual network transport services. Callable only after the node has been started.

zts_read

@brief Read data from socket onto buffer

zts_recv

@brief Receive data from remote host

zts_route_is_assigned

@brief Return whether a managed route of the given address family has been assigned by the network

zts_send

@brief Send data to remote host

zts_set_blocking

@brief Change blocking behavior O_NONBLOCK

zts_set_keepalive

@brief Enable or disable SO_KEEPALIVE

zts_set_linger

@brief Enable or disable SO_LINGER while also setting its value

zts_set_no_delay

@brief Enable or disable TCP_NODELAY. Enabling this is equivalent to turning off Nagle’s algorithm

zts_set_recv_buf_size

@brief Set the value of SO_RCVBUF

zts_set_recv_timeout

@brief Set the value of SO_RCVTIMEO

zts_set_reuse_addr

@brief Enable or disable SO_REUSEADDR

zts_set_send_buf_size

@brief Set the value of SO_SNDBUF

zts_set_send_timeout

@brief Set the value of SO_SNDTIMEO

zts_set_ttl

@brief Set the value of IP_TTL

zts_shutdown_rd

@brief Shut down read aspect of a socket

zts_shutdown_rdwr

@brief Shut down both read and write aspect of a socket

zts_shutdown_wr

@brief Shut down write aspect of a socket

zts_socket

@brief Create a socket

zts_stats_get_all

@brief Get all statistical counters for all protocols and levels. See also: lwip/stats.h.

zts_tcp_client

@brief A convenience function that takes a remote address IP string and creates the appropriate type of socket, and uses it to connect to a remote host.

zts_tcp_server

@brief A convenience function that takes a remote address IP string and creates the appropriate type of socket, binds, listens, and then accepts on it.

zts_udp_client

@brief This function doesn’t really do anything other than be a namespace counterpart to zts_udp_server. All this function does is create a ZTS_SOCK_DGRAM socket and return its file descriptor.

zts_udp_server

@brief A convenience function that takes a remote address IP string and creates the appropriate type of socket, and binds to it.

zts_util_delay

@brief Platform-agnostic delay

zts_util_get_ip_family

@brief Return the family type of the IP string

zts_util_ipstr_to_saddr

Convert human-friendly IP string to zts_sockaddr_in or zts_sockaddr_in6.

zts_util_ntop

@brief Similar to inet_ntop but determines family automatically and returns port as a value result parameter.

zts_util_sign_root_set

@brief Generates a new root set definition

zts_write

@brief Write data from buffer to socket

Type Definitions

int_fast8_t
int_fast16_t
int_fast32_t
int_fast64_t
int_least8_t
int_least16_t
int_least32_t
int_least64_t
intmax_t
size_t
ssize_t
uint_fast8_t
uint_fast16_t
uint_fast32_t
uint_fast64_t
uint_least8_t
uint_least16_t
uint_least32_t
uint_least64_t
uintmax_t
zts_errno_t
zts_error_t

Common error return values

zts_event_t

Event codes used by the (optional) callback API

zts_in_addr_t
zts_in_port_t
zts_net_info_type_t

Virtual network type codes

zts_network_status_t

Virtual network status codes

zts_nfds_t
zts_peer_role_t

The peer’s trust hierarchy role

zts_sa_family_t
zts_socklen_t

Unions

zts_in6_addr_un
zts_ip_addr__bindgen_ty_1