diff options
author | Werner Koch <wk@gnupg.org> | 2002-08-05 00:00:32 +0200 |
---|---|---|
committer | Werner Koch <wk@gnupg.org> | 2002-08-05 00:00:32 +0200 |
commit | 705873c41b194a5e93e471be69dfebd0103aaa09 (patch) | |
tree | 168005c65941d88d81e9f11774118dfce8889b14 | |
parent | * configure.ac (ALL_LINGUAS): Added Catalan. (diff) | |
download | gnupg2-1-1-91.tar.xz gnupg2-1-1-91.zip |
Removed some obsolete header files.V1-1-91
-rw-r--r-- | cipher/ChangeLog | 5 | ||||
-rw-r--r-- | cipher/Makefile.am | 3 | ||||
-rw-r--r-- | cipher/algorithms.h | 52 | ||||
-rw-r--r-- | cipher/blowfish.c | 3 | ||||
-rw-r--r-- | cipher/blowfish.h | 62 | ||||
-rw-r--r-- | cipher/cast5.c | 2 | ||||
-rw-r--r-- | cipher/cast5.h | 33 | ||||
-rw-r--r-- | cipher/cipher.c | 4 | ||||
-rw-r--r-- | cipher/des.c | 2 | ||||
-rw-r--r-- | cipher/des.h | 34 | ||||
-rw-r--r-- | cipher/dynload.h | 68 | ||||
-rw-r--r-- | cipher/rijndael.c | 2 | ||||
-rw-r--r-- | cipher/rndunix.c | 2 | ||||
-rw-r--r-- | cipher/twofish.c | 3 |
14 files changed, 64 insertions, 211 deletions
diff --git a/cipher/ChangeLog b/cipher/ChangeLog index 8aca3418d..7b8c87f2f 100644 --- a/cipher/ChangeLog +++ b/cipher/ChangeLog @@ -1,3 +1,8 @@ +2002-08-04 Werner Koch <wk@gnupg.org> + + * blowfish.h, cast5.h, des.h: Removed after moving all prototypes to + * algorithms.h: here. Changed all sources to use this one. + 2002-08-03 Stefan Bellon <sbellon@sbellon.de> * idea-stub.c (idea_get_info): RISC OS' Norcroft C needs a cast. diff --git a/cipher/Makefile.am b/cipher/Makefile.am index 59aae94d7..6f6ec3298 100644 --- a/cipher/Makefile.am +++ b/cipher/Makefile.am @@ -28,12 +28,9 @@ libcipher_a_SOURCES = cipher.c \ dynload.c \ bithelp.h \ des.c \ - des.h \ twofish.c \ blowfish.c \ - blowfish.h \ cast5.c \ - cast5.h \ rijndael.c \ elgamal.c \ elgamal.h \ diff --git a/cipher/algorithms.h b/cipher/algorithms.h index a6b910612..694a7e35c 100644 --- a/cipher/algorithms.h +++ b/cipher/algorithms.h @@ -62,5 +62,57 @@ tiger_get_info (int algo, size_t *contextsize, ); +const char * +des_get_info( int algo, size_t *keylen, + size_t *blocksize, size_t *contextsize, + int (**setkeyf)( void *c, byte *key, unsigned keylen ), + void (**encryptf)( void *c, byte *outbuf, byte *inbuf ), + void (**decryptf)( void *c, byte *outbuf, byte *inbuf ) + ); + +const char * +cast5_get_info( int algo, size_t *keylen, + size_t *blocksize, size_t *contextsize, + int (**setkeyf)( void *c, byte *key, unsigned keylen ), + void (**encryptf)( void *c, byte *outbuf, byte *inbuf ), + void (**decryptf)( void *c, byte *outbuf, byte *inbuf ) + ); + + +const char * +blowfish_get_info( int algo, size_t *keylen, + size_t *blocksize, size_t *contextsize, + int (**setkeyf)( void *c, byte *key, unsigned keylen ), + void (**encryptf)( void *c, byte *outbuf, byte *inbuf ), + void (**decryptf)( void *c, byte *outbuf, byte *inbuf ) + ); + +const char * +twofish_get_info( int algo, size_t *keylen, + size_t *blocksize, size_t *contextsize, + int (**setkeyf)( void *c, byte *key, unsigned keylen ), + void (**encryptf)( void *c, byte *outbuf, byte *inbuf ), + void (**decryptf)( void *c, byte *outbuf, byte *inbuf ) + ); + +/* this is just a kludge for the time we have not yet changed the cipher + * stuff to the scheme we use for random and digests */ +const char * +rijndael_get_info( int algo, size_t *keylen, + size_t *blocksize, size_t *contextsize, + int (**setkeyf)( void *c, byte *key, unsigned keylen ), + void (**encryptf)( void *c, byte *outbuf, byte *inbuf ), + void (**decryptf)( void *c, byte *outbuf, byte *inbuf ) + ); + +const char * +idea_get_info( int algo, size_t *keylen, + size_t *blocksize, size_t *contextsize, + int (**setkeyf)( void *c, byte *key, unsigned keylen ), + void (**encryptf)( void *c, byte *outbuf, byte *inbuf ), + void (**decryptf)( void *c, byte *outbuf, byte *inbuf ) + ); + + #endif /*GNUPG_ALGORITHMS_H*/ diff --git a/cipher/blowfish.c b/cipher/blowfish.c index d8ad1d00d..bf00fc462 100644 --- a/cipher/blowfish.c +++ b/cipher/blowfish.c @@ -36,8 +36,7 @@ #include <assert.h> #include "types.h" #include "errors.h" -#include "blowfish.h" -#include "dynload.h" +#include "algorithms.h" diff --git a/cipher/blowfish.h b/cipher/blowfish.h deleted file mode 100644 index 46e302288..000000000 --- a/cipher/blowfish.h +++ /dev/null @@ -1,62 +0,0 @@ -/* blowfish.h - * Copyright (C) 1998 Free Software Foundation, Inc. - * - * This file is part of GnuPG. - * - * GnuPG is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * GnuPG is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA - */ -#ifndef G10_BLOWFISH_H -#define G10_BLOWFISH_H - -#include "types.h" - - -const char * -blowfish_get_info( int algo, size_t *keylen, - size_t *blocksize, size_t *contextsize, - int (**setkeyf)( void *c, byte *key, unsigned keylen ), - void (**encryptf)( void *c, byte *outbuf, byte *inbuf ), - void (**decryptf)( void *c, byte *outbuf, byte *inbuf ) - ); - -/* this is just a kludge for the time we have not yet chnaged the cipher - * stuff to the scheme we use for random and digests */ -const char * -twofish_get_info( int algo, size_t *keylen, - size_t *blocksize, size_t *contextsize, - int (**setkeyf)( void *c, byte *key, unsigned keylen ), - void (**encryptf)( void *c, byte *outbuf, byte *inbuf ), - void (**decryptf)( void *c, byte *outbuf, byte *inbuf ) - ); - -/* this is just a kludge for the time we have not yet changed the cipher - * stuff to the scheme we use for random and digests */ -const char * -rijndael_get_info( int algo, size_t *keylen, - size_t *blocksize, size_t *contextsize, - int (**setkeyf)( void *c, byte *key, unsigned keylen ), - void (**encryptf)( void *c, byte *outbuf, byte *inbuf ), - void (**decryptf)( void *c, byte *outbuf, byte *inbuf ) - ); - -const char * -idea_get_info( int algo, size_t *keylen, - size_t *blocksize, size_t *contextsize, - int (**setkeyf)( void *c, byte *key, unsigned keylen ), - void (**encryptf)( void *c, byte *outbuf, byte *inbuf ), - void (**decryptf)( void *c, byte *outbuf, byte *inbuf ) - ); - -#endif /*G10_BLOWFISH_H*/ diff --git a/cipher/cast5.c b/cipher/cast5.c index c99b47e13..6373886f5 100644 --- a/cipher/cast5.c +++ b/cipher/cast5.c @@ -41,7 +41,7 @@ #include <string.h> #include "types.h" #include "errors.h" -#include "cast5.h" +#include "algorithms.h" #define CIPHER_ALGO_CAST5 3 diff --git a/cipher/cast5.h b/cipher/cast5.h deleted file mode 100644 index 798eaa23f..000000000 --- a/cipher/cast5.h +++ /dev/null @@ -1,33 +0,0 @@ -/* cast5.h - * Copyright (C) 1998 Free Software Foundation, Inc. - * - * This file is part of GnuPG. - * - * GnuPG is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * GnuPG is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA - */ -#ifndef G10_CAST5_H -#define G10_CAST5_H - -#include "types.h" - -const char * -cast5_get_info( int algo, size_t *keylen, - size_t *blocksize, size_t *contextsize, - int (**setkeyf)( void *c, byte *key, unsigned keylen ), - void (**encryptf)( void *c, byte *outbuf, byte *inbuf ), - void (**decryptf)( void *c, byte *outbuf, byte *inbuf ) - ); - -#endif /*G10_CAST5_H*/ diff --git a/cipher/cipher.c b/cipher/cipher.c index 761ec9b99..1924dcf16 100644 --- a/cipher/cipher.c +++ b/cipher/cipher.c @@ -27,9 +27,7 @@ #include "util.h" #include "errors.h" #include "cipher.h" -#include "des.h" -#include "blowfish.h" -#include "cast5.h" +#include "algorithms.h" #define MAX_BLOCKSIZE 16 diff --git a/cipher/des.c b/cipher/des.c index 90fd8199e..36383d2c0 100644 --- a/cipher/des.c +++ b/cipher/des.c @@ -116,7 +116,7 @@ #include <string.h> /* memcpy, memcmp */ #include "types.h" /* for byte and u32 typedefs */ #include "errors.h" -#include "des.h" +#include "algorithms.h" #if defined(__GNUC__) && defined(__GNU_LIBRARY__) #define working_memcmp memcmp diff --git a/cipher/des.h b/cipher/des.h deleted file mode 100644 index f68560686..000000000 --- a/cipher/des.h +++ /dev/null @@ -1,34 +0,0 @@ -/* des.h - * Copyright (C) 1998 Free Software Foundation, Inc. - * - * This file is part of GnuPG. - * - * GnuPG is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * GnuPG is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA - */ -#ifndef G10_DES_H -#define G10_DES_H - -#include "types.h" - - -const char * -des_get_info( int algo, size_t *keylen, - size_t *blocksize, size_t *contextsize, - int (**setkeyf)( void *c, byte *key, unsigned keylen ), - void (**encryptf)( void *c, byte *outbuf, byte *inbuf ), - void (**decryptf)( void *c, byte *outbuf, byte *inbuf ) - ); - -#endif /*G10_DES_H*/ diff --git a/cipher/dynload.h b/cipher/dynload.h deleted file mode 100644 index 328a7197b..000000000 --- a/cipher/dynload.h +++ /dev/null @@ -1,68 +0,0 @@ -/* dynload.h - * Copyright (C) 1998 Free Software Foundation, Inc. - * - * This file is part of GnuPG. - * - * GnuPG is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * GnuPG is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA - */ -#ifndef G10_CIPHER_DYNLOAD_H -#define G10_CIPHER_DYNLOAD_H - -#include "mpi.h" - - -void register_internal_cipher_extension( const char *module_id, - void * (*enumfunc)(int, int*, int*, int*) ); - -int -enum_gnupgext_digests( void **enum_context, - int *algo, - const char *(**r_get_info)( int, size_t*,byte**, int*, int*, - void (**)(void*), - void (**)(void*,byte*,size_t), - void (**)(void*),byte *(**)(void*)) ); - -const char * -enum_gnupgext_ciphers( void **enum_context, int *algo, - size_t *keylen, size_t *blocksize, size_t *contextsize, - int (**setkeyf)( void *c, byte *key, unsigned keylen ), - void (**encryptf)( void *c, byte *outbuf, byte *inbuf ), - void (**decryptf)( void *c, byte *outbuf, byte *inbuf ) - ); - - -const char * -enum_gnupgext_pubkeys( void **enum_context, int *algo, - int *npkey, int *nskey, int *nenc, int *nsig, int *use, - int (**generate)( int algo, unsigned nbits, MPI *skey, MPI **retfactors ), - int (**check_secret_key)( int algo, MPI *skey ), - int (**encryptf)( int algo, MPI *resarr, MPI data, MPI *pkey ), - int (**decryptf)( int algo, MPI *result, MPI *data, MPI *skey ), - int (**sign)( int algo, MPI *resarr, MPI data, MPI *skey ), - int (**verify)( int algo, MPI hash, MPI *data, MPI *pkey, - int (*cmp)(void *, MPI), void *opaquev ), - unsigned (**get_nbits)( int algo, MPI *pkey ) ); - - -int (*dynload_getfnc_gather_random(void))( void (*)(const void*, size_t, int), - int, size_t, int); -void (*dynload_getfnc_fast_random_poll(void) - )( void (*)(const void*, size_t, int), int ); - - -/** This function is in construct.c **/ -void cipher_modules_constructor(void); - -#endif /*G10_CIPHER_DYNLOAD_H*/ diff --git a/cipher/rijndael.c b/cipher/rijndael.c index cd29beaad..62c5bc23a 100644 --- a/cipher/rijndael.c +++ b/cipher/rijndael.c @@ -41,7 +41,7 @@ #include "types.h" /* for byte and u32 typedefs */ #include "util.h" #include "errors.h" -#include "dynload.h" +#include "algorithms.h" #define MAXKC (256/32) #define MAXROUNDS 14 diff --git a/cipher/rndunix.c b/cipher/rndunix.c index c8d140efe..ba1a55a1a 100644 --- a/cipher/rndunix.c +++ b/cipher/rndunix.c @@ -101,7 +101,7 @@ #include "types.h" /* for byte and u32 typedefs */ #ifndef IS_MODULE -#include "dynload.h" +#include "algorithms.h" #endif #include "util.h" diff --git a/cipher/twofish.c b/cipher/twofish.c index 175f7c414..5ed44872c 100644 --- a/cipher/twofish.c +++ b/cipher/twofish.c @@ -29,8 +29,7 @@ #include "types.h" /* for byte and u32 typedefs */ #include "util.h" #include "errors.h" -#include "dynload.h" - +#include "algorithms.h" /* Prototype for the self-test function. */ static const char *selftest(void); |