From 86e3c960a473001a2b0d6ccde3f0df7ae32e4462 Mon Sep 17 00:00:00 2001 From: Pol Henarejos Date: Thu, 22 Sep 2022 10:00:06 +0200 Subject: [PATCH] Fix when no pin is provided. 6.1.3.7.1 is too ambiguous on uv == false. We also accept that is not provided. Signed-off-by: Pol Henarejos --- src/fido/cbor_make_credential.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/fido/cbor_make_credential.c b/src/fido/cbor_make_credential.c index 0ac30ee..9dda767 100644 --- a/src/fido/cbor_make_credential.c +++ b/src/fido/cbor_make_credential.c @@ -197,7 +197,7 @@ int cbor_make_credential(const uint8_t *data, size_t len) { //else if (options.up == NULL) //5.7 //rup = ptrue; } - if (pinUvAuthParam.present == false && options.uv == pfalse && file_has_data(ef_pin)) { //8.1 + if (pinUvAuthParam.present == false && options.uv != ptrue && file_has_data(ef_pin)) { //8.1 CBOR_ERROR(CTAP2_ERR_PUAT_REQUIRED); } if (enterpriseAttestation > 0) {