Nehal J Wani 0977b8aa07 domifaddr: Implement the API for qemu
By querying the qemu guest agent with the QMP command
"guest-network-get-interfaces" and converting the received JSON
output to structured objects.

Although "ifconfig" is deprecated, IP aliases created by "ifconfig"
are supported by this API. The legacy syntax of an IP alias is:
"<ifname>:<alias-name>". Since we want all aliases to be clubbed
under parent interface, simply stripping ":<alias-name>" suffices.
Note that IP aliases formed by "ip" aren't visible to "ifconfig",
and aliases created by "ip" do not have any specific name. But
we are lucky, as qemu guest agent detects aliases created by both.

src/qemu/qemu_agent.h:
  * Define qemuAgentGetInterfaces

src/qemu/qemu_agent.c:
  * Implement qemuAgentGetInterface

src/qemu/qemu_driver.c:
  * New function qemuGetDHCPInterfaces
  * New function qemuDomainInterfaceAddresses

src/remote_protocol-sructs:
  * Define new structs

tests/qemuagenttest.c:
  * Add new test: testQemuAgentGetInterfaces
    Test cases for IP aliases, 0 or multiple ipv4/ipv6 address(es)

Signed-off-by: Nehal J Wani <nehaljw.kkd1@gmail.com>
2015-03-17 15:15:38 +00:00
..
2014-09-03 09:36:13 -06:00
2014-01-01 16:34:13 +00:00
2014-09-03 09:36:13 -06:00
2014-12-09 10:02:20 -05:00
2014-09-04 15:18:43 -06:00
2014-08-18 20:36:24 -06:00
2015-02-20 16:17:19 +01:00
2014-11-25 08:47:12 -07:00
2013-10-14 10:31:01 +01:00
2014-04-08 11:15:55 +01:00