mirror of
git://git.gnupg.org/gnupg.git
synced 2025-07-02 22:46:30 +02:00
extensions are now working and fixed a lot of bugs
This commit is contained in:
parent
e662bf708b
commit
6e1ca6b80f
40 changed files with 350 additions and 454 deletions
|
@ -29,11 +29,6 @@
|
|||
|
||||
#include "mpi.h"
|
||||
#include "../cipher/md.h"
|
||||
#ifdef HAVE_RSA_CIPHER
|
||||
#include "../cipher/rsa.h"
|
||||
#endif
|
||||
#include "../cipher/elgamal.h"
|
||||
#include "../cipher/dsa.h"
|
||||
#include "../cipher/random.h"
|
||||
|
||||
|
||||
|
@ -57,9 +52,7 @@
|
|||
#define DIGEST_ALGO_MD5 1
|
||||
#define DIGEST_ALGO_SHA1 2
|
||||
#define DIGEST_ALGO_RMD160 3
|
||||
#ifdef WITH_TIGER_HASH
|
||||
#define DIGEST_ALGO_TIGER 6
|
||||
#endif
|
||||
|
||||
#define is_RSA(a) ((a)==PUBKEY_ALGO_RSA || (a)==PUBKEY_ALGO_RSA_E \
|
||||
|| (a)==PUBKEY_ALGO_RSA_S )
|
||||
|
@ -123,7 +116,8 @@ int pubkey_check_secret_key( int algo, MPI *skey );
|
|||
int pubkey_encrypt( int algo, MPI *resarr, MPI data, MPI *pkey );
|
||||
int pubkey_decrypt( int algo, MPI *result, MPI *data, MPI *skey );
|
||||
int pubkey_sign( int algo, MPI *resarr, MPI hash, MPI *skey );
|
||||
int pubkey_verify( int algo, MPI hash, MPI *data, MPI *pkey );
|
||||
int pubkey_verify( int algo, MPI hash, MPI *data, MPI *pkey,
|
||||
int (*cmp)(void *, MPI), void *opaque );
|
||||
|
||||
/*-- smallprime.c --*/
|
||||
extern ushort small_prime_numbers[];
|
||||
|
|
|
@ -79,6 +79,10 @@ unsigned g10m_get_size( MPI a );
|
|||
******* miscellaneous functions *******
|
||||
*****************************************/
|
||||
|
||||
const char *g10m_revision_string(int mode);
|
||||
const char *g10c_revision_string(int mode);
|
||||
const char *g10u_revision_string(int mode);
|
||||
|
||||
MPI g10c_generate_secret_prime( unsigned nbits );
|
||||
unsigned char g10c_get_random_byte( int level );
|
||||
|
||||
|
|
|
@ -55,6 +55,7 @@ typedef struct mpi_struct {
|
|||
#define MPI_NULL NULL
|
||||
|
||||
#define mpi_get_nlimbs(a) ((a)->nlimbs)
|
||||
#define mpi_get_nbit_info(a) ((a)->nbits)
|
||||
#define mpi_is_neg(a) ((a)->sign)
|
||||
|
||||
/*-- mpiutil.c --*/
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue