123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143 |
- .TH "ifapi_policy_execution" 3 "Fri Oct 7 2022" "Version 3.2.0" "tpm2-tss" \" -*- nroff -*-
- .ad l
- .nh
- .SH NAME
- ifapi_policy_execution
- .SH SYNOPSIS
- .br
- .PP
- .SS "Functions"
- .in +1c
- .ti -1c
- .RI "TSS2_RC \fBget_policy_digest_idx\fP (TPML_DIGEST_VALUES *digest_values, TPMI_ALG_HASH hashAlg, size_t *idx)"
- .br
- .ti -1c
- .RI "TSS2_RC \fBifapi_extend_authorization\fP (\fBTPMS_POLICY\fP *policy, \fBTPMS_POLICYAUTHORIZATION\fP *authorization)"
- .br
- .ti -1c
- .RI "TSS2_RC \fBifapi_policyeval_execute\fP (\fBESYS_CONTEXT\fP *esys_ctx, \fBIFAPI_POLICY_EXEC_CTX\fP *current_policy)"
- .br
- .ti -1c
- .RI "TSS2_RC \fBifapi_policyeval_execute_prepare\fP (\fBIFAPI_POLICY_EXEC_CTX\fP *pol_ctx, TPMI_ALG_HASH hash_alg, \fBTPMS_POLICY\fP *policy)"
- .br
- .in -1c
- .SH "Detailed Description"
- .PP
- Provides internal functions for policy execution\&.
- .SH "Function Documentation"
- .PP
- .SS "TSS2_RC get_policy_digest_idx (TPML_DIGEST_VALUES * digest_values, TPMI_ALG_HASH hashAlg, size_t * idx)"
- Compute the index for the current digest list and clear the digest\&.
- .PP
- The list entry with the appropriate hash algorithm will be searched\&. The found digest will be set to zero\&.
- .PP
- \fBParameters:\fP
- .RS 4
- \fIdigest_values\fP The list of policy digests and corresponding hash algorithms\&.
- .br
- \fIhashAlg\fP The hash algorithm to be searched\&.
- .br
- \fIidx\fP The index of the found digest\&.
- .RE
- .PP
- \fBReturn values:\fP
- .RS 4
- \fITSS2_RC_SUCCESS\fP on success\&.
- .br
- \fITSS2_FAPI_RC_BAD_VALUE\fP If no appropriate digest was found in the digest list\&.
- .RE
- .PP
- .SS "TSS2_RC ifapi_extend_authorization (\fBTPMS_POLICY\fP * policy, \fBTPMS_POLICYAUTHORIZATION\fP * authorization)"
- Add a new authorization to a policy\&.
- .PP
- The the signed hash computed from the policy digest and the policyRef together with the public key of the key used for signing will be stored in the policy\&.
- .PP
- \fBParameters:\fP
- .RS 4
- \fIpolicy\fP The policy to be authorized\&.
- .br
- \fIauthorization\fP The structure with the signature, the policyRef and the public key\&.
- .RE
- .PP
- \fBReturn values:\fP
- .RS 4
- \fITSS2_RC_SUCCESS\fP on success\&.
- .br
- \fITSS2_FAPI_RC_MEMORY\fP If the memory for the authorization list cannot be allocated\&.
- .RE
- .PP
- .SS "TSS2_RC ifapi_policyeval_execute (\fBESYS_CONTEXT\fP * esys_ctx, \fBIFAPI_POLICY_EXEC_CTX\fP * current_policy)"
- Execute all policy commands defined by a list of policy elements\&.
- .PP
- \fBReturn values:\fP
- .RS 4
- \fITSS2_RC_SUCCESS\fP on success\&.
- .br
- \fITSS2_FAPI_RC_MEMORY\fP if not enough memory can be allocated\&.
- .br
- \fITSS2_FAPI_RC_BAD_VALUE\fP If wrong values are detected during execution\&.
- .br
- \fITSS2_FAPI_RC_IO_ERROR\fP If an error occurs during access to the policy store\&.
- .br
- \fITSS2_FAPI_RC_POLICY_UNKNOWN\fP If policy search for a certain policy digest was not successful\&.
- .br
- \fITSS2_FAPI_RC_BAD_TEMPLATE\fP In a invalid policy is loaded during execution\&.
- .br
- \fITSS2_FAPI_RC_TRY_AGAIN\fP if an I/O operation is not finished yet and this function needs to be called again\&.
- .br
- \fITSS2_FAPI_RC_GENERAL_FAILURE\fP if an internal error occurred\&.
- .br
- \fITSS2_FAPI_RC_BAD_SEQUENCE\fP if the context has an asynchronous operation already pending\&.
- .br
- \fITSS2_FAPI_RC_BAD_REFERENCE\fP a invalid null pointer is passed\&.
- .br
- \fITSS2_FAPI_RC_PATH_NOT_FOUND\fP if a FAPI object path was not found during authorization\&.
- .br
- \fITSS2_FAPI_RC_KEY_NOT_FOUND\fP if a key was not found\&.
- .br
- \fITSS2_FAPI_RC_AUTHORIZATION_UNKNOWN\fP if a required authorization callback is not set\&.
- .br
- \fITSS2_FAPI_RC_AUTHORIZATION_FAILED\fP if the authorization attempt fails\&.
- .br
- \fITSS2_ESYS_RC_*\fP possible error codes of ESAPI\&.
- .br
- \fITSS2_FAPI_RC_BAD_PATH\fP if the path is used in inappropriate context or contains illegal characters\&.
- .br
- \fITSS2_FAPI_RC_NOT_PROVISIONED\fP FAPI was not provisioned\&.
- .RE
- .PP
- .SS "TSS2_RC ifapi_policyeval_execute_prepare (\fBIFAPI_POLICY_EXEC_CTX\fP * pol_ctx, TPMI_ALG_HASH hash_alg, \fBTPMS_POLICY\fP * policy)"
- Initialize policy element list to be executed and store policy in context\&.
- .PP
- \fBParameters:\fP
- .RS 4
- \fIpol_ctx\fP Context for execution of a list of policy elements\&.
- .br
- \fIhash_alg\fP The hash algorithm used for the policy computation\&.
- .br
- \fIpolicy\fP The policy to be executed\&. Some policy elements will be used to store computed parameters needed for policy execution\&.
- .RE
- .PP
- \fBReturn values:\fP
- .RS 4
- \fITSS2_RC_SUCCESS\fP on success\&.
- .br
- \fITSS2_FAPI_RC_AUTHORIZATION_UNKNOWN\fP If the callback for branch selection is not defined\&. This callback will be needed of or policies have to be executed\&.
- .br
- \fITSS2_FAPI_RC_BAD_VALUE\fP If the computed branch index deliverd by the callback does not identify a branch\&.
- .br
- \fITSS2_FAPI_RC_MEMORY\fP if not enough memory can be allocated\&.
- .br
- \fITSS2_FAPI_RC_BAD_REFERENCE\fP a invalid null pointer is passed\&.
- .br
- \fITSS2_FAPI_RC_AUTHORIZATION_FAILED\fP if the authorization attempt fails\&.
- .RE
- .PP
- .SH "Author"
- .PP
- Generated automatically by Doxygen for tpm2-tss from the source code\&.
|