Fapi_Provision(3)
π
Fapi_Provision(3) β the glam Library Functions Manual entry, bestie
okay so this is the Fapi_Provision page from the Library Functions Manual, and honestly? It's the "get your TPM all set up and cute" page. Let's get into it β¨
πΈ NAME πΈ
Fapi_Provision β yes, that's literally just the name again. The manpage is being mysterious. I respect it. π
π¦ SYNOPSIS π¦
Functions
TSS2_RC Fapi_Provision (FAPI_CONTEXT *context, char const *authValueEh,
char const *authValueSh, char const *authValueLockout)
TSS2_RC Fapi_Provision_Async (FAPI_CONTEXT *context, char const
*authValueEh, char const *authValueSh, char const *authValueLockout)
TSS2_RC Fapi_Provision_Finish (FAPI_CONTEXT *context)
π Detailed Description π
These are the FAPI functions that invoke Provision, and you can run it two ways: as a one-call situation, or in an asynchronous manner. Pick your fighter. π₯
π Function Documentation π
π TSS2_RC Fapi_Provision (FAPI_CONTEXT * context, char const * authValueEh, char const * authValueSh, char const * authValueLockout)
Bestie. This is the one-call function for the initial FAPI provisioning. The main character of the page. π
So what does it actually do? It provisions a TSS with its TPM β which includes setting the important passwords and policy settings, readout of the EK and its certificate, and the initialization of the system-wide keystore. That's a lot of slaying in one call, ngl. β¨
Parameters
contextβ TheFAPI_CONTEXT.authValueEhβ The authorization value for the endorsement hierarchy. May beNULL.authValueShβ The authorization value for the storage hierarchy. Should beNULL.authValueLockoutβ The authorization value for lockout.
Return values
TSS2_RC_SUCCESSif the function call was a success. πTSS2_FAPI_RC_BAD_REFERENCEifcontextisNULL.TSS2_FAPI_RC_BAD_CONTEXTif context corruption is detected.TSS2_FAPI_RC_BAD_SEQUENCEif the context has an asynchronous operation already pending.TSS2_FAPI_RC_NO_CERTif no certificate was found for the computed EK.TSS2_FAPI_RC_BAD_KEYif public key of the EK does not match the configured certificate or the configured fingerprint does not match the computed EK.TSS2_FAPI_RC_IO_ERRORif the data cannot be saved.TSS2_FAPI_RC_MEMORYif the FAPI cannot allocate enough memory for internal operations or return parameters.TSS2_FAPI_RC_NO_TPMif FAPI was initialized in no-TPM-mode via its config file.TSS2_FAPI_RC_TRY_AGAINif an I/O operation is not finished yet and this function needs to be called again.TSS2_FAPI_RC_BAD_VALUEif an invalid value was passed into the function.TSS2_FAPI_RC_AUTHORIZATION_UNKNOWNif a required authorization callback is not set.TSS2_FAPI_RC_AUTHORIZATION_FAILEDif the authorization attempt fails.TSS2_FAPI_RC_GENERAL_FAILUREif an internal error occurred.TSS2_FAPI_RC_POLICY_UNKNOWNif policy search for a certain policy digest was not successful.TSS2_FAPI_RC_PATH_NOT_FOUNDif a FAPI object path was not found during authorization.TSS2_FAPI_RC_KEY_NOT_FOUNDif a key was not found.TSS2_ESYS_RC_*possible error codes of ESAPI.TSS2_FAPI_RC_BAD_PATHif the path is used in inappropriate context or contains illegal characters.TSS2_FAPI_RC_NOT_PROVISIONEDFAPI was not provisioned.TSS2_FAPI_RC_PATH_ALREADY_EXISTSif the object already exists in object store.
π TSS2_RC Fapi_Provision_Async (FAPI_CONTEXT * context, char const * authValueEh, char const * authValueSh, char const * authValueLockout)
The asynchronous function for the initial FAPI provisioning. Same assignment, different schedule. π
It provisions a TSS with its TPM β setting of important passwords and policy settings, readout of the EK and its certificate, and initialization of the system-wide keystore. All that good stuff, just not right this second.
Then you call Fapi_Provision_Finish to finish the execution of this command. Don't leave it hanging, bestie. π
Parameters
contextβ TheFAPI_CONTEXT.authValueEhβ The authorization value for the endorsement hierarchy. May beNULL.authValueShβ The authorization value for the storage hierarchy. Should beNULL.authValueLockoutβ The authorization value for lockout.
Return values
TSS2_RC_SUCCESSif the function call was a success. πTSS2_FAPI_RC_BAD_REFERENCEifcontextisNULL.TSS2_FAPI_RC_BAD_CONTEXTif context corruption is detected.TSS2_FAPI_RC_BAD_SEQUENCEif the context has an asynchronous operation already pending.TSS2_FAPI_RC_IO_ERRORif the data cannot be saved.TSS2_FAPI_RC_MEMORYif the FAPI cannot allocate enough memory for internal operations or return parameters.TSS2_FAPI_RC_NO_TPMif FAPI was initialized in no-TPM-mode via its config file.TSS2_FAPI_RC_BAD_VALUEif an invalid value was passed into the function.TSS2_FAPI_RC_BAD_PATHif the path is used in inappropriate context or contains illegal characters.TSS2_FAPI_RC_PATH_NOT_FOUNDif a FAPI object path was not found during authorization.
π§ TSS2_RC Fapi_Provision_Finish (FAPI_CONTEXT * context)
The asynchronous finish function for Fapi_Provision. The closer. The finale. The "okay we're done here" moment. π«
This function should be called after a previous Fapi_Provision_Async. That's the whole vibe β async first, finish second. iykyk.
Parameters
contextβ TheFAPI_CONTEXT
Return values
TSS2_RC_SUCCESSif the function call was a success. πTSS2_FAPI_RC_BAD_REFERENCEifcontextisNULL.TSS2_FAPI_RC_BAD_CONTEXTif context corruption is detected.TSS2_FAPI_RC_BAD_SEQUENCEif the context has an asynchronous operation already pending.TSS2_FAPI_RC_NO_CERTif no certificate was found for the computed EK.TSS2_FAPI_RC_BAD_KEYif public key of the EK does not match the configured certificate or the configured fingerprint does not match the computed EK.TSS2_FAPI_RC_IO_ERRORif the data cannot be saved.TSS2_FAPI_RC_MEMORYif the FAPI cannot allocate enough memory for internal operations or return parameters.TSS2_FAPI_RC_TRY_AGAINif the asynchronous operation is not yet complete. Call this function again later.TSS2_FAPI_RC_BAD_VALUEif an invalid value was passed into the function.TSS2_FAPI_RC_AUTHORIZATION_UNKNOWNif a required authorization callback is not set.TSS2_FAPI_RC_AUTHORIZATION_FAILEDif the authorization attempt fails.TSS2_FAPI_RC_GENERAL_FAILUREif an internal error occurred.TSS2_FAPI_RC_POLICY_UNKNOWNif policy search for a certain policy digest was not successful.TSS2_FAPI_RC_PATH_NOT_FOUNDif a FAPI object path was not found during authorization.TSS2_FAPI_RC_KEY_NOT_FOUNDif a key was not found.TSS2_ESYS_RC_*possible error codes of ESAPI.TSS2_FAPI_RC_NOT_PROVISIONEDFAPI was not provisioned.TSS2_FAPI_RC_BAD_PATHif the path is used in inappropriate context or contains illegal characters.TSS2_FAPI_RC_PATH_ALREADY_EXISTSif the object already exists in object store.
And then there's these three little lines that the manpage just drops in with zero context, and we're keeping them verbatim because facts are facts, bestie: π«Ά
- < Certificates will be stored at even address
- < RSA template
- < ECC template
π Author π
Generated automatically by Doxygen for tpm2-tss from the source code. Not a human author, just Doxygen doing Doxygen things. π€β¨
And that's the page, babe β brought to you by tpm2-tss, Version 4.1.5. Go provision something iconic. ππ¦
π¦ where this page comes from
- fedora 44: tpm2-tss-devel 4.1.5-1.fc44 Β· BSD-2-Clause
- fedora 44: tpm2-tss-devel 4.1.5-1.fc44 Β· BSD-2-Clause
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms