---
name: "fido_assert_verify"
section: "3"
platform: "linux"
package: "libfido2"
version: "1.17.0-1"
release: "Arch Linux 2026-11-01"
platforms: ["linux"]
url: "https://new.carta.tech/fido_assert_verify"
---

# fido\_assert\_verify(3)

verifies the signature of a FIDO2 assertion statement

## NAME

**fido\_assert\_verify** – verifies the signature of a FIDO2 assertion statement

## SYNOPSIS

**#include \<fido.h\>**

*int*\

**fido\_assert\_verify**(*const fido\_assert\_t \*assert*, *size\_t idx*, *int cose\_alg*, *const void \*pk*);

## DESCRIPTION

The **fido\_assert\_verify**() function verifies whether the signature contained in statement index *idx* of *assert* matches the parameters of the assertion. Before using **fido\_assert\_verify**() in a sensitive context, the reader is strongly encouraged to make herself familiar with the FIDO2 assertion statement process as defined in the Web Authentication (webauthn) standard.

A brief description follows:

The **fido\_assert\_verify**() function verifies whether the client data hash, relying party ID, user presence and user verification attributes of *assert* have been attested by the holder of the private counterpart of the public key *pk* of COSE type *cose\_alg*, where *cose\_alg* is COSE\_ES256, COSE\_ES384, COSE\_RS256, or COSE\_EDDSA, and *pk* points to a *es256\_pk\_t*, *es384\_pk\_t*, *rs256\_pk\_t*, or *eddsa\_pk\_t* type accordingly.

Please note that the first statement in *assert* has an *idx* of 0.

## RETURN VALUES

The error codes returned by **fido\_assert\_verify**() are defined in ⟨fido/err.h⟩. If statement *idx* of *assert* passes verification with *pk*, then FIDO\_OK is returned.

## SEE ALSO

[fido\_assert\_new(3)](/fido_assert_new/3.md), [fido\_assert\_set\_authdata(3)](/fido_assert_set_authdata/3.md)
