Skip to content

fix(nfc): recognise FIDO_2_1, FIDO_2_1_PRE, FIDO_2_2 in select_fido2#197

Merged
AlfioEmanueleFresta merged 1 commit into
masterfrom
fix/nfc-version-strings
May 12, 2026
Merged

fix(nfc): recognise FIDO_2_1, FIDO_2_1_PRE, FIDO_2_2 in select_fido2#197
AlfioEmanueleFresta merged 1 commit into
masterfrom
fix/nfc-version-strings

Conversation

@AlfioEmanueleFresta
Copy link
Copy Markdown
Member

Stricter CTAP 2.1+ NFC authenticators advertise the version string FIDO_2_1, FIDO_2_1_PRE, or FIDO_2_2 from the FIDO AID SELECT response without shadowing as U2F_V2. The current code only matches FIDO_2_0 and U2F_V2, so those devices are reported as supporting neither protocol.

Changes

  • Match all spec-defined version strings in select_fido2.
  • Add a unit test for the version-string classifier.

Other NFC items (CTAP2 keepalive, SELECT Le, SW preservation) are tracked separately in #195.

Refs: CTAP 2.2 section 11.3.1.

@AlfioEmanueleFresta AlfioEmanueleFresta marked this pull request as ready for review May 10, 2026 20:10
Stricter CTAP 2.1+ NFC authenticators advertise their version string as
"FIDO_2_1", "FIDO_2_1_PRE", or "FIDO_2_2" from the FIDO AID SELECT
response without shadowing as "U2F_V2". The current code only matches
"FIDO_2_0" and "U2F_V2", so those devices are reported as supporting
neither protocol and are unusable.

Factor the version-string check into a helper and match all spec-defined
strings. Keep the U2F_V2 fallback that probes ctap2_get_info.
@AlfioEmanueleFresta AlfioEmanueleFresta force-pushed the fix/nfc-version-strings branch from a282788 to cf17d75 Compare May 12, 2026 18:18
@AlfioEmanueleFresta AlfioEmanueleFresta merged commit 9099de3 into master May 12, 2026
4 checks passed
@AlfioEmanueleFresta AlfioEmanueleFresta deleted the fix/nfc-version-strings branch May 12, 2026 18:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant