Anjay Lite
Loading...
Searching...
No Matches
storage.h
Go to the documentation of this file.
1/*
2 * Copyright 2023-2025 AVSystem <avsystem@avsystem.com>
3 * AVSystem Anjay Lite LwM2M SDK
4 * All rights reserved.
5 *
6 * Licensed under AVSystem Anjay Lite LwM2M Client SDK - Non-Commercial License.
7 * See the attached LICENSE file for details.
8 */
9
10#include <anj/init.h>
11
30#ifndef ANJ_CRYPTO_STORAGE_H
31# define ANJ_CRYPTO_STORAGE_H
32
33# include <anj/crypto.h>
34# include <anj/defs.h>
35
36# ifdef __cplusplus
37extern "C" {
38# endif
39
40# ifdef ANJ_WITH_EXTERNAL_CRYPTO_STORAGE
41
42# ifdef ANJ_WITH_PERSISTENCE
47# define ANJ_CRYPTO_STORAGE_PERSISTENCE_INFO_MAX_SIZE 64
48# endif // ANJ_WITH_PERSISTENCE
49
60int anj_crypto_storage_init(void **out_crypto_ctx);
61
81
109int anj_crypto_storage_store_data(void *crypto_ctx,
110 const anj_crypto_security_info_t *info,
111 const void *data,
112 size_t data_size,
113 bool last_chunk);
114
128 const anj_crypto_security_info_t *info);
129
148 void *crypto_ctx,
150 char *out_buffer,
151 size_t out_buffer_size,
152 size_t *out_record_size);
153
162void anj_crypto_storage_deinit(void *out_crypto_ctx);
163
164# ifdef ANJ_WITH_PERSISTENCE
187 void *crypto_ctx,
189 void *out_data,
190 size_t *out_data_size);
191
210 void *crypto_ctx,
211 const void *data,
212 size_t data_size,
214# endif // ANJ_WITH_PERSISTENCE
215
216# endif // ANJ_WITH_EXTERNAL_CRYPTO_STORAGE
217
218# ifdef __cplusplus
219}
220# endif
221
222#endif // ANJ_CRYPTO_STORAGE_H
Cryptographic data descriptors used by Security Object and networking.
Core type and constant definitions for Anjay Lite.
Global configuration validation header for Anjay Lite.
int anj_crypto_storage_delete_record(void *crypto_ctx, const anj_crypto_security_info_t *info)
int anj_crypto_storage_resolve_persistence_info(void *crypto_ctx, const void *data, size_t data_size, anj_crypto_security_info_external_t *out_info)
int anj_crypto_storage_store_data(void *crypto_ctx, const anj_crypto_security_info_t *info, const void *data, size_t data_size, bool last_chunk)
int anj_crypto_storage_init(void **out_crypto_ctx)
int anj_crypto_storage_resolve_security_info(void *crypto_ctx, anj_crypto_security_info_external_t *info, char *out_buffer, size_t out_buffer_size, size_t *out_record_size)
int anj_crypto_storage_get_persistence_info(void *crypto_ctx, const anj_crypto_security_info_external_t *info, void *out_data, size_t *out_data_size)
int anj_crypto_storage_create_new_record(void *crypto_ctx, anj_crypto_security_info_t *out_info)
void anj_crypto_storage_deinit(void *out_crypto_ctx)
Definition crypto.h:101