This patch adds a request list_virtual_machines which is responsible for
making an API connection and returning a raw "response" object from the
API.
Model instances of a Server (compute resource) are returned as a
collection through the "all" method. The Fog framework calls all on the
instance of the collection.
Without this patch we were blindly trusting the remote end of our API
connection is who they claim to be. This is an insecure state because
we leave ourselves open to a man in the middle attack.
This patch adds a vsphere_expected_pubkey_hash setting for the Vsphere
provider. This setting is expected to be the SHA256 hex digest string
of the PEM encoded text of the RSA public key.
The first time an end user connects this string is displayed to them in
the error message. They need simply copy and paste it into ~/.fog to
securely connect to the remote end.
For example:
:vspherebadpw:
:vsphere_server: vc01.acme.lan
:vsphere_username: api_login
:vsphere_password: badpassword
:vsphere_expected_pubkey_hash: 431dd...
This patch adds a compute service to fog setting the stage to model
VMware virtual machines using Fog. The patch adds support for:
rdebug -- fog vsphere
>>> connection = Fog::Compute.new(:provider => :vsphere)
The connection to the VMware API is implemented along with
authentication using an username and password. The connection is not
fully secured with this patch because no validation of the SSL
certificate is implemented.
Raw API requests are working with this patch, but none of the API
requests have associated Fog models or collections.