net-dhcp-leases: Implement the public APIs
Introduce 3 new APIs, virNetworkGetDHCPLeases, virNetworkGetDHCPLeasesForMAC and virNetworkDHCPLeaseFree. * virNetworkGetDHCPLeases: returns the dhcp leases information for a given virtual network. For DHCPv4, the information returned: - Network Interface Name - Expiry Time - MAC address - IAID (NULL) - IPv4 address (with type and prefix) - Hostname (can be NULL) - Client ID (can be NULL) For DHCPv6, the information returned: - Network Interface Name - Expiry Time - MAC address - IAID (can be NULL, only in rare cases) - IPv6 address (with type and prefix) - Hostname (can be NULL) - Client DUID Note: @mac, @iaid, @ipaddr, @clientid are in ASCII form, not raw bytes. Note: @expirytime can 0, in case the lease is for infinite time. * virNetworkGetDHCPLeasesForMAC: returns the dhcp leases information for a given virtual network and specified MAC Address. * virNetworkDHCPLeaseFree: allows the upper layer application to free the network interface object conveniently. There is no support for flags, so user is expected to pass 0 for both the APIs. include/libvirt/libvirt.h.in: * Define virNetworkGetDHCPLeases * Define virNetworkGetDHCPLeasesForMAC * Define virNetworkDHCPLeaseFree src/driver.h: * Define networkGetDHCPLeases * Define networkGetDHCPLeasesForMAC src/libvirt.c: * Implement virNetworkGetDHCPLeases * Implement virNetworkGetDHCPLeasesForMAC * Implement virNetworkDHCPLeaseFree src/libvirt_public.syms: * Export the new symbols
Showing
-
mentioned in commit 1f9e9f83
-
mentioned in commit de8545c8
-
mentioned in commit e08ee660
-
mentioned in commit 1571d2d2
-
mentioned in commit ceefdec9
-
mentioned in commit b096e694
-
mentioned in commit fdd10cae
-
mentioned in commit de00f271
-
mentioned in commit 3988533c
-
mentioned in commit 4f634078
-
mentioned in commit 9ed36071
-
mentioned in commit a85bb493
-
mentioned in commit b814222d
-
mentioned in commit 7d17f0a4
-
mentioned in commit 99497739
-
mentioned in commit 6884c394
-
mentioned in commit ff947e98
想要评论请 注册 或 登录