FIDO2-CRED(1)
π FIDO2-CRED π
okay bestie, listen UP, because this one is a whole manual page β it's from the General Commands Manual, it's called fido2-cred, and it is literally the main character of FIDO2 credentials. π
β¨ NAME β¨
fido2-cred β make/verify a FIDO2 credential
πΈ SYNOPSIS πΈ
fido2-cred -M [-bdhqruvw] [-t option] [-a mode] [-c cred_protect]
[-i input_file] [-o output_file] device [type]
fido2-cred -V [-dhv] [-c cred_protect] [-i input_file] [-o output_file]
[type]
π¦ DESCRIPTION π¦
So, fido2-cred makes or verifies a FIDO2 credential. That's the whole vibe. π
A credential type can be one of these four, and no, they're not interchangeable, they're each their own little icon:
es256β denoting ECDSA over NIST P-256 with SHA-256es384β denoting ECDSA over NIST P-384 with SHA-384rs256β denoting 2048-bit RSA with PKCS#1.5 padding and SHA-256eddsaβ denoting EDDSA over Curve25519 with SHA-512
If type is not specified, es256 is assumed. defaults, she's serving π«Ά
When making a credential, the authenticator may require the user to authenticate with a PIN. If the -q option is not specified, fido2-cred will prompt the user for the PIN. If a tty is available, fido2-cred will use it to obtain the PIN. Otherwise, stdin is used.
The input of fido2-cred is defined by the parameters of the credential to be made/verified. Peep the βINPUT FORMATβ section for the deets. π
The output of fido2-cred is defined by the result of the selected operation. That's the βOUTPUT FORMATβ section, go look. β¨
If a credential is successfully created or verified, fido2-cred exits 0. Otherwise, fido2-cred exits 1. that's it, that's the whole pass/fail system, no cap π
The options are as follows:
π OPTIONS π
-Mβ Tellsfido2-credto make a new credential on device. β¨-Vβ Tellsfido2-credto verify a credential. π-bβ Request the credential's βlargeBlobKeyβ, a 32-byte symmetric key associated with the generated credential.-amode β When making a credential, request enterprise attestation. Please refer to<fido/param.h>for the set of possible values. (yes bestie, go read the header, I'm not making stuff up π«Ά)-ccred_protect β If making a credential, set the credential's protection level to cred_protect, where cred_protect is the credential's protection level in decimal notation. Please refer to<fido/param.h>for the set of possible values. If verifying a credential, check whether the credential's protection level was signed by the authenticator as cred_protect. π-dβ Causesfido2-credto emit debugging output on stderr. messy but informative π-hβ If making a credential, enable the FIDO2 hmac-secret extension. If verifying a credential, check whether the extension data bit was signed by the authenticator. π-iinput_file β Tellsfido2-credto read the parameters of the credential from input_file instead of stdin.-ooutput_file β Tellsfido2-credto write output on output_file instead of stdout.-qβ Tellsfido2-credto be quiet. If a PIN is required and-qis specified,fido2-credwill fail. π€« no PIN prompt for you, it just gives up-rβ Create a resident credential. Resident credentials are called βdiscoverable credentialsβ in CTAP 2.1. (name drop! π)-toption β Toggles a key/value option, where option is a string of the form βkey=valueβ. The options supported at present are:uv=true|falseβ Asks the authenticator for user verification to be enabled or disabled.pin=true|falseβ Tellsfido2-credwhether to prompt for a PIN and request user verification.
The -t option may be specified multiple times. stack 'em π
-uβ Create a U2F credential. By default,fido2-credwill use FIDO2 if supported by the authenticator, and fallback to U2F otherwise.-vβ If making a credential, request user verification. If verifying a credential, check whether the user verification bit was signed by the authenticator.-wβ Tellsfido2-credthat the first line of input when making a credential shall be interpreted as unhashed client data. This is required by Windows Hello, which calculates the client data hash internally. (windows hello doing its own little thing, iconic honestly π)
π§ INPUT FORMAT π§
The input of fido2-cred consists of base64 blobs and UTF-8 strings separated by newline characters ('\n').
When making a credential, fido2-cred expects its input to consist of:
- client data hash (base64 blob);
- relying party id (UTF-8 string);
- user name (UTF-8 string);
- user id (base64 blob).
When verifying a credential, fido2-cred expects its input to consist of:
- client data hash (base64 blob);
- relying party id (UTF-8 string);
- credential format (UTF-8 string);
- CBOR encoded authenticator data (base64 blob);
- credential id (base64 blob);
- attestation signature (base64 blob);
- attestation certificate (optional, base64 blob).
β οΈ UTF-8 strings passed to fido2-cred must not contain embedded newline or NUL characters. fr fr, it will not vibe with those.
π OUTPUT FORMAT π
The output of fido2-cred consists of base64 blobs, UTF-8 strings, and PEM-encoded public keys separated by newline characters ('\n').
Upon the successful generation of a credential, fido2-cred outputs:
- client data hash (base64 blob);
- relying party id (UTF-8 string);
- credential format (UTF-8 string);
- CBOR encoded authenticator data (base64 blob);
- credential id (base64 blob);
- attestation signature (base64 blob);
- attestation certificate, if present (base64 blob).
- the credential's associated 32-byte symmetric key (βlargeBlobKeyβ), if present (base64 blob).
Upon the successful verification of a credential, fido2-cred outputs:
- credential id (base64 blob);
- PEM-encoded credential key. π
π₯ EXAMPLES π₯
Create a new es256 credential on /dev/hidraw5, verify it, and save the id and the public key of the credential in cred:
$ echo credential challenge | openssl sha256 -binary | base64 > cred_param
$ echo relying party >> cred_param
$ echo user name >> cred_param
$ dd if=/dev/urandom bs=1 count=32 | base64 >> cred_param
$ fido2-cred -M -i cred_param /dev/hidraw5 | fido2-cred -V -o cred
like, look at her. making a credential and verifying it in one pipe. ate. π β¨
π SEE ALSO π
fido2-assert(1), fido2-token(1)
π CAVEATS π
Please note that fido2-cred handles Basic Attestation and Self Attestation transparently. In the case of Basic Attestation, the validity of the authenticator's attestation certificate is not verified.
π¨ bestie that's a real one β it's transparent about it, but it does not check that certificate's validity. know that going in.
okay that's the whole page, you're so welcome π«Ά this was Debian, dated December 8, 2025 β go make some credentials, you got this, mwah π
π¦ where this page comes from
- arch rolling: libfido2 1.17.0-1 Β· BSD-2-Clause
- nixpkgs unstable: libfido2 1.17.0
- ubuntu stonking: fido2-tools 1.17.0-2build1 Β· BSD-2-Clause
- π the page's license: BSD-2-Clause
- Copyright (c) 2018-2026 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