Class: VTPM

Last published : Oct 01, 2026
A virtual TPM device

Fields for class: VTPM

Field Type Qualifier Description
allowed_operations vtpm_operations set RO/runtime list of the operations allowed in this state. This list is advisory only and the server state may have changed by the time this field is read by a client.
backend VM ref RO/runtime The domain where the backend is located (unused)
current_operations (string -> vtpm_operations) map RO/runtime links each of the running tasks using this object (by reference) to a current_operation enum which describes the nature of the task.
is_protected bool RO/runtime Whether the contents of the VTPM are secured according to the TPM spec
is_unique bool RO/constructor Whether the contents are never copied, satisfying the TPM spec
persistence_backend persistence_backend RO/runtime The backend where the vTPM is persisted
uuid string RO/runtime Unique identifier/object reference
VM VM ref RO/constructor The virtual machine the TPM is attached to

RPCs associated with class: VTPM

RPC name: create

Overview:
Create a new VTPM instance, and return its handle.
Signature:
VTPM ref create (session ref session_ref, VM ref vM, bool is_unique)
Arguments:
Type Name Description
session ref session_ref Reference to a valid session
VM ref vM The VM reference the VTPM will be attached to
bool is_unique Whether the VTPM must be unique
Minimum Role: vm-admin
Return Type: VTPM ref
The reference of the newly created VTPM

RPC name: destroy

Overview:
Destroy the specified VTPM instance, along with its state.
Signature:
void destroy (session ref session_ref, VTPM ref self)
Arguments:
Type Name Description
session ref session_ref Reference to a valid session
VTPM ref self The reference to the VTPM object
Minimum Role: vm-admin
Return Type: void

RPC name: getall

Overview:
Return a list of all the VTPMs known to the system.
Signature:
VTPM ref set get_all (session ref session_ref)
Arguments:
Type Name Description
session ref session_ref Reference to a valid session
Minimum Role: read-only
Return Type: VTPM ref set
references to all objects

RPC name: getallrecords

Overview:
Return a map of VTPM references to VTPM records for all VTPMs known to the system.
Signature:
(VTPM ref -> VTPM record) map get_all_records (session ref session_ref)
Arguments:
Type Name Description
session ref session_ref Reference to a valid session
Minimum Role: read-only
Return Type: (VTPM ref -> VTPM record) map
records of all objects

RPC name: getallowedoperations

Overview:
Get the allowedoperations field of the given VTPM.
Signature:
vtpm_operations set get_allowed_operations (session ref session_ref, VTPM ref self)
Arguments:
Type Name Description
session ref session_ref Reference to a valid session
VTPM ref self reference to the object
Minimum Role: read-only
Return Type: vtpm_operations set
value of the field

RPC name: getbackend

Overview:
Get the backend field of the given VTPM.
Signature:
VM ref get_backend (session ref session_ref, VTPM ref self)
Arguments:
Type Name Description
session ref session_ref Reference to a valid session
VTPM ref self reference to the object
Minimum Role: read-only
Return Type: VM ref
value of the field

RPC name: getbyuuid

Overview:
Get a reference to the VTPM instance with the specified UUID.
Signature:
VTPM ref get_by_uuid (session ref session_ref, string uuid)
Arguments:
Type Name Description
session ref session_ref Reference to a valid session
string uuid UUID of object to return
Minimum Role: read-only
Return Type: VTPM ref
reference to the object

RPC name: getcurrentoperations

Overview:
Get the currentoperations field of the given VTPM.
Signature:
(string -> vtpm_operations) map get_current_operations (session ref session_ref, VTPM ref self)
Arguments:
Type Name Description
session ref session_ref Reference to a valid session
VTPM ref self reference to the object
Minimum Role: read-only
Return Type: (string -> vtpm_operations) map
value of the field

RPC name: getisprotected

Overview:
Get the isprotected field of the given VTPM.
Signature:
bool get_is_protected (session ref session_ref, VTPM ref self)
Arguments:
Type Name Description
session ref session_ref Reference to a valid session
VTPM ref self reference to the object
Minimum Role: read-only
Return Type: bool
value of the field

RPC name: getisunique

Overview:
Get the isunique field of the given VTPM.
Signature:
bool get_is_unique (session ref session_ref, VTPM ref self)
Arguments:
Type Name Description
session ref session_ref Reference to a valid session
VTPM ref self reference to the object
Minimum Role: read-only
Return Type: bool
value of the field

RPC name: getpersistencebackend

Overview:
Get the persistencebackend field of the given VTPM.
Signature:
persistence_backend get_persistence_backend (session ref session_ref, VTPM ref self)
Arguments:
Type Name Description
session ref session_ref Reference to a valid session
VTPM ref self reference to the object
Minimum Role: read-only
Return Type: persistence_backend
value of the field

RPC name: getrecord

Overview:
Get a record containing the current state of the given VTPM.
Signature:
VTPM record get_record (session ref session_ref, VTPM ref self)
Arguments:
Type Name Description
session ref session_ref Reference to a valid session
VTPM ref self reference to the object
Minimum Role: read-only
Return Type: VTPM record
all fields from the object

RPC name: getuuid

Overview:
Get the uuid field of the given VTPM.
Signature:
string get_uuid (session ref session_ref, VTPM ref self)
Arguments:
Type Name Description
session ref session_ref Reference to a valid session
VTPM ref self reference to the object
Minimum Role: read-only
Return Type: string
value of the field

RPC name: getVM

Overview:
Get the VM field of the given VTPM.
Signature:
VM ref get_VM (session ref session_ref, VTPM ref self)
Arguments:
Type Name Description
session ref session_ref Reference to a valid session
VTPM ref self reference to the object
Minimum Role: read-only
Return Type: VM ref
value of the field