Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Device ¶
type Device struct {
// ManufacturerName is the human-readable name of the TPM manufacturer,
// decoded from the four-character short name the TPM reports (e.g. "AMD",
// "IFX" for Infineon, "STM" for STMicroelectronics).
ManufacturerName string `json:"manufacturer_name"`
// ManufacturerVendorID is the 16-bit TCG Vendor ID assigned to the TPM
// manufacturer by the Trusted Computing Group. Note that this is a
// separate namespace from the PCI vendor ID. It may be empty when the
// host only exposes the manufacturer's short name.
// See: https://trustedcomputinggroup.org/resource/vendor-id-registry/
ManufacturerVendorID string `json:"manufacturer_vendor_id"`
// SpecVersion is the TCG TPM library (specification) version the device
// implements, i.e. the ISO/IEC 11889 version, e.g. "1.2" or "2.0".
SpecVersion string `json:"spec_version"`
// FirmwareVersion is the TPM firmware version, when the host exposes it.
FirmwareVersion string `json:"firmware_version"`
}
Device describes a single Trusted Platform Module (TPM) present on the host system.
type Info ¶
type Info struct {
// Devices are the TPM devices detected under /sys/class/tpm. A host can,
// in principle, expose more than one TPM device.
Devices []*Device `json:"devices"`
}
Info describes the Trusted Platform Module(s) on the host system.
func New ¶
New returns a pointer to an Info struct that contains information about the TPM(s) on the host system.
func (*Info) JSONString ¶
JSONString returns a string with the TPM information formatted as JSON under a top-level "tpm:" key
func (*Info) String ¶
String returns a short string with summary information about the TPM(s) on the host system.
func (*Info) YAMLString ¶
YAMLString returns a string with the TPM information formatted as YAML under a top-level "tpm:" key
Click to show internal directories.
Click to hide internal directories.