Loading...
Searching...
No Matches
sizes.h
Go to the documentation of this file.
1/*
2 * Copyright (C) 2025 TU Dresden
3 * Copyright (C) 2021 HAW Hamburg
4 *
5 * This file is subject to the terms and conditions of the GNU Lesser
6 * General Public License v2.1. See the file LICENSE in the top level
7 * directory for more details.
8 */
9
10#pragma once
11
23
24#ifdef __cplusplus
25extern "C" {
26#endif
27
28#include "psa/sizes.h"
29#include "psa/key/type.h"
30
42#define PSA_SIGNATURE_MAX_SIZE /* implementation-defined value */
43
53#define PSA_ECDSA_SIGNATURE_SIZE(curve_bits) \
54 ((size_t)(PSA_BITS_TO_BYTES(curve_bits) * 2))
55
74#define PSA_SIGN_OUTPUT_SIZE(key_type, key_bits, alg) \
75 (PSA_KEY_TYPE_IS_ECC(key_type) ? PSA_ECDSA_SIGNATURE_SIZE(key_bits) : \
76 ((void)alg, 0))
77
78#ifdef __cplusplus
79}
80#endif
81
Key type definitions for the PSA Crypto API.
Size definitions for the PSA Crypto API.