~ubuntu-branches/ubuntu/karmic/gnupg2/karmic-security

« back to all changes in this revision

Viewing changes to cipher/dynload.h

  • Committer: Bazaar Package Importer
  • Author(s): Thomas Viehmann
  • Date: 2008-10-04 10:25:53 UTC
  • mfrom: (5.1.15 intrepid)
  • Revision ID: james.westby@ubuntu.com-20081004102553-fv62pp8dsitxli47
Tags: 2.0.9-3.1
* Non-maintainer upload.
* agent/gpg-agent.c: Deinit the threading library before exec'ing
  the command to run in --daemon mode. And because that still doesn't
  restore the sigprocmask, do that manually. Closes: #499569

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
/* dynload.h
2
 
 *      Copyright (C) 1998 Free Software Foundation, Inc.
3
 
 *
4
 
 * This file is part of GnuPG.
5
 
 *
6
 
 * GnuPG is free software; you can redistribute it and/or modify
7
 
 * it under the terms of the GNU General Public License as published by
8
 
 * the Free Software Foundation; either version 2 of the License, or
9
 
 * (at your option) any later version.
10
 
 *
11
 
 * GnuPG is distributed in the hope that it will be useful,
12
 
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
13
 
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
14
 
 * GNU General Public License for more details.
15
 
 *
16
 
 * You should have received a copy of the GNU General Public License
17
 
 * along with this program; if not, write to the Free Software
18
 
 * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA
19
 
 */
20
 
#ifndef G10_CIPHER_DYNLOAD_H
21
 
#define G10_CIPHER_DYNLOAD_H
22
 
 
23
 
#include "mpi.h"
24
 
 
25
 
 
26
 
void register_internal_cipher_extension( const char *module_id,
27
 
                              void * (*enumfunc)(int, int*, int*, int*) );
28
 
 
29
 
int
30
 
enum_gnupgext_digests( void **enum_context,
31
 
            int *algo,
32
 
            const char *(**r_get_info)( int, size_t*,byte**, int*, int*,
33
 
                                       void (**)(void*),
34
 
                                       void (**)(void*,byte*,size_t),
35
 
                                       void (**)(void*),byte *(**)(void*)) );
36
 
 
37
 
const char *
38
 
enum_gnupgext_ciphers( void **enum_context, int *algo,
39
 
                       size_t *keylen, size_t *blocksize, size_t *contextsize,
40
 
                       int  (**setkeyf)( void *c, byte *key, unsigned keylen ),
41
 
                       void (**encryptf)( void *c, byte *outbuf, byte *inbuf ),
42
 
                       void (**decryptf)( void *c, byte *outbuf, byte *inbuf )
43
 
                     );
44
 
 
45
 
 
46
 
const char *
47
 
enum_gnupgext_pubkeys( void **enum_context, int *algo,
48
 
    int *npkey, int *nskey, int *nenc, int *nsig, int *use,
49
 
    int (**generate)( int algo, unsigned nbits, MPI *skey, MPI **retfactors ),
50
 
    int (**check_secret_key)( int algo, MPI *skey ),
51
 
    int (**encryptf)( int algo, MPI *resarr, MPI data, MPI *pkey ),
52
 
    int (**decryptf)( int algo, MPI *result, MPI *data, MPI *skey ),
53
 
    int (**sign)( int algo, MPI *resarr, MPI data, MPI *skey ),
54
 
    int (**verify)( int algo, MPI hash, MPI *data, MPI *pkey,
55
 
                    int (*cmp)(void *, MPI), void *opaquev ),
56
 
    unsigned (**get_nbits)( int algo, MPI *pkey ) );
57
 
 
58
 
 
59
 
int (*dynload_getfnc_gather_random(void))( void (*)(const void*, size_t, int),
60
 
                                           int, size_t, int);
61
 
void (*dynload_getfnc_fast_random_poll(void)
62
 
                                )( void (*)(const void*, size_t, int), int );
63
 
 
64
 
 
65
 
/** This function is in construct.c **/
66
 
void cipher_modules_constructor(void);
67
 
 
68
 
#endif /*G10_CIPHER_DYNLOAD_H*/