nRF Connect SDK API 2.8.99
Loading...
Searching...
No Matches
pkcs15_decode.h
Go to the documentation of this file.
1/*
2 * Copyright (c) 2024 Nordic Semiconductor ASA
3 *
4 * SPDX-License-Identifier: LicenseRef-Nordic-5-Clause
5 */
6
7/* A minimalistic PKCS #15 Elementary File (EF) decoder.
8 *
9 * Supported objects:
10 * EF(ODF) (Object Directory File) - Path element
11 * EF(DODF) (Data Object Directory File) - Path element
12 */
13
14#ifndef PKCS15_DECODE_H_
15#define PKCS15_DECODE_H_
16
17#include <stdlib.h>
18#include <stdint.h>
19#include <stdbool.h>
20
21#ifdef __cplusplus
22extern "C" {
23#endif
24
26#define PATH_SIZE 16
27
29typedef struct {
30 uint8_t path[PATH_SIZE];
32
42bool pkcs15_ef_odf_path_decode(const uint8_t *bytes, size_t len, pkcs15_object_t *object);
43
53bool pkcs15_ef_dodf_path_decode(const uint8_t *bytes, size_t len, pkcs15_object_t *object);
54
55#ifdef __cplusplus
56}
57#endif
58
59#endif /* PKCS15_DECODE_H_ */
bool pkcs15_ef_odf_path_decode(const uint8_t *bytes, size_t len, pkcs15_object_t *object)
Decode PKCS #15 EF(ODF) Path.
bool pkcs15_ef_dodf_path_decode(const uint8_t *bytes, size_t len, pkcs15_object_t *object)
Decode PKCS #15 EF(DODF) Path.
#define PATH_SIZE
Definition pkcs15_decode.h:26
Definition pkcs15_decode.h:29