📄 tpm_quote.3
字号:
.\" Copyright 2004 IBM (Jeff Kravitz).\".\" Written Feb 10 2004, Jeff Kravitz.\".TH "TPM_Quote" 3 2004-03-29 "IBM" "TPM Library".SH NAMETPM_Quote.SH SYNOPSIS.nf.B #include <tpmfunc.h>.sp.BR "uint32_t TPM_Quote(uint32_t keyhandle," uint32_t pcrmap, unsigned char *keyauth, unsigned char *data, unsigned char *pcrcompos, unsigned char *blob, unsigned int *bloblen);.fi.SH DESCRIPTIONThe \fBTPM_Quote()\fP function returns thecurrent PCR register values, for specified PCR registers, ina cryptographically secure manner..SH ARGUMENTSThe arguments include....TP 10.B keyhandleThe handle of the key used to sign the results. This is usually obtainedfrom \fBTPM_LoadKey()\fP. This key must be a signing or legacy key..TP 10.B pcrmapA 32 bit integer containing a bit map of the PCR registernumbers to be used when quoting. e.g 0x0000001 specifiesPCR 0. 0x00000003 specifies PCR's 0 and 1, etc..TP 10.B keyauthThe authorization data for the key(a 20 byte value which is usually calculated as the hash of a password).if NULL, it will be assumed that no password is required..TP 10.B dataA pointer to some data to be signed (20 bytes). Usually, thisis a cryptographic nonce or challenge, which is used to provethat the signed result is not a replay..TP 10.B pcrcomposA pointer to an area to receive a pcrcomposite structure, containingthe current PCR values.This area is defined as....RS 5.IP \(bu 5A 32-bit integer containing the length of the following PCR selection array,in big-endian order..IP \(bu 5An array of bytes, called a PCR selection array,specifying the PCR registers contained in the followingPCR value array.The PCR selection array forms a bit map, where a 1 bit selects the corresponding register.The bytes are arranged in order from the lowest-numbered registers to thehigher-numbered ones, e.g the first byte in the array specifies registers0 through 7, the next byte registers 8 through 15, etc. The lowest orderbit in a byte specifies the lowest-numbered register for that byte.Thus register 0 is specified by turning on bit 0, in byte 0 of the array.The array may be any length from 1 to 16 bytes long..IP \(bu 5A 32-bit integer containing the length of the following PCR value array,in big-endian order..IP \(bu 5An array of PCR values, each value is 20 bytes in length. The arraycontains the values, in order, of the PCR registers specifiedby the \fBpcrmap\fP argument, and also indicated by the PCRselection bit map..RE.TP 10.B blobA pointer to an area to receive the signed data..TP 10.B bloblenA pointer to an integer which will receive the lengthof the signed data..SH "RETURN VALUE"0 if the operation is successful. non-zero otherwise.The non zero value can be converted to an error message via the function \fBTPM_GetErrMsg()\fP..SH "SEE ALSO".BR TPM_GetErrMsg(3) , TPM_LoadKey(3) , TPM_PcrRead(3) ..SH AUTHORJeff Kravitz, IBM T.J. Watson Research Center
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -