Commit 9919146
committed
authentication: fido2: hide internal symbols from the API docs
A number of symbols in the public FIDO2 headers are implementation
details of the subsystem core. They are not part of the application API,
and they are not part of the contract with out-of-tree transport,
storage, user presence or attestation backends either.
Wrap them in @cond INTERNAL_HIDDEN blocks so they no longer show up in
the generated API documentation:
- CTAP2 status and command codes (enum fido2_status, enum fido2_cmd).
The core casts the status to a raw response byte before handing the
buffer to a transport, and dispatches on the raw command byte, so
neither appears in any public signature.
- struct fido2_device_info, built by the core and consumed by the
internal CBOR encoder, together with the constants that only exist to
size or describe it: FIDO2_AAGUID_SIZE, FIDO2_MAX_VERSIONS,
FIDO2_MAX_EXTENSIONS and FIDO2_TRANSPORT_{USB,BLE,NFC}.
- The credential ID and authenticatorData layout constants
(FIDO2_DISCOVERABLE_CRED_ID_SIZE, FIDO2_NON_DISCOVERABLE_CRED_ID_SIZE,
FIDO2_AUTH_DATA_HEADER_SIZE, FIDO2_ATTESTED_CRED_DATA_MAX_SIZE,
FIDO2_AUTH_DATA_MAX_SIZE) and the authenticatorData flags
(AUTH_DATA_FLAG_*).
- The COSE/ECDH key encoding constants
(FIDO2_P256_UNCOMPRESSED_KEY_SIZE, FIDO2_P256_COORD_SIZE,
FIDO2_EC_POINT_UNCOMPRESSED).
What a backend implementer needs stays documented: struct
fido2_credential and the macros sizing its fields, FIDO2_SHA256_SIZE,
FIDO2_PIN_HASH_SIZE, FIDO2_ECDSA_SIG_MAX_SIZE (used by an attestation
backend to size its signature buffer, as the in-tree self attestation
one does), FIDO2_EXT_*, enum fido2_cred_protect and enum fido2_cose_alg.
While at it, drop a stray "8" from the FIDO2_AUTH_DATA_MAX_SIZE brief
and add the missing @brief to FIDO2_ATTESTATION_FMT_MAX_LEN.
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
Assisted-by: Claude:opus-51 parent 8dafb9a commit 9919146
2 files changed
Lines changed: 19 additions & 7 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
30 | 30 | | |
31 | 31 | | |
32 | 32 | | |
33 | | - | |
| 33 | + | |
34 | 34 | | |
35 | 35 | | |
36 | 36 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
46 | 46 | | |
47 | 47 | | |
48 | 48 | | |
49 | | - | |
50 | | - | |
51 | | - | |
52 | 49 | | |
53 | 50 | | |
54 | 51 | | |
55 | 52 | | |
56 | 53 | | |
57 | 54 | | |
| 55 | + | |
| 56 | + | |
| 57 | + | |
| 58 | + | |
| 59 | + | |
| 60 | + | |
| 61 | + | |
| 62 | + | |
58 | 63 | | |
59 | 64 | | |
60 | 65 | | |
| |||
68 | 73 | | |
69 | 74 | | |
70 | 75 | | |
71 | | - | |
| 76 | + | |
72 | 77 | | |
73 | 78 | | |
74 | 79 | | |
| |||
86 | 91 | | |
87 | 92 | | |
88 | 93 | | |
89 | | - | |
90 | | - | |
| 94 | + | |
91 | 95 | | |
92 | 96 | | |
93 | 97 | | |
| |||
98 | 102 | | |
99 | 103 | | |
100 | 104 | | |
| 105 | + | |
| 106 | + | |
101 | 107 | | |
102 | 108 | | |
103 | 109 | | |
| |||
178 | 184 | | |
179 | 185 | | |
180 | 186 | | |
| 187 | + | |
| 188 | + | |
181 | 189 | | |
182 | 190 | | |
183 | 191 | | |
| |||
230 | 238 | | |
231 | 239 | | |
232 | 240 | | |
| 241 | + | |
| 242 | + | |
233 | 243 | | |
234 | 244 | | |
235 | 245 | | |
| |||
277 | 287 | | |
278 | 288 | | |
279 | 289 | | |
| 290 | + | |
| 291 | + | |
280 | 292 | | |
281 | 293 | | |
282 | 294 | | |
| |||
0 commit comments