1 .\" Copyright (c) 2018 Yubico AB. All rights reserved.
2 .\" Use of this source code is governed by a BSD-style
3 .\" license that can be found in the LICENSE file.
5 .Dd $Mdocdate: May 25 2018 $
10 .Nm fido_dev_get_retry_count ,
11 .Nm fido_dev_get_uv_retry_count ,
13 .Nd FIDO 2 device management functions
17 .Fn fido_dev_set_pin "fido_dev_t *dev" "const char *pin" "const char *oldpin"
19 .Fn fido_dev_get_retry_count "fido_dev_t *dev" "int *retries"
21 .Fn fido_dev_get_uv_retry_count "fido_dev_t *dev" "int *retries"
23 .Fn fido_dev_reset "fido_dev_t *dev"
27 function sets the PIN of device
33 is a NUL-terminated UTF-8 string.
36 is not NULL, the device's PIN is changed from
44 are NUL-terminated UTF-8 strings.
47 .Fn fido_dev_get_retry_count
50 with the number of PIN retries left in
52 before lock-out, where
54 is an addressable pointer.
57 .Fn fido_dev_get_uv_retry_count
60 with the number of built-in UV retries left in
62 before built-in UV is disabled, where
64 is an addressable pointer.
68 function performs a reset on
70 resetting the device's PIN and erasing credentials stored on the
74 .Fn fido_dev_set_pin ,
75 .Fn fido_dev_get_retry_count ,
76 .Fn fido_dev_get_uv_retry_count ,
79 are synchronous and will block if necessary.
81 The error codes returned by
82 .Fn fido_dev_set_pin ,
83 .Fn fido_dev_get_retry_count ,
84 .Fn fido_dev_get_uv_retry_count ,
95 the actual user-flow to perform a reset is outside the scope of the
96 FIDO2 specification, and may therefore vary depending on the
98 Yubico authenticators will return
99 .Dv FIDO_ERR_NOT_ALLOWED
100 if a reset is issued later than 5 seconds after power-up, and
101 .Dv FIDO_ERR_ACTION_TIMEOUT
102 if the user fails to confirm the reset by touching the key