com.vmware.vcenter.host package

Submodules

com.vmware.vcenter.host.entropy_client module

The com.vmware.vcenter.host.entropy_client module provides classes to manage entropy

class com.vmware.vcenter.host.entropy_client.ExternalPool(config)

Bases: vmware.vapi.bindings.stub.VapiInterface

The ExternalPool class provides methods to send entropy data and query external entropy pool information on an ESX host. Clients can check the entropy level of an ESX host using the ExternalPool.get() method to check . When the entropy level has dropped below a threshold, a client can use the ExternalPool.add() method to add additional entropy until as required. This class was added in vSphere API 8.0.1.0.

Parameters

config (vmware.vapi.bindings.stub.StubConfiguration) – Configuration to be used for creating the stub.

class AddResult(capacity=None, currently_available=None, low_watermark=None, inactive_source_timeout=None)

Bases: vmware.vapi.bindings.struct.VapiStruct

The ExternalPool.AddResult class provides result of the ExternalPool.add() method. This class was added in vSphere API 8.0.1.0.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters
  • capacity (long) – Capacity of external entropy pool in bytes. This attribute was added in vSphere API 8.0.1.0.

  • currently_available (long) – Currently available amount of entropy in bytes in the external entropy pool. This attribute was added in vSphere API 8.0.1.0.

  • low_watermark (long) – A threshold value in bytes. An audit record will be logged when ExternalPool.AddResult.currently_available drops below this value. This attribute was added in vSphere API 8.0.1.0.

  • inactive_source_timeout (long) –

    A timeout period in seconds within which the client must call ExternalPool.get() method or ExternalPool.add() method. If no call is received before the timeout lapses an audit record will be created.

    This is the timeout to detect any connection lost with the client.. This attribute was added in vSphere API 8.0.1.0.

class AddSpec(data=None)

Bases: vmware.vapi.bindings.struct.VapiStruct

The ExternalPool.AddSpec class defines parameters for the ExternalPool.add() method. This class was added in vSphere API 8.0.1.0.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters

data (str) – Buffer for entropy data. This will carry entropy data received from the external entropy source. This attribute was added in vSphere API 8.0.1.0.

class Info(status=None, capacity=None, currently_available=None, low_watermark=None, inactive_source_timeout=None)

Bases: vmware.vapi.bindings.struct.VapiStruct

The ExternalPool.Info class contains entropy pool information on the ESX host. It provides external entropy pool details as well as timeout in seconds within which client has to keep calling ExternalPool.get() method.

Client has to monitor Info.currentlyAvailable parameter. Before the entropy level goes down below a threshold value the client has to send entropy data by calling ExternalPool.add() method.. This class was added in vSphere API 8.0.1.0.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters
  • status (ExternalPool.Status) – This flag indicates entropy service is enabled or not in a ESX host. This attribute was added in vSphere API 8.0.1.0.

  • capacity (long) – Capacity of external entropy pool in bytes. This attribute was added in vSphere API 8.0.1.0. This attribute is optional and it is only relevant when the value of status is ExternalPool.Status.ENABLED.

  • currently_available (long) – Currently available amount of entropy in bytes in the external entropy pool. This attribute was added in vSphere API 8.0.1.0. This attribute is optional and it is only relevant when the value of status is ExternalPool.Status.ENABLED.

  • low_watermark (long) – A threshold value in bytes. An audit record will be logged when ExternalPool.Info.currently_available drops below this value. This attribute was added in vSphere API 8.0.1.0. This attribute is optional and it is only relevant when the value of status is ExternalPool.Status.ENABLED.

  • inactive_source_timeout (long) –

    A timeout period in seconds within which the client must call ExternalPool.get() method or ExternalPool.add() method. If no call is received before the timeout lapses an audit record will be created.

    This timeout is used to detect that connection with the client is lost.. This attribute was added in vSphere API 8.0.1.0. This attribute is optional and it is only relevant when the value of status is ExternalPool.Status.ENABLED.

class Status(string)

Bases: vmware.vapi.bindings.enum.Enum

The ExternalPool.Status enum represents external entropy status on an ESX host. This enumeration was added in vSphere API 8.0.1.0.

Note

This class represents an enumerated type in the interface language definition. The class contains class attributes which represent the values in the current version of the enumerated type. Newer versions of the enumerated type may contain new values. To use new values of the enumerated type in communication with a server that supports the newer version of the API, you instantiate this class. See enumerated type description page.

Parameters

string (str) – String value for the Status instance.

DISABLED = Status(string='DISABLED')

External entropy is disabled for the ESX host. This class attribute was added in vSphere API 8.0.1.0.

ENABLED = Status(string='ENABLED')

External entropy is enabled for the ESX host. This class attribute was added in vSphere API 8.0.1.0.

add(host, spec)

Adds additional entropy to the pool. This API will accept maximum (ExternalPool.Info.capacity - ExternalPool.Info.currently_available) bytes of entropy. Extra entropy data sent will be discarded. This method was added in vSphere API 8.0.1.0.

Parameters
  • host (str) – Identifier of the host. The parameter must be an identifier for the resource type: HostSystem.

  • spec (ExternalPool.AddSpec) – contains buffer of entropy data.

Return type

ExternalPool.AddResult

Returns

Result of add method.

Raise

com.vmware.vapi.std.errors_client.Error if there is a generic error.

Raise

com.vmware.vapi.std.errors_client.NotFound if the host is not found.

Raise

com.vmware.vapi.std.errors_client.ServiceUnavailable if the host is not available.

Raise

com.vmware.vapi.std.errors_client.Unauthenticated if the caller is not authenticated.

Raise

com.vmware.vapi.std.errors_client.Unauthorized if you do not have all of the privileges described as follows:

  • The resource HostSystem referenced by the parameter host requires Host.Entropy.Write.

get(host)

Retrieves the entropy pool details of a host including current entropy level. This method was added in vSphere API 8.0.1.0.

Parameters

host (str) – Identifier of the host. The parameter must be an identifier for the resource type: HostSystem.

Return type

ExternalPool.Info

Returns

Entropy details of a host.

Raise

com.vmware.vapi.std.errors_client.Error if there is a generic error.

Raise

com.vmware.vapi.std.errors_client.NotFound if the host is not found.

Raise

com.vmware.vapi.std.errors_client.ServiceUnavailable if the host is not available.

Raise

com.vmware.vapi.std.errors_client.Unauthenticated if the caller is not authenticated.

Raise

com.vmware.vapi.std.errors_client.Unauthorized if you do not have all of the privileges described as follows:

  • The resource HostSystem referenced by the parameter host requires Host.Entropy.Read.

class com.vmware.vcenter.host.entropy_client.StubFactory(stub_config)

Bases: vmware.vapi.bindings.stub.StubFactoryBase

Initialize StubFactoryBase

Parameters

stub_config (vmware.vapi.bindings.stub.StubConfiguration) – Stub config instance