Embedded SDK
Embedded SDK
Loading...
Searching...
No Matches
cx_mldsa_params.c
Go to the documentation of this file.
1/*****************************************************************************
2 * (c) 2026 Ledger SAS.
3 *
4 * Licensed under the Apache License, Version 2.0 (the "License");
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
7 *
8 * http://www.apache.org/licenses/LICENSE-2.0
9 *
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an "AS IS" BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
15 *****************************************************************************/
16
22#include "lcx_mldsa.h"
23
25 /* ML-DSA-44 */
26 {.k = MLDSA44_K,
27 .l = MLDSA44_L,
28 .eta = MLDSA44_ETA,
29 .tau = MLDSA44_TAU,
30 .beta = MLDSA44_BETA,
31 .gamma1 = MLDSA44_GAMMA1,
32 .gamma2 = MLDSA44_GAMMA2,
33 .omega = MLDSA44_OMEGA,
34 .ctilde_bytes = MLDSA44_CTILDEBYTES,
35 .polyeta_packed_bytes = MLDSA44_POLYETA_PACKEDBYTES,
36 .polyz_packed_bytes = MLDSA44_POLYZ_PACKEDBYTES,
37 .polyw1_packed_bytes = MLDSA44_POLYW1_PACKEDBYTES,
38 .polyvech_packed_bytes = MLDSA44_POLYVECH_PACKEDBYTES,
39 .pk_bytes = MLDSA44_PUBLICKEYBYTES,
40 .sk_bytes = MLDSA44_SECRETKEYBYTES,
41 .sig_bytes = MLDSA44_SIGBYTES},
42 /* ML-DSA-65 */
43 {.k = MLDSA65_K,
44 .l = MLDSA65_L,
45 .eta = MLDSA65_ETA,
46 .tau = MLDSA65_TAU,
47 .beta = MLDSA65_BETA,
48 .gamma1 = MLDSA65_GAMMA1,
49 .gamma2 = MLDSA65_GAMMA2,
50 .omega = MLDSA65_OMEGA,
51 .ctilde_bytes = MLDSA65_CTILDEBYTES,
52 .polyeta_packed_bytes = MLDSA65_POLYETA_PACKEDBYTES,
53 .polyz_packed_bytes = MLDSA65_POLYZ_PACKEDBYTES,
54 .polyw1_packed_bytes = MLDSA65_POLYW1_PACKEDBYTES,
55 .polyvech_packed_bytes = MLDSA65_POLYVECH_PACKEDBYTES,
56 .pk_bytes = MLDSA65_PUBLICKEYBYTES,
57 .sk_bytes = MLDSA65_SECRETKEYBYTES,
58 .sig_bytes = MLDSA65_SIGBYTES},
59#ifdef HAVE_MLDSA_87
60 /* ML-DSA-87 */
61 {.k = MLDSA87_K,
62 .l = MLDSA87_L,
63 .eta = MLDSA87_ETA,
64 .tau = MLDSA87_TAU,
65 .beta = MLDSA87_BETA,
66 .gamma1 = MLDSA87_GAMMA1,
67 .gamma2 = MLDSA87_GAMMA2,
68 .omega = MLDSA87_OMEGA,
69 .ctilde_bytes = MLDSA87_CTILDEBYTES,
70 .polyeta_packed_bytes = MLDSA87_POLYETA_PACKEDBYTES,
71 .polyz_packed_bytes = MLDSA87_POLYZ_PACKEDBYTES,
72 .polyw1_packed_bytes = MLDSA87_POLYW1_PACKEDBYTES,
73 .polyvech_packed_bytes = MLDSA87_POLYVECH_PACKEDBYTES,
74 .pk_bytes = MLDSA87_PUBLICKEYBYTES,
75 .sk_bytes = MLDSA87_SECRETKEYBYTES,
76 .sig_bytes = MLDSA87_SIGBYTES},
77#endif
78};
const MLDSA_param_info_t MLDSA_PARAM[MLDSA_NUM_PARAM_SETS]
Lookup table of ML-DSA parameter sets indexed by MLDSA_param_t.
#define MLDSA44_TAU
Definition lcx_mldsa.h:57
#define MLDSA44_POLYW1_PACKEDBYTES
Definition lcx_mldsa.h:66
#define MLDSA44_OMEGA
Definition lcx_mldsa.h:61
#define MLDSA44_CTILDEBYTES
Definition lcx_mldsa.h:63
#define MLDSA44_GAMMA2
Definition lcx_mldsa.h:60
#define MLDSA44_L
Definition lcx_mldsa.h:55
#define MLDSA44_SECRETKEYBYTES
Definition lcx_mldsa.h:73
#define MLDSA44_POLYVECH_PACKEDBYTES
Definition lcx_mldsa.h:68
#define MLDSA44_POLYETA_PACKEDBYTES
Definition lcx_mldsa.h:64
#define MLDSA44_GAMMA1
Definition lcx_mldsa.h:59
#define MLDSA44_K
Definition lcx_mldsa.h:54
#define MLDSA44_BETA
Definition lcx_mldsa.h:58
#define MLDSA44_SIGBYTES
Definition lcx_mldsa.h:78
#define MLDSA44_ETA
Definition lcx_mldsa.h:56
#define MLDSA44_POLYZ_PACKEDBYTES
Definition lcx_mldsa.h:65
#define MLDSA44_PUBLICKEYBYTES
Definition lcx_mldsa.h:70
#define MLDSA65_CTILDEBYTES
Definition lcx_mldsa.h:97
#define MLDSA65_L
Definition lcx_mldsa.h:89
#define MLDSA65_BETA
Definition lcx_mldsa.h:92
#define MLDSA65_POLYVECH_PACKEDBYTES
Definition lcx_mldsa.h:102
#define MLDSA65_POLYZ_PACKEDBYTES
Definition lcx_mldsa.h:99
#define MLDSA65_GAMMA2
Definition lcx_mldsa.h:94
#define MLDSA65_OMEGA
Definition lcx_mldsa.h:95
#define MLDSA65_TAU
Definition lcx_mldsa.h:91
#define MLDSA65_GAMMA1
Definition lcx_mldsa.h:93
#define MLDSA65_POLYETA_PACKEDBYTES
Definition lcx_mldsa.h:98
#define MLDSA65_K
Definition lcx_mldsa.h:88
#define MLDSA65_ETA
Definition lcx_mldsa.h:90
#define MLDSA65_POLYW1_PACKEDBYTES
Definition lcx_mldsa.h:100
#define MLDSA65_PUBLICKEYBYTES
Definition lcx_mldsa.h:104
#define MLDSA65_SECRETKEYBYTES
Definition lcx_mldsa.h:107
#define MLDSA65_SIGBYTES
Definition lcx_mldsa.h:112
ML-DSA (Module-Lattice Digital Signature Algorithm) public API.
#define MLDSA_NUM_PARAM_SETS
Definition lcx_mldsa.h:162
ML-DSA parameter set descriptor holding all derived sizes.
Definition lcx_mldsa.h:179