diff options
author | Damien Miller <djm@cvs.openbsd.org> | 2020-09-07 01:09:49 +0000 |
---|---|---|
committer | Damien Miller <djm@cvs.openbsd.org> | 2020-09-07 01:09:49 +0000 |
commit | 03ffdda6000483143594bd796fd8ca61d35617c4 (patch) | |
tree | 9e39279528ddbd23a47ba2a1dc7c52e260faa2d7 /lib/libfido2 | |
parent | 552915c6014c901b546da40832f84d8e4f625d14 (diff) |
sync a couple of minor fixes (no API/ABI change) to bring libfido2
in line with upstream 1.5.0
Diffstat (limited to 'lib/libfido2')
-rw-r--r-- | lib/libfido2/README.openbsd | 2 | ||||
-rw-r--r-- | lib/libfido2/man/fido_dev_get_touch_begin.3 | 8 | ||||
-rw-r--r-- | lib/libfido2/src/dev.c | 3 | ||||
-rw-r--r-- | lib/libfido2/src/u2f.c | 1 |
4 files changed, 10 insertions, 4 deletions
diff --git a/lib/libfido2/README.openbsd b/lib/libfido2/README.openbsd index 124e0e34d65..643512b1d4f 100644 --- a/lib/libfido2/README.openbsd +++ b/lib/libfido2/README.openbsd @@ -1,4 +1,4 @@ -This is an import of https://github.com/Yubico/libfido2 46710ac06 (20200815) +This is an import of https://github.com/Yubico/libfido2 1.5.0 (20200901) Local changes: diff --git a/lib/libfido2/man/fido_dev_get_touch_begin.3 b/lib/libfido2/man/fido_dev_get_touch_begin.3 index 5c987a1a9ad..4a9b9908cbd 100644 --- a/lib/libfido2/man/fido_dev_get_touch_begin.3 +++ b/lib/libfido2/man/fido_dev_get_touch_begin.3 @@ -2,7 +2,7 @@ .\" Use of this source code is governed by a BSD-style .\" license that can be found in the LICENSE file. .\" -.Dd $Mdocdate: August 23 2020 $ +.Dd $Mdocdate: September 7 2020 $ .Dt FIDO_DEV_GET_TOUCH_BEGIN 3 .Os .Sh NAME @@ -65,3 +65,9 @@ in source tree. .Sh SEE ALSO .Xr fido_dev_cancel 3 +.Sh CAVEATS +The +.Fn fido_dev_get_touch_status +function will cause a command to be transmitted to U2F +authenticators. +These transmissions should not exceed a frequency of 5Hz. diff --git a/lib/libfido2/src/dev.c b/lib/libfido2/src/dev.c index c84962cd96e..3463ae41d01 100644 --- a/lib/libfido2/src/dev.c +++ b/lib/libfido2/src/dev.c @@ -468,9 +468,10 @@ fido_dev_get_touch_status(fido_dev_t *dev, int *touched, int ms) return (u2f_get_touch_status(dev, touched, ms)); switch ((r = fido_rx_cbor_status(dev, ms))) { - case FIDO_ERR_PIN_INVALID: case FIDO_ERR_PIN_AUTH_INVALID: + case FIDO_ERR_PIN_INVALID: case FIDO_ERR_PIN_NOT_SET: + case FIDO_ERR_SUCCESS: *touched = 1; break; case FIDO_ERR_RX: diff --git a/lib/libfido2/src/u2f.c b/lib/libfido2/src/u2f.c index 406186a51b0..3c6ea82731d 100644 --- a/lib/libfido2/src/u2f.c +++ b/lib/libfido2/src/u2f.c @@ -835,7 +835,6 @@ u2f_get_touch_status(fido_dev_t *dev, int *touched, int ms) switch ((reply[reply_len - 2] << 8) | reply[reply_len - 1]) { case SW_CONDITIONS_NOT_SATISFIED: - usleep(200 * 1000); /* per spec (Chrome) */ if ((r = u2f_get_touch_begin(dev)) != FIDO_OK) { fido_log_debug("%s: u2f_get_touch_begin", __func__); return (r); |