---
name: "Fapi_SetSignCB"
section: "3"
platform: "linux"
package: "tpm2-tss"
version: "4.2.0-2"
release: "Arch Linux 2026-11-01"
platforms: ["linux"]
url: "https://new.carta.tech/Fapi_SetSignCB"
---

# Fapi\_SetSignCB(3)

Fapi\_SetSignCB

## NAME

Fapi\_SetSignCB - Fapi\_SetSignCB

## SYNOPSIS

### Typedefs

typedef TSS2\_RC(\* **Fapi\_CB\_Sign**) (char const \*objectPath, char const \*description, char const \*publicKey, char const \*publicKeyHint, uint32\_t hashAlg, uint8\_t const \*dataToSign, size\_t dataToSignSize, uint8\_t const \*\*signature, size\_t \*signatureSize, void \*userData)\
 typedef TSS2\_RC(\* **Fapi\_CB\_PolicyAction**) (char const \*objectPath, char const \*action, void \*userData)\

### Functions

TSS2\_RC **Fapi\_SetSignCB** (**FAPI\_CONTEXT** \*context, Fapi\_CB\_Sign callback, void \*userData)\
 TSS2\_RC **Fapi\_SetPolicyActionCB** (**FAPI\_CONTEXT** \*context, Fapi\_CB\_PolicyAction callback, void \*userData)\

## Detailed Description

FAPI functions to invoke SetSignCB.

## Function Documentation

### TSS2\_RC Fapi\_SetPolicyActionCB (FAPI\_CONTEXT \* context, Fapi\_CB\_PolicyAction callback, void \* userData)

Fapi\_SetActionCB() registers an application-defined function as a callback that shall be called back upon encountering a policy action element.

**Parameters**

*context* The **FAPI\_CONTEXT** \
 *callback* The callback function for branch selection \
 *userData* A pointer that is provided to all callback invocations

**Return values**

*TSS2\_RC\_SUCCESS* if the function call was a success. \
 *TSS2\_FAPI\_RC\_BAD\_REFERENCE* if the context is NULL. \
 *TSS2\_FAPI\_RC\_BAD\_CONTEXT* if context corruption is detected. \
 *TSS2\_FAPI\_RC\_MEMORY* if the FAPI cannot allocate enough memory for internal operations or return parameters. \
 *TSS2\_FAPI\_RC\_BAD\_SEQUENCE* if the synchronous or Async functions are called while the context has another asynchronous operation outstanding, or the Finish function is called while the context does not have an appropriate asynchronous operation outstanding. \
 *TSS2\_FAPI\_RC\_IO\_ERROR* if the data cannot be saved.

### TSS2\_RC Fapi\_SetSignCB (FAPI\_CONTEXT \* context, Fapi\_CB\_Sign callback, void \* userData)

**Fapi\_SetSignCB()** registers an application-defined function as a callback to allow the FAPI to get signatures authorizing use of TPM objects.

**Parameters**

*context* The **FAPI\_CONTEXT** \
 *callback* The callback function for signing selection \
 *userData* A pointer that is provided to all callback invocations

**Return values**

*TSS2\_RC\_SUCCESS* if the function call was a success. \
 *TSS2\_FAPI\_RC\_BAD\_REFERENCE* if the context is NULL. \
 *TSS2\_FAPI\_RC\_BAD\_CONTEXT* if context corruption is detected. \
 *TSS2\_FAPI\_RC\_MEMORY* if the FAPI cannot allocate enough memory for internal operations or return parameters. \
 *TSS2\_FAPI\_RC\_BAD\_SEQUENCE* if the synchronous or Async functions are called while the context has another asynchronous operation outstanding, or the Finish function is called while the context does not have an appropriate asynchronous operation outstanding. \
 *TSS2\_FAPI\_RC\_IO\_ERROR* if the data cannot be saved.

## Author

Generated automatically by Doxygen for tpm2-tss from the source code.
