~ubuntu-branches/ubuntu/hardy/gnutls13/hardy-updates

« back to all changes in this revision

Viewing changes to lib/gnutls_extra_hooks.c

  • Committer: Bazaar Package Importer
  • Author(s): Andreas Metzler
  • Date: 2007-09-29 11:29:22 UTC
  • mfrom: (1.1.4 upstream)
  • Revision ID: james.westby@ubuntu.com-20070929112922-abqj0gl08kstu27v
Tags: 2.0.1-1
* New upstream version.
* Remove doc/*.info* on clean to allow building thrice in a row.
  (Closes: #441740)

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
/*
 
2
 * Copyright (C) 2007 Free Software Foundation
 
3
 *
 
4
 * Author: Simon Josefsson
 
5
 *
 
6
 * This file is part of GNUTLS.
 
7
 *
 
8
 * The GNUTLS library is free software; you can redistribute it and/or
 
9
 * modify it under the terms of the GNU Lesser General Public License
 
10
 * as published by the Free Software Foundation; either version 2.1 of
 
11
 * the License, or (at your option) any later version.
 
12
 *
 
13
 * This library is distributed in the hope that it will be useful, but
 
14
 * WITHOUT ANY WARRANTY; without even the implied warranty of
 
15
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
 
16
 * Lesser General Public License for more details.
 
17
 *
 
18
 * You should have received a copy of the GNU Lesser General Public
 
19
 * License along with this library; if not, write to the Free Software
 
20
 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301,
 
21
 * USA
 
22
 *
 
23
 */
 
24
 
 
25
#include <gnutls_int.h>
 
26
#include <gnutls_extra_hooks.h>
 
27
 
 
28
/* Variables used by libgnutls, set by
 
29
   _gnutls_add_openpgp_functions(), typically invoked by
 
30
   libgnutls_extra. */
 
31
_gnutls_openpgp_verify_key_func _E_gnutls_openpgp_verify_key;
 
32
_gnutls_openpgp_key_creation_time_func
 
33
_E_gnutls_openpgp_get_raw_key_creation_time;
 
34
_gnutls_openpgp_key_expiration_time_func
 
35
_E_gnutls_openpgp_get_raw_key_expiration_time;
 
36
_gnutls_openpgp_fingerprint_func _E_gnutls_openpgp_fingerprint;
 
37
_gnutls_openpgp_key_request_func _E_gnutls_openpgp_request_key;
 
38
_gnutls_openpgp_raw_key_to_gcert_func _E_gnutls_openpgp_raw_key_to_gcert;
 
39
_gnutls_openpgp_raw_privkey_to_gkey_func _E_gnutls_openpgp_raw_privkey_to_gkey;
 
40
_gnutls_openpgp_key_to_gcert_func _E_gnutls_openpgp_key_to_gcert;
 
41
_gnutls_openpgp_privkey_to_gkey_func _E_gnutls_openpgp_privkey_to_gkey;
 
42
_gnutls_openpgp_key_deinit_func _E_gnutls_openpgp_key_deinit;
 
43
_gnutls_openpgp_privkey_deinit_func _E_gnutls_openpgp_privkey_deinit;
 
44
 
 
45
/* Called by libgnutls_extra to set the OpenPGP functions that are
 
46
   needed by GnuTLS.  */
 
47
extern void
 
48
_gnutls_add_openpgp_functions
 
49
(_gnutls_openpgp_verify_key_func verify_key,
 
50
 _gnutls_openpgp_key_creation_time_func key_creation_time,
 
51
 _gnutls_openpgp_key_expiration_time_func key_expiration_time,
 
52
 _gnutls_openpgp_fingerprint_func fingerprint,
 
53
 _gnutls_openpgp_key_request_func request_key,
 
54
 _gnutls_openpgp_raw_key_to_gcert_func raw_key_to_gcert,
 
55
 _gnutls_openpgp_raw_privkey_to_gkey_func raw_privkey_to_gkey,
 
56
 _gnutls_openpgp_key_to_gcert_func key_to_gcert,
 
57
 _gnutls_openpgp_privkey_to_gkey_func privkey_to_gkey,
 
58
 _gnutls_openpgp_key_deinit_func key_deinit,
 
59
 _gnutls_openpgp_privkey_deinit_func privkey_deinit)
 
60
{
 
61
  _E_gnutls_openpgp_verify_key = verify_key;
 
62
  _E_gnutls_openpgp_get_raw_key_creation_time = key_creation_time;
 
63
  _E_gnutls_openpgp_get_raw_key_expiration_time = key_expiration_time;
 
64
  _E_gnutls_openpgp_fingerprint = fingerprint;
 
65
  _E_gnutls_openpgp_request_key = request_key;
 
66
  _E_gnutls_openpgp_raw_key_to_gcert = raw_key_to_gcert;
 
67
  _E_gnutls_openpgp_raw_privkey_to_gkey = raw_privkey_to_gkey;
 
68
  _E_gnutls_openpgp_key_to_gcert = key_to_gcert;
 
69
  _E_gnutls_openpgp_privkey_to_gkey = privkey_to_gkey;
 
70
  _E_gnutls_openpgp_key_deinit = key_deinit;
 
71
  _E_gnutls_openpgp_privkey_deinit = privkey_deinit;
 
72
 
 
73
}