diff options
Diffstat (limited to 'src/fido.h')
-rw-r--r-- | src/fido.h | 23 |
1 files changed, 19 insertions, 4 deletions
@@ -32,6 +32,12 @@ | |||
32 | extern "C" { | 32 | extern "C" { |
33 | #endif /* __cplusplus */ | 33 | #endif /* __cplusplus */ |
34 | 34 | ||
35 | #ifdef _MSC_VER | ||
36 | #define FIDO_DEPRECATED(reason) __declspec(deprecated(reason)) | ||
37 | #else | ||
38 | #define FIDO_DEPRECATED(reason) __attribute__((__deprecated__(reason))) | ||
39 | #endif | ||
40 | |||
35 | fido_assert_t *fido_assert_new(void); | 41 | fido_assert_t *fido_assert_new(void); |
36 | fido_cred_t *fido_cred_new(void); | 42 | fido_cred_t *fido_cred_new(void); |
37 | fido_dev_t *fido_dev_new(void); | 43 | fido_dev_t *fido_dev_new(void); |
@@ -82,6 +88,7 @@ const unsigned char *fido_cbor_info_aaguid_ptr(const fido_cbor_info_t *); | |||
82 | const unsigned char *fido_cred_authdata_ptr(const fido_cred_t *); | 88 | const unsigned char *fido_cred_authdata_ptr(const fido_cred_t *); |
83 | const unsigned char *fido_cred_clientdata_hash_ptr(const fido_cred_t *); | 89 | const unsigned char *fido_cred_clientdata_hash_ptr(const fido_cred_t *); |
84 | const unsigned char *fido_cred_id_ptr(const fido_cred_t *); | 90 | const unsigned char *fido_cred_id_ptr(const fido_cred_t *); |
91 | const unsigned char *fido_cred_aaguid_ptr(const fido_cred_t *); | ||
85 | const unsigned char *fido_cred_user_id_ptr(const fido_cred_t *); | 92 | const unsigned char *fido_cred_user_id_ptr(const fido_cred_t *); |
86 | const unsigned char *fido_cred_pubkey_ptr(const fido_cred_t *); | 93 | const unsigned char *fido_cred_pubkey_ptr(const fido_cred_t *); |
87 | const unsigned char *fido_cred_sig_ptr(const fido_cred_t *); | 94 | const unsigned char *fido_cred_sig_ptr(const fido_cred_t *); |
@@ -97,8 +104,8 @@ int fido_assert_set_clientdata_hash(fido_assert_t *, const unsigned char *, | |||
97 | int fido_assert_set_count(fido_assert_t *, size_t); | 104 | int fido_assert_set_count(fido_assert_t *, size_t); |
98 | int fido_assert_set_extensions(fido_assert_t *, int); | 105 | int fido_assert_set_extensions(fido_assert_t *, int); |
99 | int fido_assert_set_hmac_salt(fido_assert_t *, const unsigned char *, size_t); | 106 | int fido_assert_set_hmac_salt(fido_assert_t *, const unsigned char *, size_t); |
100 | int fido_assert_set_options(fido_assert_t *, bool, bool) | 107 | FIDO_DEPRECATED("use fido_assert_set_up/fido_assert_set_uv") |
101 | __attribute__((__deprecated__("use fido_assert_set_up/fido_assert_set_uv"))); | 108 | int fido_assert_set_options(fido_assert_t *, bool, bool); |
102 | int fido_assert_set_rp(fido_assert_t *, const char *); | 109 | int fido_assert_set_rp(fido_assert_t *, const char *); |
103 | int fido_assert_set_up(fido_assert_t *, fido_opt_t); | 110 | int fido_assert_set_up(fido_assert_t *, fido_opt_t); |
104 | int fido_assert_set_uv(fido_assert_t *, fido_opt_t); | 111 | int fido_assert_set_uv(fido_assert_t *, fido_opt_t); |
@@ -111,8 +118,8 @@ int fido_cred_set_authdata_raw(fido_cred_t *, const unsigned char *, size_t); | |||
111 | int fido_cred_set_clientdata_hash(fido_cred_t *, const unsigned char *, size_t); | 118 | int fido_cred_set_clientdata_hash(fido_cred_t *, const unsigned char *, size_t); |
112 | int fido_cred_set_extensions(fido_cred_t *, int); | 119 | int fido_cred_set_extensions(fido_cred_t *, int); |
113 | int fido_cred_set_fmt(fido_cred_t *, const char *); | 120 | int fido_cred_set_fmt(fido_cred_t *, const char *); |
114 | int fido_cred_set_options(fido_cred_t *, bool, bool) | 121 | FIDO_DEPRECATED("use fido_cred_set_rk/fido_cred_set_uv") |
115 | __attribute__((__deprecated__("use fido_cred_set_rk/fido_cred_set_uv"))); | 122 | int fido_cred_set_options(fido_cred_t *, bool, bool); |
116 | int fido_cred_set_prot(fido_cred_t *, int); | 123 | int fido_cred_set_prot(fido_cred_t *, int); |
117 | int fido_cred_set_rk(fido_cred_t *, fido_opt_t); | 124 | int fido_cred_set_rk(fido_cred_t *, fido_opt_t); |
118 | int fido_cred_set_rp(fido_cred_t *, const char *, const char *); | 125 | int fido_cred_set_rp(fido_cred_t *, const char *, const char *); |
@@ -130,6 +137,8 @@ int fido_dev_close(fido_dev_t *); | |||
130 | int fido_dev_get_assert(fido_dev_t *, fido_assert_t *, const char *); | 137 | int fido_dev_get_assert(fido_dev_t *, fido_assert_t *, const char *); |
131 | int fido_dev_get_cbor_info(fido_dev_t *, fido_cbor_info_t *); | 138 | int fido_dev_get_cbor_info(fido_dev_t *, fido_cbor_info_t *); |
132 | int fido_dev_get_retry_count(fido_dev_t *, int *); | 139 | int fido_dev_get_retry_count(fido_dev_t *, int *); |
140 | int fido_dev_get_touch_begin(fido_dev_t *); | ||
141 | int fido_dev_get_touch_status(fido_dev_t *, int *, int); | ||
133 | int fido_dev_info_manifest(fido_dev_info_t *, size_t, size_t *); | 142 | int fido_dev_info_manifest(fido_dev_info_t *, size_t, size_t *); |
134 | int fido_dev_make_cred(fido_dev_t *, fido_cred_t *, const char *); | 143 | int fido_dev_make_cred(fido_dev_t *, fido_cred_t *, const char *); |
135 | int fido_dev_open_with_info(fido_dev_t *); | 144 | int fido_dev_open_with_info(fido_dev_t *); |
@@ -154,6 +163,7 @@ size_t fido_cbor_info_versions_len(const fido_cbor_info_t *); | |||
154 | size_t fido_cred_authdata_len(const fido_cred_t *); | 163 | size_t fido_cred_authdata_len(const fido_cred_t *); |
155 | size_t fido_cred_clientdata_hash_len(const fido_cred_t *); | 164 | size_t fido_cred_clientdata_hash_len(const fido_cred_t *); |
156 | size_t fido_cred_id_len(const fido_cred_t *); | 165 | size_t fido_cred_id_len(const fido_cred_t *); |
166 | size_t fido_cred_aaguid_len(const fido_cred_t *); | ||
157 | size_t fido_cred_user_id_len(const fido_cred_t *); | 167 | size_t fido_cred_user_id_len(const fido_cred_t *); |
158 | size_t fido_cred_pubkey_len(const fido_cred_t *); | 168 | size_t fido_cred_pubkey_len(const fido_cred_t *); |
159 | size_t fido_cred_sig_len(const fido_cred_t *); | 169 | size_t fido_cred_sig_len(const fido_cred_t *); |
@@ -170,9 +180,14 @@ uint8_t fido_dev_flags(const fido_dev_t *); | |||
170 | int16_t fido_dev_info_vendor(const fido_dev_info_t *); | 180 | int16_t fido_dev_info_vendor(const fido_dev_info_t *); |
171 | int16_t fido_dev_info_product(const fido_dev_info_t *); | 181 | int16_t fido_dev_info_product(const fido_dev_info_t *); |
172 | uint64_t fido_cbor_info_maxmsgsiz(const fido_cbor_info_t *); | 182 | uint64_t fido_cbor_info_maxmsgsiz(const fido_cbor_info_t *); |
183 | uint64_t fido_cbor_info_maxcredcntlst(const fido_cbor_info_t *); | ||
184 | uint64_t fido_cbor_info_maxcredidlen(const fido_cbor_info_t *); | ||
173 | uint64_t fido_cbor_info_fwversion(const fido_cbor_info_t *); | 185 | uint64_t fido_cbor_info_fwversion(const fido_cbor_info_t *); |
174 | 186 | ||
187 | bool fido_dev_has_pin(const fido_dev_t *); | ||
175 | bool fido_dev_is_fido2(const fido_dev_t *); | 188 | bool fido_dev_is_fido2(const fido_dev_t *); |
189 | bool fido_dev_supports_pin(const fido_dev_t *); | ||
190 | bool fido_dev_supports_cred_prot(const fido_dev_t *); | ||
176 | 191 | ||
177 | #ifdef __cplusplus | 192 | #ifdef __cplusplus |
178 | } /* extern "C" */ | 193 | } /* extern "C" */ |