cloudstack/plugins
Rohit Yadav 8da2462469
CLOUDSTACK-10333: Secure Live VM Migration for KVM (#2505)
This extends securing of KVM hosts to securing of libvirt on KVM
host as well for TLS enabled live VM migration. To simplify implementation
securing of host implies that both host and libvirtd processes are
secured with management server's CA plugin issued certificates.

Based on whether keystore and certificates files are available at
/etc/cloudstack/agent, the KVM agent determines whether to use TLS or
TCP based uris for live VM migration. It is also enforced that a secured
host will allow live VM migration to/from other secured host, and an
unsecured hosts will allow live VM migration to/from other unsecured
host only.

Post upgrade the KVM agent on startup will expose its security state
(secured detail is sent as true or false) to the managements server that
gets saved in host_details for the host. This host detail can be accesed
via the listHosts response, and in the UI unsecured KVM hosts will show
up with the host state of ‘unsecured’. Further, a button has been added
that allows admins to provision/renew certificates to KVM hosts and can
be used to secure any unsecured KVM host.

The `cloudstack-setup-agent` was modified to accept a new flag `-s`
which will reconfigure libvirtd with following settings:

    listen_tcp=0
    listen_tls=1
    tcp_port="16509"
    tls_port="16514"
    auth_tcp="none"
    auth_tls="none"
    key_file = "/etc/pki/libvirt/private/serverkey.pem"
    cert_file = "/etc/pki/libvirt/servercert.pem"
    ca_file = "/etc/pki/CA/cacert.pem"

For a connected KVM host agent, when the certificate are
renewed/provisioned a background task is scheduled that waits until all
of the agent tasks finish after which libvirt process is restarted and
finally the agent is restarted via AgentShell.

There are no API or DB changes.

Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
2018-04-20 00:36:18 +05:30
..
acl Updating pom.xml version numbers for release 4.11.1.0-SNAPSHOT 2018-02-26 16:57:48 +01:00
affinity-group-processors Updating pom.xml version numbers for release 4.11.1.0-SNAPSHOT 2018-02-26 16:57:48 +01:00
alert-handlers Updating pom.xml version numbers for release 4.11.1.0-SNAPSHOT 2018-02-26 16:57:48 +01:00
api Updating pom.xml version numbers for release 4.11.1.0-SNAPSHOT 2018-02-26 16:57:48 +01:00
ca/root-ca CLOUDSTACK-10333: Secure Live VM Migration for KVM (#2505) 2018-04-20 00:36:18 +05:30
database Updating pom.xml version numbers for release 4.11.1.0-SNAPSHOT 2018-02-26 16:57:48 +01:00
dedicated-resources Updating pom.xml version numbers for release 4.11.1.0-SNAPSHOT 2018-02-26 16:57:48 +01:00
deployment-planners Updating pom.xml version numbers for release 4.11.1.0-SNAPSHOT 2018-02-26 16:57:48 +01:00
event-bus CLOUDSTACK-10319: Prefer TLSv1.2, deprecate TLSv1.0,1.1 (#2480) 2018-03-12 11:43:59 +01:00
file-systems/netapp Updating pom.xml version numbers for release 4.11.1.0-SNAPSHOT 2018-02-26 16:57:48 +01:00
ha-planners/skip-heurestics Updating pom.xml version numbers for release 4.11.1.0-SNAPSHOT 2018-02-26 16:57:48 +01:00
host-allocators/random Updating pom.xml version numbers for release 4.11.1.0-SNAPSHOT 2018-02-26 16:57:48 +01:00
hypervisors CLOUDSTACK-10333: Secure Live VM Migration for KVM (#2505) 2018-04-20 00:36:18 +05:30
integrations Updating pom.xml version numbers for release 4.11.1.0-SNAPSHOT 2018-02-26 16:57:48 +01:00
metrics Updating pom.xml version numbers for release 4.11.1.0-SNAPSHOT 2018-02-26 16:57:48 +01:00
network-elements CLOUDSTACK-10132: Extend support for management servers LB for agents (#2469) 2018-03-15 16:34:03 +05:30
outofbandmanagement-drivers Updating pom.xml version numbers for release 4.11.1.0-SNAPSHOT 2018-02-26 16:57:48 +01:00
storage Updating pom.xml version numbers for release 4.11.1.0-SNAPSHOT 2018-02-26 16:57:48 +01:00
storage-allocators/random Updating pom.xml version numbers for release 4.11.1.0-SNAPSHOT 2018-02-26 16:57:48 +01:00
user-authenticators manual mapped ldap fix (#2517) 2018-04-09 17:38:49 +02:00
pom.xml Updating pom.xml version numbers for release 4.11.1.0-SNAPSHOT 2018-02-26 16:57:48 +01:00