@@ -6539,29 +6539,36 @@ \subsection{Radix to binary conversion}
65396539 unsigned int *names_list_size);
65406540\end {verbatim }
65416541You may want to call these functions twice, first to get the amount
6542- of memory to be allocated for the $ names_list $ , and a final time to
6543- actually populate $ names_list $ . If $ names_list $ is NULL,
6544- $ names_list_size $ will be the minimum size needed to receive the
6545- complete $ names_list $ . If $ names_list $ is NOT NULL, $ names_list $ must
6546- be a pointer to sufficient memory into which the $ names_list $ will be
6547- written. Also, the value in $ names_list_size $ sets the upper bound of
6542+ of memory to be allocated for the $ names \_ list $ , and a final time to
6543+ actually populate $ names \_ list $ . If $ names \_ list $ is NULL,
6544+ $ names \_ list \_ size $ will be the minimum size needed to receive the
6545+ complete $ names \_ list $ . If $ names \_ list $ is NOT NULL, $ names \_ list $ must
6546+ be a pointer to sufficient memory into which the $ names \_ list $ will be
6547+ written. Also, the value in $ names \_ list \_ size $ sets the upper bound of
65486548the number of characters to be written. A -1 return value signifies
65496549insufficient space.
65506550
6551- The format of the $ names_list $ string is a series of $ name,value$ pairs
6551+ The format of the $ names \_ list $ string is a series of $ name,value$ pairs
65526552where each name and value is separated by a comma, the pairs are separated
65536553by newlines, and the list is null terminated.
65546554
6555- Calling either of these functions will initialize the respective
6556- math library.
6555+ \index {crypt\_ mp\_ init()}
65576556\begin {verbatim }
6558- void init_LTM(void);
6559- void init_TFM(void);
6560- void init_GMP(void);
6557+ int crypt_mp_init(const char* mpi);
65616558\end {verbatim }
65626559
6560+ To ease the setup of a specific math descriptor, in cases where the library was compiled with support for multiple MPI libraries,
6561+ the function \textit {crypt\_ mp\_ init() } is provided.
6562+ It takes a string to the desired MPI library to use as an argument.
6563+ The three default MPI libraries are identified as follows, \textit {LibTomMath } as \texttt {"ltm" }, \textit {TomsFastmath } as \texttt {"tfm" }
6564+ and the \textit {GNU Multi Precision Arithmetic Library } as \texttt {"gmp" }.
6565+ The identification happens case-insensitive and only on the first character.
6566+
65636567Here is a Python program demonstrating how to call various LTC dynamic
65646568language support functions.
6569+
6570+ A more detailed example is given in the library source in \texttt {demos/demo\_ dynamic.py }.
6571+
65656572\begin {verbatim }
65666573from ctypes import *
65676574
@@ -8255,6 +8262,20 @@ \subsection{RSA Functions}
82558262
82568263Since the function is given the entire RSA key (for private keys only) CRT is possible as prescribed in the PKCS \# 1 v2.1 specification.
82578264
8265+
8266+ \mysection {Deprecated API functions}
8267+
8268+ \subsection {After v1.18.0 }
8269+
8270+ \index {init\_ LTM()} \index {init\_ TFM()} \index {init\_ GMP()}
8271+ \begin {verbatim }
8272+ void init_LTM(void);
8273+ void init_TFM(void);
8274+ void init_GMP(void);
8275+ \end {verbatim }
8276+
8277+ These three MPI init functions have been introduced in version 1.18.0 and have been deprecated in the same version in favor of \textit {crypt\_ mp\_ init() }.
8278+
82588279\newpage
82598280\markboth {Index}{Index}
82608281\input {crypt.ind }
0 commit comments