FIDO2-ASSERT(1)
π FIDO2-ASSERT(1) β the manual, but make it make sense
okay bestie, welcome to fido2-assert, a little command-line icon from the General Commands Manual section of your system. she gets and verifies FIDO2 assertions, and honestly? she's carrying the whole security-key ecosystem on her back. π
β¨ NAME β¨
fido2-assert β get/verify a FIDO2 assertion
π¦ SYNOPSIS π¦
fido2-assert -G [-bdhpruvw] [-t option] [-i input_file] [-o output_file]
device
fido2-assert -V [-dhpv] [-i input_file] key_file [type]
so there's two whole moods she can be in: obtain (-G) and verify (-V). pick your lane, queen. π
πΈ DESCRIPTION πΈ
fido2-assert gets or verifies a FIDO2 assertion. that's the vibe. that's the whole job.
The input of fido2-assert is defined by the parameters of the assertion to be obtained/verified. See the βINPUT FORMATβ section for details. (yes, there's a whole section. scroll down. i got you. π)
The output of fido2-assert is defined by the result of the selected operation. See the βOUTPUT FORMATβ section for details.
If an assertion is successfully obtained or verified, fido2-assert exits 0. Otherwise, fido2-assert exits 1. no in-between, no drama, just binary success energy. β¨
The options are as follows:
-Gβ Tellsfido2-assertto obtain a new assertion from device. go get it, girl.-Vβ Tellsfido2-assertto verify an assertion using the PEM-encoded public key in key_file of type type, where type may bees256(denoting ECDSA over NIST P-256 with SHA-256),es384(denoting ECDSA over NIST P-384 with SHA-384),rs256(denoting 2048-bit RSA with PKCS#1.5 padding and SHA-256), oreddsa(denoting EDDSA over Curve25519 with SHA-512). If type is not specified,es256is assumed. default queen behavior fr fr.-bβ Request the credential's βlargeBlobKeyβ, a 32-byte symmetric key associated with the asserted credential.-hβ If obtaining an assertion, enable the FIDO2 hmac-secret extension. If verifying an assertion, check whether the extension data bit was signed by the authenticator.-dβ Causesfido2-assertto emit debugging output onstderr. she's telling you everything, bestie. every little thought. π«Ά-iinput_file β Tellsfido2-assertto read the parameters of the assertion from input_file instead ofstdin.-ooutput_file β Tellsfido2-assertto write output on output_file instead ofstdout.-pβ If obtaining an assertion, request user presence. If verifying an assertion, check whether the user presence bit was signed by the authenticator. (that's you, tapping the key. main character energy. π)-rβ Obtain an assertion using a resident credential. If-ris specified,fido2-assertwill not expect a credential id in its input, and may output multiple assertions. Resident credentials are called βdiscoverable credentialsβ in CTAP 2.1. iconic rebrand honestly.-toption β Toggles a key/value option, where option is a string of the form βkey=valueβ. The options supported at present are:up=true|falseβ Asks the authenticator for user presence to be enabled or disabled.uv=true|falseβ Asks the authenticator for user verification to be enabled or disabled.pin=true|falseβ Tellsfido2-assertwhether to prompt for a PIN and request user verification.
The -t option may be specified multiple times. stack 'em, bestie. π§
-uβ Obtain an assertion using U2F. By default,fido2-assertwill use FIDO2 if supported by the authenticator, and fallback to U2F otherwise. she tries the new thing first, then the old reliable. no cap.-vβ If obtaining an assertion, prompt the user for a PIN and request user verification from the authenticator. If verifying an assertion, check whether the user verification bit was signed by the authenticator.-wβ Tellsfido2-assertthat the first line of input when obtaining an assertion shall be interpreted as unhashed client data. This is required by Windows Hello, which calculates the client data hash internally. (windows hello being special, as always π)
If a tty is available, fido2-assert will use it to obtain the PIN. Otherwise, stdin is used. she'll find a way. she always does. π
π INPUT FORMAT π
The input of fido2-assert consists of base64 blobs and UTF-8 strings separated by newline characters ('\n').
When obtaining an assertion, fido2-assert expects its input to consist of:
- client data hash (base64 blob);
- relying party id (UTF-8 string);
- credential id, if credential not resident (base64 blob);
- hmac salt, if the FIDO2 hmac-secret extension is enabled (base64 blob);
When verifying an assertion, fido2-assert expects its input to consist of:
- client data hash (base64 blob);
- relying party id (UTF-8 string);
- CBOR encoded authenticator data (base64 blob);
- assertion signature (base64 blob);
UTF-8 strings passed to fido2-assert must not contain embedded newline or NUL characters. like, do not. she will simply not deal. π
π OUTPUT FORMAT π
The output of fido2-assert consists of base64 blobs and UTF-8 strings separated by newline characters ('\n').
For each generated assertion, fido2-assert outputs:
- client data hash (base64 blob);
- relying party id (UTF-8 string);
- CBOR encoded authenticator data (base64 blob);
- assertion signature (base64 blob);
- user id, if credential resident (base64 blob);
- hmac secret, if the FIDO2 hmac-secret extension is enabled (base64 blob);
- the credential's associated 32-byte symmetric key (βlargeBlobKeyβ), if requested (base64 blob).
When verifying an assertion, fido2-assert produces no output. silence. she's mysterious like that. π€«
π₯ EXAMPLES π₯
Assuming cred contains a es256 credential created according to the steps outlined in fido2-cred(1), obtain an assertion from an authenticator at /dev/hidraw5 and verify it:
$ echo assertion challenge | openssl sha256 -binary | base64 > assert_param
$ echo relying party >> assert_param
$ head -1 cred >> assert_param
$ tail -n +2 cred > pubkey
$ fido2-assert -G -i assert_param /dev/hidraw5 | fido2-assert -V pubkey es256
look at that pipeline. obtain on the left, verify on the right, zero chill in the middle. ate. π
π SEE ALSO π
iykyk. go read those too, bestie. β
this page came from Debian, version dated July 3, 2023. that's the whole sign-off. mwah. πβ¨π
π¦ 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
- fedora 43: fido2-tools 1.16.0-3.fc43 Β· BSD-2-Clause
- fedora 44: fido2-tools 1.16.0-5.fc44 Β· BSD-2-Clause
- nixpkgs unstable: libfido2 1.17.0
- ubuntu questing: fido2-tools 1.16.0-2
- ubuntu resolute: fido2-tools 1.16.0-2build1 Β· BSD-2-Clause
- ubuntu stonking: fido2-tools 1.17.0-2build1 Β· BSD-2-Clause
- π the page's license: BSD-2-Clause
- Copyright (c) 2018-2023 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