![]() |
Aranya
a software development tool for governing access to data and services over a decentralized, zero-trust framework with secure end-to-end encrypted data exchange built-in.
|
The Aranya C API allows a C application to interface directly with the Aranya client using a library and header file.
Before attempting to use this API, verify that you are using a matching version of the C library, Aranya client header file, Rust example application, getting started documentation, and API documentation.
aranya_create_team()
- Create an Aranya teamaranya_add_team()
- Add an Aranya team to a devicearanya_add_device_to_team()
- Add a device to the Aranya teamaranya_add_sync_peer()
- Add peer to sync witharanya_aqc_assign_net_identifier()
- Assign an AQC network identifier to a devicearanya_create_label()
- Create a new AQC labelaranya_assign_label()
- Assign an AQC label to a devicearanya_aqc_create_bidi_channel()
- Create a bidirectional AQC channelaranya_aqc_receive_channel()
- Receive an AQC channelaranya_aqc_bidi_create_bidi_stream()
- Create a bidirectional AQC streamaranya_aqc_bidi_stream_send()
- Send data via bidirectional streamaranya_aqc_bidi_stream_try_recv()
- Try to receive data via a bidirectional streamObjects for creating an Aranya client and Aranya team:
AranyaClient
AranyaClientConfig
AranyaCreateTeamConfig
AranyaCreateTeamConfigBuilder
AranyaCreateTeamQuicSyncConfig
AranyaCreateTeamQuicSyncConfigBuilder
AranyaAddTeamConfig
AranyaAddTeamConfigBuilder
AranyaAddTeamQuicSyncConfig
AranyaAddTeamQuicSyncConfigBuilder
AranyaSyncPeerConfig
AranyaSyncPeerConfigBuilder
Objects for creating AQC (Aranya QUIC) channels and sending/receiving data:
Functions suffixed with _ext
accept an extra struct AranyaExtError *ext_err
parameter for extended error information.
ext_err
must be a valid, non-NULL pointer.ARANYA_ERROR_SUCCESS
, *ext_err
is populated with additional error details.ext_err
is unchanged.To extract a human-readable message: AranyaError aranya_ext_error_msg(
const struct AranyaExtError *err,
char *msg,
size_t *msg_len
);
Example: struct AranyaExtError ext_err; AranyaError rc = aranya_get_device_id_ext(client, &id, &ext_err); if (rc != ARANYA_ERROR_SUCCESS) { size_t len = 0; aranya_ext_error_msg(&ext_err, NULL, &len); char *buf = malloc(len); aranya_ext_error_msg(&ext_err, buf, &len); // `buf` now holds the detailed error message }