TPM_GETCAPABILITY(3)

NAME
TPM_GetCapability_Version, TPM_GetCapability_Slots, TPM_GetCapability_Pcrs, TPM_GetCapability_Key_Handle - Retrieve information about the capabilities of the TPM chip

LIBRARY
tcpa

SYNOPSIS
#include <tcpa.h>
uint32_t
TPM_GetCapability_Version(int *major, int *minor, int *version, int *rev, FILE *log);
uint32_t
TPM_GetCapability_Pcrs(uint32_t *pcrs, FILE *log);
uint32_t
TPM_GetCapability_Slots(uint32_t *slots, FILE *log);
uint32_t
TPM_GetCapability_Key_Handle(uint16_t *num, uint32_t keys[], FILE *log);

DESCRIPTION
Togethers, these functions allow a program to query the TPM chip about its capabilities. All of the functions take the log parameter. This is used for diagnostic purposed, and outputs debugging information to this FILE if non-NULL.

The first capability, retrieved by TPM_GetCapability_Version() , is the manufactured version number of the chip. There are four components to this version number, stored respectively in major, minor, version, and rev. Currently, the chip in my IBM T30 laptop is version 1.1.0.6.

The next capability is TPM_GetCapability_Pcrs(). This retrieves the number of platform configuration registers available on the chip, and stores that number in *slots. Platform configuration registers are used to store values (actually SHA1 hashes) that represent the state of various parts of the system (such as the bios, bootloader, kernel, etc.) By looking at these it is possible to determine if the system (or at least the parts that load values into the registers) has changed.

TPM_GetCapability_Slots() returns the number of slots where encryption / signing keys can be loaded into the chip. This number is put into *slots.

Finally, there is the TPM_GetCapability_Key_Handle() function. This function returns the handles for all of the keys currently loaded in the chip. First it returns the number of keys that are currently loaded in *num. Then is loads the handles for num keys into the keys array, where each handle is a uint32_t.

RETURN VALUES

SEE ALSO
TPM_Transmit(3), TPM_OIAP(3), TPM_TakeOwnership(3), TPM_LoadKey(3), TPM_ReadPubek(3), TPM_Seal(3), TPM_Sign(3)

AUTHORS
Rick Wash <rwash@citi.umich.edu>