Select one of the symbols to view example projects that use it.
 
Outline
...
...
...
...
#include "nx_crypto_phash.h"
#include "nx_crypto_tls_prf_1.h"
#include "nx_crypto_tls_prf_sha256.h"
#include "nx_crypto_tls_prf_sha384.h"
#include "nx_crypto_tls_prf_sha512.h"
#include "nx_crypto_hkdf.h"
#include "nx_crypto_3des.h"
#include "nx_crypto.h"
#include "nx_crypto_md5.h"
#include "nx_crypto_sha1.h"
#include "nx_crypto_sha2.h"
#include "nx_crypto_sha5.h"
#include "nx_crypto.h"
#include "nx_crypto_hmac_sha1.h"
#include "nx_crypto_hmac_sha2.h"
#include "nx_crypto_hmac_sha5.h"
#include "nx_crypto_hmac_md5.h"
#include "nx_crypto_aes.h"
#include "nx_crypto_rsa.h"
#include "nx_crypto_null.h"
#include "nx_crypto_ecjpake.h"
#include "nx_crypto_ecdsa.h"
#include "nx_crypto_ecdh.h"
#include "nx_crypto_drbg.h"
#include "nx_crypto_pkcs1_v1.5.h"
...
crypto_method_none
crypto_method_null
crypto_method_aes_cbc_128
crypto_method_aes_cbc_192
crypto_method_aes_cbc_256
crypto_method_aes_ccm_8
crypto_method_aes_ccm_16
crypto_method_aes_128_gcm_16
crypto_method_aes_256_gcm_16
crypto_method_aes_xcbc_mac_96
crypto_method_drbg
crypto_method_ecdsa
crypto_method_ecdh
crypto_method_ecdhe
crypto_method_hmac_sha1
crypto_method_hmac_sha224
crypto_method_hmac_sha256
crypto_method_hmac_sha384
crypto_method_hmac_sha512
crypto_method_hmac_sha512_224
crypto_method_hmac_sha512_256
crypto_method_hmac_md5
crypto_method_rsa
crypto_method_auth_psk
crypto_method_auth_ecjpake
crypto_method_ec_secp192
crypto_method_ec_secp224
crypto_method_ec_secp256
crypto_method_ec_secp384
crypto_method_ec_secp521
crypto_method_public_null
crypto_method_md5
crypto_method_sha1
crypto_method_sha224
crypto_method_sha256
crypto_method_sha384
crypto_method_sha512
crypto_method_sha512_224
crypto_method_sha512_256
crypto_method_tls_prf_1
#define crypto_method_tls_prf_sha_256
crypto_method_tls_prf_sha256
crypto_method_tls_prf_sha384
crypto_method_tls_prf_sha512
crypto_method_hmac
crypto_method_hkdf
crypto_method_des
crypto_method_3des
crypto_method_pkcs1
Files
loading...
SourceVuSTM32 Libraries and Samplesnetxduocrypto_libraries/src/nx_crypto_methods.c
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
/**************************************************************************/ /* */ /* Copyright (c) Microsoft Corporation. All rights reserved. */ /* */ /* This software is licensed under the Microsoft Software License */ /* Terms for Microsoft Azure RTOS. Full text of the license can be */ /* found in the LICENSE file at https://aka.ms/AzureRTOS_EULA */ /* and in the root directory of this software. */ /* */... /**************************************************************************/ ... /**************************************************************************/ /**************************************************************************/ /** */ /** NetX Crypto Component */ /** */ /** Crypto Methods */ /** */... /**************************************************************************/ /**************************************************************************/ #include "nx_crypto_phash.h" #include "nx_crypto_tls_prf_1.h" #include "nx_crypto_tls_prf_sha256.h" #include "nx_crypto_tls_prf_sha384.h" #include "nx_crypto_tls_prf_sha512.h" #include "nx_crypto_hkdf.h" #include "nx_crypto_3des.h" #include "nx_crypto.h" #include "nx_crypto_md5.h" #include "nx_crypto_sha1.h" #include "nx_crypto_sha2.h" #include "nx_crypto_sha5.h" #include "nx_crypto.h" #include "nx_crypto_hmac_sha1.h" #include "nx_crypto_hmac_sha2.h" #include "nx_crypto_hmac_sha5.h" #include "nx_crypto_hmac_md5.h" #include "nx_crypto_aes.h" #include "nx_crypto_rsa.h" #include "nx_crypto_null.h" #include "nx_crypto_ecjpake.h" #include "nx_crypto_ecdsa.h" #include "nx_crypto_ecdh.h" #include "nx_crypto_drbg.h" #include "nx_crypto_pkcs1_v1.5.h" 25 includes .../**************************************************************************/ /* */ /* FUNCTION RELEASE */ /* */ /* nx_crypto_methods PORTABLE C */ /* 6.1 */ /* AUTHOR */ /* */ /* Timothy Stapko, Microsoft Corporation */ /* */ /* DESCRIPTION */ /* */ /* This table of function pointers provides a mapping from TLS */ /* ciphersuites to the necessary cryptographic methods for a given */ /* platform. It can be used as a model to develop a hardware-specific */ /* cryptography table for TLS. */ /* */ /* INPUT */ /* */ /* None */ /* */ /* OUTPUT */ /* */ /* None */ /* */ /* CALLS */ /* */ /* None */ /* */ /* CALLED BY */ /* */ /* Application Code */ /* */ /* RELEASE HISTORY */ /* */ /* DATE NAME DESCRIPTION */ /* */ /* 05-19-2020 Timothy Stapko Initial Version 6.0 */ /* 09-30-2020 Timothy Stapko Modified comment(s), */ /* resulting in version 6.1 */ /* */... /**************************************************************************/ /* Define cryptographic methods. */ /* Declare the NONE method: encrypt / hash method not config */ NX_CRYPTO_METHOD crypto_method_none = { NX_CRYPTO_NONE, /* Name of the crypto algorithm */ 0, /* Key size in bits, not used */ 0, /* IV size in bits, not used */ 0, /* ICV size in bits, not used */ 0, /* Block size in bytes */ 0, /* Metadata size in bytes */ NX_CRYPTO_NULL, /* Initialization routine, not used */ NX_CRYPTO_NULL, /* Cleanup routine, not used */ NX_CRYPTO_NULL /* NULL operation */ ...}; /* Declare the NULL encrypt */ NX_CRYPTO_METHOD crypto_method_null = { NX_CRYPTO_ENCRYPTION_NULL, /* Name of the crypto algorithm */ 0, /* Key size in bits, not used */ 0, /* IV size in bits, not used */ 0, /* ICV size in bits, not used */ 4, /* Block size in bytes */ 0, /* Metadata size in bytes */ NX_CRYPTO_NULL, /* Initialization routine, not used */ NX_CRYPTO_NULL, /* Cleanup routine, not used */ NX_CRYPTO_NULL /* NULL operation */ ...}; /* Declare the AES-CBC 128 encrytion method. */ NX_CRYPTO_METHOD crypto_method_aes_cbc_128 = { NX_CRYPTO_ENCRYPTION_AES_CBC, /* AES crypto algorithm */ NX_CRYPTO_AES_128_KEY_LEN_IN_BITS, /* Key size in bits */ NX_CRYPTO_AES_IV_LEN_IN_BITS, /* IV size in bits */ 0, /* ICV size in bits, not used */ (NX_CRYPTO_AES_BLOCK_SIZE_IN_BITS >> 3), /* Block size in bytes */ sizeof(NX_CRYPTO_AES), /* Metadata size in bytes */ _nx_crypto_method_aes_init, /* AES-CBC initialization routine */ _nx_crypto_method_aes_cleanup, /* AES-CBC cleanup routine */ _nx_crypto_method_aes_cbc_operation /* AES-CBC operation */ ...}; /* Declare the AES-CBC 192 encrytion method. */ NX_CRYPTO_METHOD crypto_method_aes_cbc_192 = { NX_CRYPTO_ENCRYPTION_AES_CBC, /* AES crypto algorithm */ NX_CRYPTO_AES_192_KEY_LEN_IN_BITS, /* Key size in bits */ NX_CRYPTO_AES_IV_LEN_IN_BITS, /* IV size in bits */ 0, /* ICV size in bits, not used */ (NX_CRYPTO_AES_BLOCK_SIZE_IN_BITS >> 3), /* Block size in bytes */ sizeof(NX_CRYPTO_AES), /* Metadata size in bytes */ _nx_crypto_method_aes_init, /* AES-CBC initialization routine */ _nx_crypto_method_aes_cleanup, /* AES-CBC cleanup routine */ _nx_crypto_method_aes_operation /* AES-CBC operation */ ...}; /* Declare the AES-CBC 256 encryption method */ NX_CRYPTO_METHOD crypto_method_aes_cbc_256 = { NX_CRYPTO_ENCRYPTION_AES_CBC, /* AES crypto algorithm */ NX_CRYPTO_AES_256_KEY_LEN_IN_BITS, /* Key size in bits */ NX_CRYPTO_AES_IV_LEN_IN_BITS, /* IV size in bits */ 0, /* ICV size in bits, not used */ (NX_CRYPTO_AES_BLOCK_SIZE_IN_BITS >> 3), /* Block size in bytes */ sizeof(NX_CRYPTO_AES), /* Metadata size in bytes */ _nx_crypto_method_aes_init, /* AES-CBC initialization routine */ _nx_crypto_method_aes_cleanup, /* AES-CBC cleanup routine */ _nx_crypto_method_aes_cbc_operation /* AES-CBC operation */ ...}; /* Declare the AES-CCM-8 encrytion method. */ NX_CRYPTO_METHOD crypto_method_aes_ccm_8 = { NX_CRYPTO_ENCRYPTION_AES_CCM_8, /* AES crypto algorithm */ NX_CRYPTO_AES_128_KEY_LEN_IN_BITS, /* Key size in bits */ 32, /* IV size in bits */ 64, /* ICV size in bits */ (NX_CRYPTO_AES_BLOCK_SIZE_IN_BITS >> 3), /* Block size in bytes. */ sizeof(NX_CRYPTO_AES), /* Metadata size in bytes */ _nx_crypto_method_aes_init, /* AES-CCM8 initialization routine. */ _nx_crypto_method_aes_cleanup, /* AES-CCM8 cleanup routine. */ _nx_crypto_method_aes_ccm_operation /* AES-CCM8 operation */ ...}; /* Declare the AES-CCM-16 encrytion method. */ NX_CRYPTO_METHOD crypto_method_aes_ccm_16 = { NX_CRYPTO_ENCRYPTION_AES_CCM_16, /* AES crypto algorithm */ NX_CRYPTO_AES_128_KEY_LEN_IN_BITS, /* Key size in bits */ 32, /* IV size in bits */ 128, /* ICV size in bits */ (NX_CRYPTO_AES_BLOCK_SIZE_IN_BITS >> 3), /* Block size in bytes. */ sizeof(NX_CRYPTO_AES), /* Metadata size in bytes */ _nx_crypto_method_aes_init, /* AES-CCM16 initialization routine. */ _nx_crypto_method_aes_cleanup, /* AES-CCM16 cleanup routine. */ _nx_crypto_method_aes_ccm_operation /* AES-CCM16 operation */ ...}; /* Declare the AES-GCM encrytion method. */ NX_CRYPTO_METHOD crypto_method_aes_128_gcm_16 = { NX_CRYPTO_ENCRYPTION_AES_GCM_16, /* AES crypto algorithm */ NX_CRYPTO_AES_128_KEY_LEN_IN_BITS, /* Key size in bits */ 32, /* IV size in bits */ 128, /* ICV size in bits */ (NX_CRYPTO_AES_BLOCK_SIZE_IN_BITS >> 3), /* Block size in bytes. */ sizeof(NX_CRYPTO_AES), /* Metadata size in bytes */ _nx_crypto_method_aes_init, /* AES-GCM initialization routine. */ _nx_crypto_method_aes_cleanup, /* AES-GCM cleanup routine. */ _nx_crypto_method_aes_gcm_operation, /* AES-GCM operation */ ...}; /* Declare the AES-GCM encrytion method. */ NX_CRYPTO_METHOD crypto_method_aes_256_gcm_16 = { NX_CRYPTO_ENCRYPTION_AES_GCM_16, /* AES crypto algorithm */ NX_CRYPTO_AES_256_KEY_LEN_IN_BITS, /* Key size in bits */ 32, /* IV size in bits */ 128, /* ICV size in bits */ (NX_CRYPTO_AES_BLOCK_SIZE_IN_BITS >> 3), /* Block size in bytes. */ sizeof(NX_CRYPTO_AES), /* Metadata size in bytes */ _nx_crypto_method_aes_init, /* AES-GCM initialization routine. */ _nx_crypto_method_aes_cleanup, /* AES-GCM cleanup routine. */ _nx_crypto_method_aes_gcm_operation, /* AES-GCM operation */ ...}; /* Declare the AES-XCBC-MAC encrytion method. */ NX_CRYPTO_METHOD crypto_method_aes_xcbc_mac_96 = { NX_CRYPTO_AUTHENTICATION_AES_XCBC_MAC_96, /* AES_XCBC_MAC algorithm */ NX_CRYPTO_AES_XCBC_MAC_KEY_LEN_IN_BITS, /* Key size in bits */ 0, /* IV size in bits, not used */ NX_CRYPTO_AUTHENTICATION_ICV_TRUNC_BITS, /* Transmitted ICV size in bits */ (NX_CRYPTO_AES_BLOCK_SIZE_IN_BITS >> 3), /* Block size in bytes. */ sizeof(NX_CRYPTO_AES), /* Metadata size in bytes */ _nx_crypto_method_aes_init, /* AES-XCBC_MAC initialization routine. */ _nx_crypto_method_aes_cleanup, /* AES-XCBC_MAC cleanup routine. */ _nx_crypto_method_aes_xcbc_operation /* AES_XCBC_MAC operation */ ...}; /* Declare the DRBG encrytion method. */ NX_CRYPTO_METHOD crypto_method_drbg = { 0, /* DRBG crypto algorithm */ 0, /* Key size in bits */ 0, /* IV size in bits */ 0, /* ICV size in bits, not used */ 0, /* Block size in bytes */ sizeof(NX_CRYPTO_DRBG), /* Metadata size in bytes */ _nx_crypto_method_drbg_init, /* DRBG initialization routine */ _nx_crypto_method_drbg_cleanup, /* DRBG cleanup routine */ _nx_crypto_method_drbg_operation, /* DRBG operation */ ...}; /* Declare the ECDSA crypto method */ NX_CRYPTO_METHOD crypto_method_ecdsa = { NX_CRYPTO_DIGITAL_SIGNATURE_ECDSA, /* ECDSA crypto algorithm */ 0, /* Key size in bits */ 0, /* IV size in bits */ 0, /* ICV size in bits, not used */ 0, /* Block size in bytes */ sizeof(NX_CRYPTO_ECDSA), /* Metadata size in bytes */ _nx_crypto_method_ecdsa_init, /* ECDSA initialization routine */ _nx_crypto_method_ecdsa_cleanup, /* ECDSA cleanup routine */ _nx_crypto_method_ecdsa_operation /* ECDSA operation */ ...}; /* Declare the ECDH crypto method */ NX_CRYPTO_METHOD crypto_method_ecdh = { NX_CRYPTO_KEY_EXCHANGE_ECDH, /* ECDH crypto algorithm */ 0, /* Key size in bits */ 0, /* IV size in bits */ 0, /* ICV size in bits, not used */ 0, /* Block size in bytes */ sizeof(NX_CRYPTO_ECDH), /* Metadata size in bytes */ _nx_crypto_method_ecdh_init, /* ECDH initialization routine */ _nx_crypto_method_ecdh_cleanup, /* ECDH cleanup routine */ _nx_crypto_method_ecdh_operation /* ECDH operation */ ...}; /* Declare the ECDHE crypto method */ NX_CRYPTO_METHOD crypto_method_ecdhe = { NX_CRYPTO_KEY_EXCHANGE_ECDHE, /* ECDHE crypto algorithm */ 0, /* Key size in bits */ 0, /* IV size in bits */ 0, /* ICV size in bits, not used */ 0, /* Block size in bytes */ sizeof(NX_CRYPTO_ECDH), /* Metadata size in bytes */ _nx_crypto_method_ecdh_init, /* ECDH initialization routine */ _nx_crypto_method_ecdh_cleanup, /* ECDH cleanup routine */ _nx_crypto_method_ecdh_operation /* ECDH operation */ ...}; /* Declare the HMAC SHA1 authentication method */ NX_CRYPTO_METHOD crypto_method_hmac_sha1 = { NX_CRYPTO_AUTHENTICATION_HMAC_SHA1_160, /* HMAC SHA1 algorithm */ 0, /* Key size in bits */ 0, /* IV size in bits, not used */ NX_CRYPTO_HMAC_SHA1_ICV_FULL_LEN_IN_BITS, /* Transmitted ICV size in bits */ NX_CRYPTO_SHA1_BLOCK_SIZE_IN_BYTES, /* Block size in bytes */ sizeof(NX_CRYPTO_SHA1_HMAC), /* Metadata size in bytes */ _nx_crypto_method_hmac_sha1_init, /* HMAC SHA1 initialization routine */ _nx_crypto_method_hmac_sha1_cleanup, /* HMAC SHA1 cleanup routine */ _nx_crypto_method_hmac_sha1_operation /* HMAC SHA1 operation */ ...}; /* Declare the HMAC SHA224 authentication method */ NX_CRYPTO_METHOD crypto_method_hmac_sha224 = { NX_CRYPTO_AUTHENTICATION_HMAC_SHA2_224, /* HMAC SHA224 algorithm */ 0, /* Key size in bits */ 0, /* IV size in bits, not used */ NX_CRYPTO_HMAC_SHA224_ICV_FULL_LEN_IN_BITS, /* Transmitted ICV size in bits */ NX_CRYPTO_SHA2_BLOCK_SIZE_IN_BYTES, /* Block size in bytes */ sizeof(NX_CRYPTO_SHA256_HMAC), /* Metadata size in bytes */ _nx_crypto_method_hmac_sha256_init, /* HMAC SHA224 initialization routine */ _nx_crypto_method_hmac_sha256_cleanup, /* HMAC SHA224 cleanup routine */ _nx_crypto_method_hmac_sha256_operation /* HMAC SHA224 operation */ ...}; /* Declare the HMAC SHA256 authentication method */ NX_CRYPTO_METHOD crypto_method_hmac_sha256 = { NX_CRYPTO_AUTHENTICATION_HMAC_SHA2_256, /* HMAC SHA256 algorithm */ 0, /* Key size in bits */ 0, /* IV size in bits, not used */ NX_CRYPTO_HMAC_SHA256_ICV_FULL_LEN_IN_BITS, /* Transmitted ICV size in bits */ NX_CRYPTO_SHA2_BLOCK_SIZE_IN_BYTES, /* Block size in bytes */ sizeof(NX_CRYPTO_SHA256_HMAC), /* Metadata size in bytes */ _nx_crypto_method_hmac_sha256_init, /* HMAC SHA256 initialization routine */ _nx_crypto_method_hmac_sha256_cleanup, /* HMAC SHA256 cleanup routine */ _nx_crypto_method_hmac_sha256_operation /* HMAC SHA256 operation */ ...}; /* Declare the HMAC SHA384 authentication method */ NX_CRYPTO_METHOD crypto_method_hmac_sha384 = { NX_CRYPTO_AUTHENTICATION_HMAC_SHA2_384, /* HMAC SHA384 algorithm */ 0, /* Key size in bits */ 0, /* IV size in bits, not used */ NX_CRYPTO_HMAC_SHA384_ICV_FULL_LEN_IN_BITS, /* Transmitted ICV size in bits */ NX_CRYPTO_SHA512_BLOCK_SIZE_IN_BYTES, /* Block size in bytes */ sizeof(NX_CRYPTO_SHA512_HMAC), /* Metadata size in bytes */ _nx_crypto_method_hmac_sha512_init, /* HMAC SHA384 initialization routine */ _nx_crypto_method_hmac_sha512_cleanup, /* HMAC SHA384 cleanup routine */ _nx_crypto_method_hmac_sha512_operation /* HMAC SHA384 operation */ ...}; /* Declare the HMAC SHA512 authentication method */ NX_CRYPTO_METHOD crypto_method_hmac_sha512 = { NX_CRYPTO_AUTHENTICATION_HMAC_SHA2_512, /* HMAC SHA512 algorithm */ 0, /* Key size in bits */ 0, /* IV size in bits, not used */ NX_CRYPTO_HMAC_SHA512_ICV_FULL_LEN_IN_BITS, /* Transmitted ICV size in bits */ NX_CRYPTO_SHA512_BLOCK_SIZE_IN_BYTES, /* Block size in bytes */ sizeof(NX_CRYPTO_SHA512_HMAC), /* Metadata size in bytes */ _nx_crypto_method_hmac_sha512_init, /* HMAC SHA512 initialization routine */ _nx_crypto_method_hmac_sha512_cleanup, /* HMAC SHA512 cleanup routine */ _nx_crypto_method_hmac_sha512_operation /* HMAC SHA512 operation */ ...}; /* Declare the HMAC SHA512 authentication method */ NX_CRYPTO_METHOD crypto_method_hmac_sha512_224 = { NX_CRYPTO_AUTHENTICATION_HMAC_SHA2_512_224, /* HMAC SHA512224 algorithm */ 0, /* Key size in bits */ 0, /* IV size in bits, not used */ NX_CRYPTO_HMAC_SHA512_224_ICV_FULL_LEN_IN_BITS,/* Transmitted ICV size in bits */ NX_CRYPTO_SHA512_BLOCK_SIZE_IN_BYTES, /* Block size in bytes */ sizeof(NX_CRYPTO_SHA512_HMAC), /* Metadata size in bytes */ _nx_crypto_method_hmac_sha512_init, /* HMAC SHA512224 initialization routine */ _nx_crypto_method_hmac_sha512_cleanup, /* HMAC SHA512224 cleanup routine */ _nx_crypto_method_hmac_sha512_operation /* HMAC SHA512224 operation */ ...}; /* Declare the HMAC SHA512 authentication method */ NX_CRYPTO_METHOD crypto_method_hmac_sha512_256 = { NX_CRYPTO_AUTHENTICATION_HMAC_SHA2_512_256, /* HMAC SHA512256 algorithm */ 0, /* Key size in bits */ 0, /* IV size in bits, not used */ NX_CRYPTO_HMAC_SHA512_256_ICV_FULL_LEN_IN_BITS,/* Transmitted ICV size in bits */ NX_CRYPTO_SHA512_BLOCK_SIZE_IN_BYTES, /* Block size in bytes */ sizeof(NX_CRYPTO_SHA512_HMAC), /* Metadata size in bytes */ _nx_crypto_method_hmac_sha512_init, /* HMAC SHA512256 initialization routine */ _nx_crypto_method_hmac_sha512_cleanup, /* HMAC SHA512256 cleanup routine */ _nx_crypto_method_hmac_sha512_operation /* HMAC SHA512256 operation */ ...}; /* Declare the HMAC MD5 authentication method */ NX_CRYPTO_METHOD crypto_method_hmac_md5 = { NX_CRYPTO_AUTHENTICATION_HMAC_MD5_128, /* HMAC MD5 algorithm */ 0, /* Key size in bits */ 0, /* IV size in bits, not used */ NX_CRYPTO_HMAC_MD5_ICV_FULL_LEN_IN_BITS, /* Transmitted ICV size in bits */ NX_CRYPTO_MD5_BLOCK_SIZE_IN_BYTES, /* Block size in bytes */ sizeof(NX_CRYPTO_MD5_HMAC), /* Metadata size in bytes */ _nx_crypto_method_hmac_md5_init, /* HMAC MD5 initialization routine */ _nx_crypto_method_hmac_md5_cleanup, /* HMAC MD5 cleanup routine */ _nx_crypto_method_hmac_md5_operation /* HMAC MD5 operation */ ...}; /* Declare the RSA public cipher method. */ NX_CRYPTO_METHOD crypto_method_rsa = { NX_CRYPTO_KEY_EXCHANGE_RSA, /* RSA crypto algorithm */ 0, /* Key size in bits */ 0, /* IV size in bits */ 0, /* ICV size in bits, not used. */ 0, /* Block size in bytes. */ sizeof(NX_CRYPTO_RSA), /* Metadata size in bytes */ _nx_crypto_method_rsa_init, /* RSA initialization routine. */ _nx_crypto_method_rsa_cleanup, /* RSA cleanup routine */ _nx_crypto_method_rsa_operation /* RSA operation */ ...}; /* Declare a placeholder for PSK authentication. */ NX_CRYPTO_METHOD crypto_method_auth_psk = { NX_CRYPTO_KEY_EXCHANGE_PSK, /* PSK placeholder */ 0, /* Key size in bits */ 0, /* IV size in bits */ 0, /* ICV size in bits, not used. */ 0, /* Block size in bytes. */ 0, /* Metadata size in bytes */ NX_CRYPTO_NULL, /* Initialization routine. */ NX_CRYPTO_NULL, /* Cleanup routine, not used. */ NX_CRYPTO_NULL /* Operation */ ...}; /* Declare a placeholder for ECJ-PAKE. */ NX_CRYPTO_METHOD crypto_method_auth_ecjpake = { NX_CRYPTO_KEY_EXCHANGE_ECJPAKE, /* ECJ-PAKE placeholder */ 0, /* Key size in bits */ 0, /* IV size in bits */ 0, /* ICV size in bits, not used. */ 0, /* Block size in bytes */ sizeof(NX_CRYPTO_ECJPAKE), /* Metadata size in bytes */ _nx_crypto_method_ecjpake_init, /* ECJPAKE initialization routine */ _nx_crypto_method_ecjpake_cleanup, /* ECJPAKE cleanup routine */ _nx_crypto_method_ecjpake_operation, /* ECJPAKE operation */ ...}; /* Declare a placeholder for EC SECP192R1. */ NX_CRYPTO_METHOD crypto_method_ec_secp192 = { NX_CRYPTO_EC_SECP192R1, /* EC placeholder */ 192, /* Key size in bits */ 0, /* IV size in bits */ 0, /* ICV size in bits, not used. */ 0, /* Block size in bytes. */ 0, /* Metadata size in bytes */ NX_CRYPTO_NULL, /* Initialization routine. */ NX_CRYPTO_NULL, /* Cleanup routine, not used. */ _nx_crypto_method_ec_secp192r1_operation, /* Operation */ ...}; /* Declare a placeholder for EC SECP224R1. */ NX_CRYPTO_METHOD crypto_method_ec_secp224 = { NX_CRYPTO_EC_SECP224R1, /* EC placeholder */ 224, /* Key size in bits */ 0, /* IV size in bits */ 0, /* ICV size in bits, not used. */ 0, /* Block size in bytes. */ 0, /* Metadata size in bytes */ NX_CRYPTO_NULL, /* Initialization routine. */ NX_CRYPTO_NULL, /* Cleanup routine, not used. */ _nx_crypto_method_ec_secp224r1_operation, /* Operation */ ...}; /* Declare a placeholder for EC SECP256R1. */ NX_CRYPTO_METHOD crypto_method_ec_secp256 = { NX_CRYPTO_EC_SECP256R1, /* EC placeholder */ 256, /* Key size in bits */ 0, /* IV size in bits */ 0, /* ICV size in bits, not used. */ 0, /* Block size in bytes. */ 0, /* Metadata size in bytes */ NX_CRYPTO_NULL, /* Initialization routine. */ NX_CRYPTO_NULL, /* Cleanup routine, not used. */ _nx_crypto_method_ec_secp256r1_operation, /* Operation */ ...}; /* Declare a placeholder for EC SECP384R1. */ NX_CRYPTO_METHOD crypto_method_ec_secp384 = { NX_CRYPTO_EC_SECP384R1, /* EC placeholder */ 384, /* Key size in bits */ 0, /* IV size in bits */ 0, /* ICV size in bits, not used. */ 0, /* Block size in bytes. */ 0, /* Metadata size in bytes */ NX_CRYPTO_NULL, /* Initialization routine. */ NX_CRYPTO_NULL, /* Cleanup routine, not used. */ _nx_crypto_method_ec_secp384r1_operation, /* Operation */ ...}; /* Declare a placeholder for EC SECP521R1. */ NX_CRYPTO_METHOD crypto_method_ec_secp521 = { NX_CRYPTO_EC_SECP521R1, /* EC placeholder */ 521, /* Key size in bits */ 0, /* IV size in bits */ 0, /* ICV size in bits, not used. */ 0, /* Block size in bytes. */ 0, /* Metadata size in bytes */ NX_CRYPTO_NULL, /* Initialization routine. */ NX_CRYPTO_NULL, /* Cleanup routine, not used. */ _nx_crypto_method_ec_secp521r1_operation, /* Operation */ ...}; /* Declare the public NULL cipher (not to be confused with the NULL methods above). This * is used as a placeholder in ciphersuites that do not use a cipher method for a * particular operation (e.g. some PSK ciphersuites don't use a public-key algorithm * like RSA). *//* ... */ NX_CRYPTO_METHOD crypto_method_public_null = { NX_CRYPTO_ENCRYPTION_NULL, /* Name of the crypto algorithm */ 0, /* Key size in bits, not used */ 0, /* IV size in bits, not used */ 0, /* ICV size in bits, not used */ 1, /* Block size in bytes */ 0, /* Metadata size in bytes */ _nx_crypto_method_null_init, /* NULL initialization routine */ _nx_crypto_method_null_cleanup, /* NULL cleanup routine */ _nx_crypto_method_null_operation /* NULL operation */ ...}; /* Declare the MD5 hash method */ NX_CRYPTO_METHOD crypto_method_md5 = { NX_CRYPTO_HASH_MD5, /* MD5 algorithm */ 0, /* Key size in bits */ 0, /* IV size in bits, not used */ NX_CRYPTO_MD5_ICV_LEN_IN_BITS, /* Transmitted ICV size in bits */ NX_CRYPTO_MD5_BLOCK_SIZE_IN_BYTES, /* Block size in bytes */ sizeof(NX_CRYPTO_MD5), /* Metadata size in bytes */ _nx_crypto_method_md5_init, /* MD5 initialization routine */ _nx_crypto_method_md5_cleanup, /* MD5 cleanup routine */ _nx_crypto_method_md5_operation /* MD5 operation */ ...}; /* Declare the SHA1 hash method */ NX_CRYPTO_METHOD crypto_method_sha1 = { NX_CRYPTO_HASH_SHA1, /* SHA1 algorithm */ 0, /* Key size in bits */ 0, /* IV size in bits, not used */ NX_CRYPTO_SHA1_ICV_LEN_IN_BITS, /* Transmitted ICV size in bits */ NX_CRYPTO_SHA1_BLOCK_SIZE_IN_BYTES, /* Block size in bytes */ sizeof(NX_CRYPTO_SHA1), /* Metadata size in bytes */ _nx_crypto_method_sha1_init, /* SHA1 initialization routine */ _nx_crypto_method_sha1_cleanup, /* SHA1 cleanup routine */ _nx_crypto_method_sha1_operation /* SHA1 operation */ ...}; /* Declare the SHA224 hash method */ NX_CRYPTO_METHOD crypto_method_sha224 = { NX_CRYPTO_HASH_SHA224, /* SHA224 algorithm */ 0, /* Key size in bits */ 0, /* IV size in bits, not used */ NX_CRYPTO_SHA224_ICV_LEN_IN_BITS, /* Transmitted ICV size in bits */ NX_CRYPTO_SHA2_BLOCK_SIZE_IN_BYTES, /* Block size in bytes */ sizeof(NX_CRYPTO_SHA256), /* Metadata size in bytes */ _nx_crypto_method_sha256_init, /* SHA224 initialization routine */ _nx_crypto_method_sha256_cleanup, /* SHA224 cleanup routine */ _nx_crypto_method_sha256_operation /* SHA224 operation */ ...}; /* Declare the SHA256 hash method */ NX_CRYPTO_METHOD crypto_method_sha256 = { NX_CRYPTO_HASH_SHA256, /* SHA256 algorithm */ 0, /* Key size in bits */ 0, /* IV size in bits, not used */ NX_CRYPTO_SHA256_ICV_LEN_IN_BITS, /* Transmitted ICV size in bits */ NX_CRYPTO_SHA2_BLOCK_SIZE_IN_BYTES, /* Block size in bytes */ sizeof(NX_CRYPTO_SHA256), /* Metadata size in bytes */ _nx_crypto_method_sha256_init, /* SHA256 initialization routine */ _nx_crypto_method_sha256_cleanup, /* SHA256 cleanup routine */ _nx_crypto_method_sha256_operation /* SHA256 operation */ ...}; /* Declare the SHA384 hash method */ NX_CRYPTO_METHOD crypto_method_sha384 = { NX_CRYPTO_HASH_SHA384, /* SHA384 algorithm */ 0, /* Key size in bits */ 0, /* IV size in bits, not used */ NX_CRYPTO_SHA384_ICV_LEN_IN_BITS, /* Transmitted ICV size in bits */ NX_CRYPTO_SHA512_BLOCK_SIZE_IN_BYTES, /* Block size in bytes */ sizeof(NX_CRYPTO_SHA512), /* Metadata size in bytes */ _nx_crypto_method_sha512_init, /* SHA384 initialization routine */ _nx_crypto_method_sha512_cleanup, /* SHA384 cleanup routine */ _nx_crypto_method_sha512_operation /* SHA384 operation */ ...}; /* Declare the SHA512 hash method */ NX_CRYPTO_METHOD crypto_method_sha512 = { NX_CRYPTO_HASH_SHA512, /* SHA512 algorithm */ 0, /* Key size in bits */ 0, /* IV size in bits, not used */ NX_CRYPTO_SHA512_ICV_LEN_IN_BITS, /* Transmitted ICV size in bits */ NX_CRYPTO_SHA512_BLOCK_SIZE_IN_BYTES, /* Block size in bytes */ sizeof(NX_CRYPTO_SHA512), /* Metadata size in bytes */ _nx_crypto_method_sha512_init, /* SHA512 initialization routine */ _nx_crypto_method_sha512_cleanup, /* SHA512 cleanup routine */ _nx_crypto_method_sha512_operation /* SHA512 operation */ ...}; /* Declare the SHA512/224 hash method */ NX_CRYPTO_METHOD crypto_method_sha512_224 = { NX_CRYPTO_HASH_SHA512_224, /* SHA512224 algorithm */ 0, /* Key size in bits */ 0, /* IV size in bits, not used */ NX_CRYPTO_SHA512_224_ICV_LEN_IN_BITS, /* Transmitted ICV size in bits */ NX_CRYPTO_SHA512_BLOCK_SIZE_IN_BYTES, /* Block size in bytes */ sizeof(NX_CRYPTO_SHA512), /* Metadata size in bytes */ _nx_crypto_method_sha512_init, /* SHA512224 initialization routine */ _nx_crypto_method_sha512_cleanup, /* SHA512224 cleanup routine */ _nx_crypto_method_sha512_operation /* SHA512224 operation */ ...}; /* Declare the SHA512/256 hash method */ NX_CRYPTO_METHOD crypto_method_sha512_256 = { NX_CRYPTO_HASH_SHA512_256, /* SHA512256 algorithm */ 0, /* Key size in bits */ 0, /* IV size in bits, not used */ NX_CRYPTO_SHA512_256_ICV_LEN_IN_BITS, /* Transmitted ICV size in bits */ NX_CRYPTO_SHA512_BLOCK_SIZE_IN_BYTES, /* Block size in bytes */ sizeof(NX_CRYPTO_SHA512), /* Metadata size in bytes */ _nx_crypto_method_sha512_init, /* SHA512256 initialization routine */ _nx_crypto_method_sha512_cleanup, /* SHA512256 cleanup routine */ _nx_crypto_method_sha512_operation /* SHA512256 operation */ ...}; /* Declare the TLSv1.0/1.1 PRF hash method */ NX_CRYPTO_METHOD crypto_method_tls_prf_1 = { NX_CRYPTO_PRF_HMAC_SHA1, /* TLS PRF algorithm */ 0, /* Key size in bits, not used */ 0, /* IV size in bits, not used */ 0, /* Transmitted ICV size in bits, not used*/ 0, /* Block size in bytes, not used */ sizeof(NX_CRYPTO_TLS_PRF_1), /* Metadata size in bytes */ _nx_crypto_method_prf_1_init, /* TLS PRF 1 initialization routine */ _nx_crypto_method_prf_1_cleanup, /* TLS PRF 1 cleanup routine */ _nx_crypto_method_prf_1_operation /* TLS PRF 1 operation */ ...}; /* For backward compatibility, this symbol is defined here */ #define crypto_method_tls_prf_sha_256 crypto_method_tls_prf_sha256 /* Declare the TLSv1.2 default PRF hash method */ NX_CRYPTO_METHOD crypto_method_tls_prf_sha256 = { NX_CRYPTO_PRF_HMAC_SHA2_256, /* TLS PRF algorithm */ 0, /* Key size in bits, not used */ 0, /* IV size in bits, not used */ 0, /* Transmitted ICV size in bits, not used*/ 0, /* Block size in bytes, not used */ sizeof(NX_CRYPTO_TLS_PRF_SHA256), /* Metadata size in bytes */ _nx_crypto_method_prf_sha_256_init, /* TLS PRF SHA256 initialization routine */ _nx_crypto_method_prf_sha_256_cleanup, /* TLS PRF SHA256 cleanup routine */ _nx_crypto_method_prf_sha_256_operation /* TLS PRF SHA256 operation */ ...}; /* Declare the TLSv1.2 default PRF hash method */ NX_CRYPTO_METHOD crypto_method_tls_prf_sha384 = { NX_CRYPTO_PRF_HMAC_SHA2_384, /* TLS PRF algorithm */ 0, /* Key size in bits, not used */ 0, /* IV size in bits, not used */ 0, /* Transmitted ICV size in bits, not used*/ 0, /* Block size in bytes, not used */ sizeof(NX_CRYPTO_TLS_PRF_SHA384), /* Metadata size in bytes */ _nx_crypto_method_prf_sha384_init, /* TLS PRF SHA384 initialization routine */ _nx_crypto_method_prf_sha384_cleanup, /* TLS PRF SHA384 cleanup routine */ _nx_crypto_method_prf_sha384_operation /* TLS PRF SHA384 operation */ ...}; /* Declare the TLSv1.2 default PRF hash method */ NX_CRYPTO_METHOD crypto_method_tls_prf_sha512 = { NX_CRYPTO_PRF_HMAC_SHA2_512, /* TLS PRF algorithm */ 0, /* Key size in bits, not used */ 0, /* IV size in bits, not used */ 0, /* Transmitted ICV size in bits, not used*/ 0, /* Block size in bytes, not used */ sizeof(NX_CRYPTO_TLS_PRF_SHA512), /* Metadata size in bytes */ _nx_crypto_method_prf_sha512_init, /* TLS PRF SHA512 initialization routine */ _nx_crypto_method_prf_sha512_cleanup, /* TLS PRF SHA512 cleanup routine */ _nx_crypto_method_prf_sha512_operation /* TLS PRF SHA512 operation */ ...}; /* Define generic HMAC cryptographic routine. */ NX_CRYPTO_METHOD crypto_method_hmac = { NX_CRYPTO_HASH_HMAC, /* HMAC algorithm */ 0, /* Key size in bits, not used */ 0, /* IV size in bits, not used */ 0, /* Transmitted ICV size in bits, not used*/ 0, /* Block size in bytes, not used */ sizeof(NX_CRYPTO_HMAC), /* Metadata size in bytes */ _nx_crypto_method_hmac_init, /* HKDF initialization routine */ _nx_crypto_method_hmac_cleanup, /* HKDF cleanup routine */ _nx_crypto_method_hmac_operation /* HKDF operation */ ...}; /* Define generic HMAC-based Key Derivation Function method. */ NX_CRYPTO_METHOD crypto_method_hkdf = { NX_CRYPTO_HKDF_METHOD, /* HKDF algorithm */ 0, /* Key size in bits, not used */ 0, /* IV size in bits, not used */ 0, /* Transmitted ICV size in bits, not used*/ 0, /* Block size in bytes, not used */ sizeof(NX_CRYPTO_HKDF) + sizeof(NX_CRYPTO_HMAC),/* Metadata size in bytes */ _nx_crypto_method_hkdf_init, /* HKDF initialization routine */ _nx_crypto_method_hkdf_cleanup, /* HKDF cleanup routine */ _nx_crypto_method_hkdf_operation /* HKDF operation */ ...}; /* Declare the 3DES-CBC 128 encrytion method. */ NX_CRYPTO_METHOD crypto_method_des = { NX_CRYPTO_ENCRYPTION_DES_CBC, /* DES crypto algorithm */ NX_CRYPTO_DES_KEY_LEN_IN_BITS, /* Key size in bits */ NX_CRYPTO_DES_IV_LEN_IN_BITS, /* IV size in bits */ 0, /* ICV size in bits, not used */ (NX_CRYPTO_DES_BLOCK_SIZE_IN_BITS >> 3), /* Block size in bytes */ sizeof(NX_CRYPTO_DES), /* Metadata size in bytes */ _nx_crypto_method_des_init, /* 3DES initialization routine */ _nx_crypto_method_des_cleanup, /* 3DES cleanup routine */ _nx_crypto_method_des_operation /* 3DES operation */ ...}; /* Declare the 3DES-CBC 128 encrytion method. */ NX_CRYPTO_METHOD crypto_method_3des = { NX_CRYPTO_ENCRYPTION_3DES_CBC, /* 3DES crypto algorithm */ NX_CRYPTO_3DES_KEY_LEN_IN_BITS, /* Key size in bits */ NX_CRYPTO_3DES_IV_LEN_IN_BITS, /* IV size in bits */ 0, /* ICV size in bits, not used */ (NX_CRYPTO_3DES_BLOCK_SIZE_IN_BITS >> 3), /* Block size in bytes */ sizeof(NX_CRYPTO_3DES), /* Metadata size in bytes */ _nx_crypto_method_3des_init, /* 3DES initialization routine */ _nx_crypto_method_3des_cleanup, /* 3DES cleanup routine */ _nx_crypto_method_3des_operation /* 3DES operation */ ...}; /* Declare the PKCS#1v1.5 encrytion method. */ NX_CRYPTO_METHOD crypto_method_pkcs1 = { NX_CRYPTO_DIGITAL_SIGNATURE_RSA, /* PKCS#1v1.5 crypto algorithm */ 0, /* Key size in bits, not used */ 0, /* IV size in bits, not used */ 0, /* ICV size in bits, not used */ 0, /* Block size in bytes, not used */ sizeof(NX_CRYPTO_PKCS1), /* Metadata size in bytes */ _nx_crypto_method_pkcs1_v1_5_init, /* PKCS#1v1.5 initialization routine */ _nx_crypto_method_pkcs1_v1_5_cleanup, /* PKCS#1v1.5 cleanup routine */ _nx_crypto_method_pkcs1_v1_5_operation /* PKCS#1v1.5 operation */ ...};
Details
Show:
from
Types: Columns:
This file uses the notable symbols shown below. Click anywhere in the file to view more details.