1.\" Copyright (c) 2019 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.
4.\"
5.Dd $Mdocdate: September 13 2019 $
6.Dt FIDO_BIO_DEV_GET_INFO 3
7.Os
8.Sh NAME
9.Nm fido_bio_dev_get_info ,
10.Nm fido_bio_dev_enroll_begin ,
11.Nm fido_bio_dev_enroll_continue ,
12.Nm fido_bio_dev_enroll_cancel ,
13.Nm fido_bio_dev_enroll_remove ,
14.Nm fido_bio_dev_get_template_array ,
15.Nm fido_bio_dev_set_template_name
16.Nd FIDO 2 biometric authenticator API
17.Sh SYNOPSIS
18.In fido.h
19.In fido/bio.h
20.Ft int
21.Fn fido_bio_dev_get_info "fido_dev_t *dev" "fido_bio_info_t *info"
22.Ft int
23.Fn fido_bio_dev_enroll_begin "fido_dev_t *dev" "fido_bio_template_t *template" "fido_bio_enroll_t *enroll" "uint32_t timeout_ms" "const char *pin"
24.Ft int
25.Fn fido_bio_dev_enroll_continue "fido_dev_t *dev" "const fido_bio_template_t *template" "fido_bio_enroll_t *enroll" "uint32_t timeout_ms"
26.Ft int
27.Fn fido_bio_dev_enroll_cancel "fido_dev_t *dev"
28.Ft int
29.Fn fido_bio_dev_enroll_remove "fido_dev_t *dev" "const fido_bio_template_t *template" "const char *pin"
30.Ft int
31.Fn fido_bio_dev_get_template_array "fido_dev_t *dev" "fido_bio_template_array_t *template_array" "const char *pin"
32.Ft int
33.Fn fido_bio_dev_set_template_name "fido_dev_t *dev" "const fido_bio_template_t *template" "const char *pin"
34.Sh DESCRIPTION
35The functions described in this page allow biometric
36templates on a FIDO2 authenticator to be listed, created,
37removed, and customised.
38Please note that not all FIDO2 authenticators support biometric
39enrollment.
40For a description of the types involved, please refer to
41.Xr fido_bio_info_new 3 ,
42.Xr fido_bio_enroll_new 3 ,
43and
44.Xr fido_bio_template 3 .
45.Pp
46The
47.Fn fido_bio_dev_get_info
48function populates
49.Fa info
50with sensor information from
51.Fa dev .
52.Pp
53The
54.Fn fido_bio_dev_enroll_begin
55function initiates a biometric enrollment on
56.Fa dev ,
57instructing the authenticator to wait
58.Fa timeout_ms
59milliseconds.
60On success,
61.Fa template
62and
63.Fa enroll
64will be populated with the newly created template's
65information and enrollment status, respectively.
66.Pp
67The
68.Fn fido_bio_dev_enroll_continue
69function continues an ongoing enrollment on
70.Fa dev ,
71instructing the authenticator to wait
72.Fa timeout_ms
73milliseconds.
74On success,
75.Fa enroll
76will be updated to reflect the status of the biometric
77enrollment.
78.Pp
79The
80.Fn fido_bio_dev_enroll_cancel
81function cancels an ongoing enrollment on
82.Fa dev .
83.Pp
84The
85.Fn fido_bio_dev_enroll_remove
86function removes
87.Fa template
88from
89.Fa dev .
90.Pp
91The
92.Fn fido_bio_dev_get_template_array
93function populates
94.Fa template_array
95with the templates currently enrolled on
96.Fa dev .
97.Pp
98The
99.Fn fido_bio_dev_set_template_name
100function sets the friendly name of
101.Fa template
102on
103.Fa dev .
104.Sh RETURN VALUES
105The error codes returned by
106.Fn fido_bio_dev_get_info ,
107.Fn fido_bio_dev_enroll_begin ,
108.Fn fido_bio_dev_enroll_continue ,
109.Fn fido_bio_dev_enroll_cancel ,
110.Fn fido_bio_dev_enroll_remove ,
111.Fn fido_bio_dev_get_template_array ,
112and
113.Fn fido_bio_dev_set_template_name
114are defined in
115.In fido/err.h .
116On success,
117.Dv FIDO_OK
118is returned.
119.Sh SEE ALSO
120.Xr fido_bio_enroll_new 3 ,
121.Xr fido_bio_info_new 3 ,
122.Xr fido_bio_template 3
123