annotate libtommath/tommath_private.h @ 1672:3a97f14c0235

Add Chacha20-Poly1305, AES128-GCM and AES256-GCM support (#93) * Add Chacha20-Poly1305 authenticated encryption * Add general AEAD approach. * Add [email protected] algo using LibTomCrypt chacha and poly1305 routines. Chacha20-Poly1305 is generally faster than AES256 on CPU w/o dedicated AES instructions, having the same key size. Compiling in will add ~5,5kB to binary size on x86-64. function old new delta chacha_crypt - 1397 +1397 _poly1305_block - 608 +608 poly1305_done - 595 +595 dropbear_chachapoly_crypt - 457 +457 .rodata 26976 27392 +416 poly1305_process - 290 +290 poly1305_init - 221 +221 chacha_setup - 218 +218 encrypt_packet 1068 1270 +202 dropbear_chachapoly_getlength - 147 +147 decrypt_packet 756 897 +141 chacha_ivctr64 - 137 +137 read_packet 543 637 +94 dropbear_chachapoly_start - 94 +94 read_kex_algos 792 880 +88 chacha_keystream - 69 +69 dropbear_mode_chachapoly - 48 +48 sshciphers 280 320 +40 dropbear_mode_none 24 48 +24 dropbear_mode_ctr 24 48 +24 dropbear_mode_cbc 24 48 +24 dropbear_chachapoly_mac - 24 +24 dropbear_chachapoly - 24 +24 gen_new_keys 848 854 +6 ------------------------------------------------------------------------------ (add/remove: 14/0 grow/shrink: 10/0 up/down: 5388/0) Total: 5388 bytes * Add AES128-GCM and AES256-GCM authenticated encryption * Add general AES-GCM mode. * Add [email protected] and [email protected] algo using LibTomCrypt gcm routines. AES-GCM is combination of AES CTR mode and GHASH, slower than AES-CTR on CPU w/o dedicated AES/GHASH instructions therefore disabled by default. Compiling in will add ~6kB to binary size on x86-64. function old new delta gcm_process - 1060 +1060 .rodata 26976 27808 +832 gcm_gf_mult - 820 +820 gcm_add_aad - 660 +660 gcm_shift_table - 512 +512 gcm_done - 471 +471 gcm_add_iv - 384 +384 gcm_init - 347 +347 dropbear_gcm_crypt - 309 +309 encrypt_packet 1068 1270 +202 decrypt_packet 756 897 +141 gcm_reset - 118 +118 read_packet 543 637 +94 read_kex_algos 792 880 +88 sshciphers 280 360 +80 gcm_mult_h - 80 +80 dropbear_gcm_start - 62 +62 dropbear_mode_gcm - 48 +48 dropbear_mode_none 24 48 +24 dropbear_mode_ctr 24 48 +24 dropbear_mode_cbc 24 48 +24 dropbear_ghash - 24 +24 dropbear_gcm_getlength - 24 +24 gen_new_keys 848 854 +6 ------------------------------------------------------------------------------ (add/remove: 14/0 grow/shrink: 10/0 up/down: 6434/0) Total: 6434 bytes
author Vladislav Grishenko <themiron@users.noreply.github.com>
date Mon, 25 May 2020 20:50:25 +0500
parents f52919ffd3b1
children 1051e4eea25a
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
1436
60fc6476e044 Update to libtommath v1.0
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
1 /* LibTomMath, multiple-precision integer library -- Tom St Denis
60fc6476e044 Update to libtommath v1.0
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
2 *
60fc6476e044 Update to libtommath v1.0
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
3 * LibTomMath is a library that provides multiple-precision
60fc6476e044 Update to libtommath v1.0
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
4 * integer arithmetic as well as number theoretic functionality.
60fc6476e044 Update to libtommath v1.0
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
5 *
60fc6476e044 Update to libtommath v1.0
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
6 * The library was designed directly after the MPI library by
60fc6476e044 Update to libtommath v1.0
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
7 * Michael Fromberger but has been written from scratch with
60fc6476e044 Update to libtommath v1.0
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
8 * additional optimizations in place.
60fc6476e044 Update to libtommath v1.0
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
9 *
1655
f52919ffd3b1 update ltm to 1.1.0 and enable FIPS 186.4 compliant key-generation (#79)
Steffen Jaeckel <s_jaeckel@gmx.de>
parents: 1470
diff changeset
10 * SPDX-License-Identifier: Unlicense
1436
60fc6476e044 Update to libtommath v1.0
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
11 */
60fc6476e044 Update to libtommath v1.0
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
12 #ifndef TOMMATH_PRIV_H_
60fc6476e044 Update to libtommath v1.0
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
13 #define TOMMATH_PRIV_H_
60fc6476e044 Update to libtommath v1.0
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
14
1655
f52919ffd3b1 update ltm to 1.1.0 and enable FIPS 186.4 compliant key-generation (#79)
Steffen Jaeckel <s_jaeckel@gmx.de>
parents: 1470
diff changeset
15 #include "tommath.h"
1436
60fc6476e044 Update to libtommath v1.0
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
16 #include <ctype.h>
60fc6476e044 Update to libtommath v1.0
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
17
1470
8bba51a55704 Update to libtommath v1.0.1
Matt Johnston <matt@ucc.asn.au>
parents: 1436
diff changeset
18 #ifndef MIN
1655
f52919ffd3b1 update ltm to 1.1.0 and enable FIPS 186.4 compliant key-generation (#79)
Steffen Jaeckel <s_jaeckel@gmx.de>
parents: 1470
diff changeset
19 #define MIN(x, y) (((x) < (y)) ? (x) : (y))
1470
8bba51a55704 Update to libtommath v1.0.1
Matt Johnston <matt@ucc.asn.au>
parents: 1436
diff changeset
20 #endif
1436
60fc6476e044 Update to libtommath v1.0
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
21
1470
8bba51a55704 Update to libtommath v1.0.1
Matt Johnston <matt@ucc.asn.au>
parents: 1436
diff changeset
22 #ifndef MAX
1655
f52919ffd3b1 update ltm to 1.1.0 and enable FIPS 186.4 compliant key-generation (#79)
Steffen Jaeckel <s_jaeckel@gmx.de>
parents: 1470
diff changeset
23 #define MAX(x, y) (((x) > (y)) ? (x) : (y))
1470
8bba51a55704 Update to libtommath v1.0.1
Matt Johnston <matt@ucc.asn.au>
parents: 1436
diff changeset
24 #endif
1436
60fc6476e044 Update to libtommath v1.0
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
25
60fc6476e044 Update to libtommath v1.0
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
26 #ifdef __cplusplus
60fc6476e044 Update to libtommath v1.0
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
27 extern "C" {
60fc6476e044 Update to libtommath v1.0
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
28
60fc6476e044 Update to libtommath v1.0
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
29 /* C++ compilers don't like assigning void * to mp_digit * */
1655
f52919ffd3b1 update ltm to 1.1.0 and enable FIPS 186.4 compliant key-generation (#79)
Steffen Jaeckel <s_jaeckel@gmx.de>
parents: 1470
diff changeset
30 #define OPT_CAST(x) (x *)
1436
60fc6476e044 Update to libtommath v1.0
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
31
60fc6476e044 Update to libtommath v1.0
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
32 #else
60fc6476e044 Update to libtommath v1.0
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
33
60fc6476e044 Update to libtommath v1.0
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
34 /* C on the other hand doesn't care */
1655
f52919ffd3b1 update ltm to 1.1.0 and enable FIPS 186.4 compliant key-generation (#79)
Steffen Jaeckel <s_jaeckel@gmx.de>
parents: 1470
diff changeset
35 #define OPT_CAST(x)
1436
60fc6476e044 Update to libtommath v1.0
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
36
60fc6476e044 Update to libtommath v1.0
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
37 #endif
60fc6476e044 Update to libtommath v1.0
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
38
60fc6476e044 Update to libtommath v1.0
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
39 /* define heap macros */
60fc6476e044 Update to libtommath v1.0
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
40 #ifndef XMALLOC
1655
f52919ffd3b1 update ltm to 1.1.0 and enable FIPS 186.4 compliant key-generation (#79)
Steffen Jaeckel <s_jaeckel@gmx.de>
parents: 1470
diff changeset
41 /* default to libc stuff */
f52919ffd3b1 update ltm to 1.1.0 and enable FIPS 186.4 compliant key-generation (#79)
Steffen Jaeckel <s_jaeckel@gmx.de>
parents: 1470
diff changeset
42 # define XMALLOC malloc
f52919ffd3b1 update ltm to 1.1.0 and enable FIPS 186.4 compliant key-generation (#79)
Steffen Jaeckel <s_jaeckel@gmx.de>
parents: 1470
diff changeset
43 # define XFREE free
f52919ffd3b1 update ltm to 1.1.0 and enable FIPS 186.4 compliant key-generation (#79)
Steffen Jaeckel <s_jaeckel@gmx.de>
parents: 1470
diff changeset
44 # define XREALLOC realloc
f52919ffd3b1 update ltm to 1.1.0 and enable FIPS 186.4 compliant key-generation (#79)
Steffen Jaeckel <s_jaeckel@gmx.de>
parents: 1470
diff changeset
45 # define XCALLOC calloc
1436
60fc6476e044 Update to libtommath v1.0
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
46 #else
1655
f52919ffd3b1 update ltm to 1.1.0 and enable FIPS 186.4 compliant key-generation (#79)
Steffen Jaeckel <s_jaeckel@gmx.de>
parents: 1470
diff changeset
47 /* prototypes for our heap functions */
f52919ffd3b1 update ltm to 1.1.0 and enable FIPS 186.4 compliant key-generation (#79)
Steffen Jaeckel <s_jaeckel@gmx.de>
parents: 1470
diff changeset
48 extern void *XMALLOC(size_t n);
f52919ffd3b1 update ltm to 1.1.0 and enable FIPS 186.4 compliant key-generation (#79)
Steffen Jaeckel <s_jaeckel@gmx.de>
parents: 1470
diff changeset
49 extern void *XREALLOC(void *p, size_t n);
f52919ffd3b1 update ltm to 1.1.0 and enable FIPS 186.4 compliant key-generation (#79)
Steffen Jaeckel <s_jaeckel@gmx.de>
parents: 1470
diff changeset
50 extern void *XCALLOC(size_t n, size_t s);
f52919ffd3b1 update ltm to 1.1.0 and enable FIPS 186.4 compliant key-generation (#79)
Steffen Jaeckel <s_jaeckel@gmx.de>
parents: 1470
diff changeset
51 extern void XFREE(void *p);
1436
60fc6476e044 Update to libtommath v1.0
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
52 #endif
60fc6476e044 Update to libtommath v1.0
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
53
60fc6476e044 Update to libtommath v1.0
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
54 /* lowlevel functions, do not call! */
1655
f52919ffd3b1 update ltm to 1.1.0 and enable FIPS 186.4 compliant key-generation (#79)
Steffen Jaeckel <s_jaeckel@gmx.de>
parents: 1470
diff changeset
55 int s_mp_add(const mp_int *a, const mp_int *b, mp_int *c);
f52919ffd3b1 update ltm to 1.1.0 and enable FIPS 186.4 compliant key-generation (#79)
Steffen Jaeckel <s_jaeckel@gmx.de>
parents: 1470
diff changeset
56 int s_mp_sub(const mp_int *a, const mp_int *b, mp_int *c);
1436
60fc6476e044 Update to libtommath v1.0
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
57 #define s_mp_mul(a, b, c) s_mp_mul_digs(a, b, c, (a)->used + (b)->used + 1)
1655
f52919ffd3b1 update ltm to 1.1.0 and enable FIPS 186.4 compliant key-generation (#79)
Steffen Jaeckel <s_jaeckel@gmx.de>
parents: 1470
diff changeset
58 int fast_s_mp_mul_digs(const mp_int *a, const mp_int *b, mp_int *c, int digs);
f52919ffd3b1 update ltm to 1.1.0 and enable FIPS 186.4 compliant key-generation (#79)
Steffen Jaeckel <s_jaeckel@gmx.de>
parents: 1470
diff changeset
59 int s_mp_mul_digs(const mp_int *a, const mp_int *b, mp_int *c, int digs);
f52919ffd3b1 update ltm to 1.1.0 and enable FIPS 186.4 compliant key-generation (#79)
Steffen Jaeckel <s_jaeckel@gmx.de>
parents: 1470
diff changeset
60 int fast_s_mp_mul_high_digs(const mp_int *a, const mp_int *b, mp_int *c, int digs);
f52919ffd3b1 update ltm to 1.1.0 and enable FIPS 186.4 compliant key-generation (#79)
Steffen Jaeckel <s_jaeckel@gmx.de>
parents: 1470
diff changeset
61 int s_mp_mul_high_digs(const mp_int *a, const mp_int *b, mp_int *c, int digs);
f52919ffd3b1 update ltm to 1.1.0 and enable FIPS 186.4 compliant key-generation (#79)
Steffen Jaeckel <s_jaeckel@gmx.de>
parents: 1470
diff changeset
62 int fast_s_mp_sqr(const mp_int *a, mp_int *b);
f52919ffd3b1 update ltm to 1.1.0 and enable FIPS 186.4 compliant key-generation (#79)
Steffen Jaeckel <s_jaeckel@gmx.de>
parents: 1470
diff changeset
63 int s_mp_sqr(const mp_int *a, mp_int *b);
f52919ffd3b1 update ltm to 1.1.0 and enable FIPS 186.4 compliant key-generation (#79)
Steffen Jaeckel <s_jaeckel@gmx.de>
parents: 1470
diff changeset
64 int mp_karatsuba_mul(const mp_int *a, const mp_int *b, mp_int *c);
f52919ffd3b1 update ltm to 1.1.0 and enable FIPS 186.4 compliant key-generation (#79)
Steffen Jaeckel <s_jaeckel@gmx.de>
parents: 1470
diff changeset
65 int mp_toom_mul(const mp_int *a, const mp_int *b, mp_int *c);
f52919ffd3b1 update ltm to 1.1.0 and enable FIPS 186.4 compliant key-generation (#79)
Steffen Jaeckel <s_jaeckel@gmx.de>
parents: 1470
diff changeset
66 int mp_karatsuba_sqr(const mp_int *a, mp_int *b);
f52919ffd3b1 update ltm to 1.1.0 and enable FIPS 186.4 compliant key-generation (#79)
Steffen Jaeckel <s_jaeckel@gmx.de>
parents: 1470
diff changeset
67 int mp_toom_sqr(const mp_int *a, mp_int *b);
f52919ffd3b1 update ltm to 1.1.0 and enable FIPS 186.4 compliant key-generation (#79)
Steffen Jaeckel <s_jaeckel@gmx.de>
parents: 1470
diff changeset
68 int fast_mp_invmod(const mp_int *a, const mp_int *b, mp_int *c);
f52919ffd3b1 update ltm to 1.1.0 and enable FIPS 186.4 compliant key-generation (#79)
Steffen Jaeckel <s_jaeckel@gmx.de>
parents: 1470
diff changeset
69 int mp_invmod_slow(const mp_int *a, const mp_int *b, mp_int *c);
f52919ffd3b1 update ltm to 1.1.0 and enable FIPS 186.4 compliant key-generation (#79)
Steffen Jaeckel <s_jaeckel@gmx.de>
parents: 1470
diff changeset
70 int fast_mp_montgomery_reduce(mp_int *x, const mp_int *n, mp_digit rho);
f52919ffd3b1 update ltm to 1.1.0 and enable FIPS 186.4 compliant key-generation (#79)
Steffen Jaeckel <s_jaeckel@gmx.de>
parents: 1470
diff changeset
71 int mp_exptmod_fast(const mp_int *G, const mp_int *X, const mp_int *P, mp_int *Y, int redmode);
f52919ffd3b1 update ltm to 1.1.0 and enable FIPS 186.4 compliant key-generation (#79)
Steffen Jaeckel <s_jaeckel@gmx.de>
parents: 1470
diff changeset
72 int s_mp_exptmod(const mp_int *G, const mp_int *X, const mp_int *P, mp_int *Y, int redmode);
1436
60fc6476e044 Update to libtommath v1.0
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
73 void bn_reverse(unsigned char *s, int len);
60fc6476e044 Update to libtommath v1.0
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
74
1655
f52919ffd3b1 update ltm to 1.1.0 and enable FIPS 186.4 compliant key-generation (#79)
Steffen Jaeckel <s_jaeckel@gmx.de>
parents: 1470
diff changeset
75 extern const char *const mp_s_rmap;
f52919ffd3b1 update ltm to 1.1.0 and enable FIPS 186.4 compliant key-generation (#79)
Steffen Jaeckel <s_jaeckel@gmx.de>
parents: 1470
diff changeset
76 extern const uint8_t mp_s_rmap_reverse[];
f52919ffd3b1 update ltm to 1.1.0 and enable FIPS 186.4 compliant key-generation (#79)
Steffen Jaeckel <s_jaeckel@gmx.de>
parents: 1470
diff changeset
77 extern const size_t mp_s_rmap_reverse_sz;
1436
60fc6476e044 Update to libtommath v1.0
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
78
60fc6476e044 Update to libtommath v1.0
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
79 /* Fancy macro to set an MPI from another type.
60fc6476e044 Update to libtommath v1.0
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
80 * There are several things assumed:
60fc6476e044 Update to libtommath v1.0
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
81 * x is the counter and unsigned
60fc6476e044 Update to libtommath v1.0
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
82 * a is the pointer to the MPI
60fc6476e044 Update to libtommath v1.0
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
83 * b is the original value that should be set in the MPI.
60fc6476e044 Update to libtommath v1.0
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
84 */
60fc6476e044 Update to libtommath v1.0
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
85 #define MP_SET_XLONG(func_name, type) \
60fc6476e044 Update to libtommath v1.0
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
86 int func_name (mp_int * a, type b) \
60fc6476e044 Update to libtommath v1.0
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
87 { \
60fc6476e044 Update to libtommath v1.0
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
88 unsigned int x; \
60fc6476e044 Update to libtommath v1.0
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
89 int res; \
60fc6476e044 Update to libtommath v1.0
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
90 \
60fc6476e044 Update to libtommath v1.0
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
91 mp_zero (a); \
60fc6476e044 Update to libtommath v1.0
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
92 \
60fc6476e044 Update to libtommath v1.0
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
93 /* set four bits at a time */ \
60fc6476e044 Update to libtommath v1.0
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
94 for (x = 0; x < (sizeof(type) * 2u); x++) { \
60fc6476e044 Update to libtommath v1.0
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
95 /* shift the number up four bits */ \
60fc6476e044 Update to libtommath v1.0
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
96 if ((res = mp_mul_2d (a, 4, a)) != MP_OKAY) { \
60fc6476e044 Update to libtommath v1.0
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
97 return res; \
60fc6476e044 Update to libtommath v1.0
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
98 } \
60fc6476e044 Update to libtommath v1.0
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
99 \
60fc6476e044 Update to libtommath v1.0
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
100 /* OR in the top four bits of the source */ \
1655
f52919ffd3b1 update ltm to 1.1.0 and enable FIPS 186.4 compliant key-generation (#79)
Steffen Jaeckel <s_jaeckel@gmx.de>
parents: 1470
diff changeset
101 a->dp[0] |= (mp_digit)(b >> ((sizeof(type) * 8u) - 4u)) & 15uL;\
1436
60fc6476e044 Update to libtommath v1.0
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
102 \
60fc6476e044 Update to libtommath v1.0
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
103 /* shift the source up to the next four bits */ \
60fc6476e044 Update to libtommath v1.0
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
104 b <<= 4; \
60fc6476e044 Update to libtommath v1.0
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
105 \
60fc6476e044 Update to libtommath v1.0
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
106 /* ensure that digits are not clamped off */ \
60fc6476e044 Update to libtommath v1.0
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
107 a->used += 1; \
60fc6476e044 Update to libtommath v1.0
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
108 } \
60fc6476e044 Update to libtommath v1.0
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
109 mp_clamp (a); \
60fc6476e044 Update to libtommath v1.0
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
110 return MP_OKAY; \
60fc6476e044 Update to libtommath v1.0
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
111 }
60fc6476e044 Update to libtommath v1.0
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
112
60fc6476e044 Update to libtommath v1.0
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
113 #ifdef __cplusplus
1655
f52919ffd3b1 update ltm to 1.1.0 and enable FIPS 186.4 compliant key-generation (#79)
Steffen Jaeckel <s_jaeckel@gmx.de>
parents: 1470
diff changeset
114 }
1436
60fc6476e044 Update to libtommath v1.0
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
115 #endif
60fc6476e044 Update to libtommath v1.0
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
116
60fc6476e044 Update to libtommath v1.0
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
117 #endif
60fc6476e044 Update to libtommath v1.0
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
118
60fc6476e044 Update to libtommath v1.0
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
119
1655
f52919ffd3b1 update ltm to 1.1.0 and enable FIPS 186.4 compliant key-generation (#79)
Steffen Jaeckel <s_jaeckel@gmx.de>
parents: 1470
diff changeset
120 /* ref: HEAD -> master, tag: v1.1.0 */
f52919ffd3b1 update ltm to 1.1.0 and enable FIPS 186.4 compliant key-generation (#79)
Steffen Jaeckel <s_jaeckel@gmx.de>
parents: 1470
diff changeset
121 /* git commit: 08549ad6bc8b0cede0b357a9c341c5c6473a9c55 */
f52919ffd3b1 update ltm to 1.1.0 and enable FIPS 186.4 compliant key-generation (#79)
Steffen Jaeckel <s_jaeckel@gmx.de>
parents: 1470
diff changeset
122 /* commit time: 2019-01-28 20:32:32 +0100 */