FIDO_DEV_GET_ASSERT(3)
π FIDO_DEV_GET_ASSERT(3) π
okay bestie, pull up a chair, we're reading a library functions manual page and honestly? it's giving iconic. this one's all about fido_dev_get_assert from the fido library β yes the FIDO2 one, the security-key one, the one that makes you feel like a hacker every time you boop your little key π¦
β¨ NAME β¨
fido_dev_get_assert β obtains an assertion from a FIDO2 device
like. it goes and gets you an assertion. from a FIDO2 device. that's the whole vibe π
πΈ SYNOPSIS πΈ
#include <fido.h>
int
fido_dev_get_assert(fido_dev_t *dev, fido_assert_t *assert,
const char *pin);
three args, no cap. dev, assert, pin. that's the trio π
π DESCRIPTION π
so the way that fido_dev_get_assert() works is it asks the FIDO2 device represented by dev for an assertion, and it builds that request according to these parameters that live inside assert:
- relying party ID
- client data hash
- list of allowed credential IDs
- user presence and user verification attributes
obsessed. literally everything it needs is already chilling in assert.
if you wanna know how those values get set in the first place, go read fido_assert_set_authdata(3) β that's the one that handles it. iykyk π
now, the pin situation. if a PIN is not needed to authenticate the request against dev, then pin may be NULL. cute, no PIN, no problem. but otherwise β and this is the important part, bestie β pin must point to a NUL-terminated UTF-8 string. not a vibe, not a guess, an actual NUL-terminated UTF-8 string. periodt π
and once fido_dev_get_assert() returns successfully? ohhh that's when the fun starts. you can then invoke all of these on assert to pull out the various attributes of the generated assertion:
fido_assert_count(3)fido_assert_user_display_name(3)fido_assert_user_icon(3)fido_assert_user_name(3)fido_assert_authdata_ptr(3)fido_assert_user_id_ptr(3)fido_assert_sig_ptr(3)fido_assert_sigcount(3)
eight whole little getters, all lined up, all ready to spill the tea about your assertion. main character energy fr fr β¨
β οΈ also please note: fido_dev_get_assert() is synchronous and will block if necessary. so like, it's not gonna go do seventeen other things while you wait. it waits. you wait. everyone waits together. plan accordingly π«Ά
β RETURN VALUES β
the error codes returned by fido_dev_get_assert() are defined in <fido/err.h>. go look there if something's off, she's got the receipts.
on success, FIDO_OK is returned. that's the good one. the slay one. the one you want to see π
π SEE ALSO π
and that's the page, bestie!! π this was the Debian version of the FIDO_DEV_GET_ASSERT(3) manual, dated May 24, 2018 β go forth and get those assertions, you've absolutely got this πβ¨πΈ
π¦ where this page comes from
- alpine 3.22: libfido2-doc 1.16.0-r0 Β· BSD-2-Clause
- alpine 3.23: libfido2-doc 1.16.0-r2 Β· BSD-2-Clause
- alpine 3.24: libfido2-doc 1.16.0-r4 Β· BSD-2-Clause
- arch rolling: libfido2 1.17.0-1 Β· BSD-2-Clause
- centos-stream 10: libfido2-devel 1.14.0-7.el10 Β· BSD-2-Clause
- centos-stream 9: libfido2-devel 1.13.0-2.el9 Β· BSD
- centos-stream 9: libfido2-devel 1.13.0-2.el9 Β· BSD
- debian bookworm: libfido2-doc 1.12.0-2 Β· BSD-2-Clause
- debian trixie: libfido2-doc 1.15.0-1 Β· BSD-2-Clause
- fedora 43: libfido2-devel 1.16.0-3.fc43 Β· BSD-2-Clause
- fedora 43: libfido2-devel 1.16.0-3.fc43 Β· BSD-2-Clause
- fedora 44: libfido2-devel 1.16.0-5.fc44 Β· BSD-2-Clause
- fedora 44: libfido2-devel 1.16.0-5.fc44 Β· BSD-2-Clause
- nixos 26.05: fido2-manage 0-unstable-2025-06-06
- nixpkgs unstable: fido2-manage 0-unstable-2025-06-06
- nixpkgs unstable: libfido2 1.17.0
- opensuse-leap 16.0: libfido2-devel 1.15.0-160000.3.2 Β· BSD-2-Clause
- opensuse-leap 16.0: libfido2-devel 1.15.0-160000.3.2 Β· BSD-2-Clause
- opensuse-leap 16.0: libfido2-devel 1.15.0-160000.3.2 Β· BSD-2-Clause
- opensuse-leap 16.0: libfido2-devel 1.15.0-160000.3.2 Β· BSD-2-Clause
- ubuntu noble: libfido2-doc 1.14.0-1build3 Β· BSD-2-Clause
- ubuntu questing: libfido2-doc 1.16.0-2
- ubuntu resolute: libfido2-doc 1.16.0-2build1 Β· BSD-2-Clause
- ubuntu stonking: libfido2-doc 1.17.0-2build1 Β· BSD-2-Clause
- π the page's license: BSD-2-Clause
- Copyright (c) 2018 Yubico AB. All rights reserved
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms