|
Zephyr API Documentation 4.4.99
A Scalable Open Source RTOS
|
Transport driver API callbacks. More...
#include <zephyr/authentication/fido2/fido2_transport.h>
Data Fields | |
| int(* | init )(fido2_transport_recv_cb_t cb, fido2_transport_cancel_cb_t cancel_cb) |
| Initialize the transport. | |
| int(* | send )(uint32_t cid, const uint8_t *data, size_t len) |
| Send response data to the host. | |
| void(* | notify )(uint32_t cid, enum fido2_wire_status status) |
| Notify the transport of an operation progress change. | |
| void(* | shutdown )(void) |
| Shut down the transport. | |
Transport driver API callbacks.
| int(* fido2_transport_api::init) (fido2_transport_recv_cb_t cb, fido2_transport_cancel_cb_t cancel_cb) |
Initialize the transport.
Called once during subsystem startup. The transport must store the callbacks and invoke them on every received CBOR message or cancel command.
| cb | Callback to invoke when a CBOR message is received. |
| cancel_cb | Callback to invoke when the cancel command is received |
| 0 | If successful. |
| -ENODEV | If hardware is not available. |
| void(* fido2_transport_api::notify) (uint32_t cid, enum fido2_wire_status status) |
Notify the transport of an operation progress change.
Called by the FIDO2 core to signal state transitions during long-running operations. Each transport translates this into the appropriate wire-protocol signaling.
| cid | Channel/connection identifier. |
| status | Progress status indicating what the core is doing. |
Send response data to the host.
| cid | Transport channel ID to send the response on. |
| data | Response payload bytes. |
| len | Length of data in bytes. |
| 0 | If successful. |
| -EIO | On transport error. |
| void(* fido2_transport_api::shutdown) (void) |
Shut down the transport.