Debian Codegraph @

pkcs11/gnome2-store/gkm-gnome2-standalone.c

raw
1 /* -*- Mode: C; indent-tabs-mode: t; c-basic-offset: 8; tab-width: 8 -*- */
2 /* gkm-gnome2-standalone.h - The user-store PKCS#11 code as a standalone module
3
4 Copyright (C) 2008, Stef Walter
5
6 The Gnome Keyring Library is free software; you can redistribute it and/or
7 modify it under the terms of the GNU Library General Public License as
8 published by the Free Software Foundation; either version 2 of the
9 License, or (at your option) any later version.
10
11 The Gnome Keyring Library 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 GNU
14 Library General Public License for more details.
15
16 You should have received a copy of the GNU Library General Public
17 License along with the Gnome Library; see the file COPYING.LIB. If not,
18 <http://www.gnu.org/licenses/>.
19
20 Author: Stef Walter <[email protected]>
21 */
22
23 #include "config.h"
24
25 #include "gkm-gnome2-store.h"
26
27 #include "gkm/gkm-crypto.h"
28
29 #include "egg/egg-secure-memory.h"
30
31 #include "pkcs11/pkcs11.h"
32
33 #include <glib-object.h>
34
35 /* Module callbacks for secure memory */
36 EGG_SECURE_DEFINE_GLIB_GLOBALS ();
37
38 CK_RV
39 C_GetFunctionList (CK_FUNCTION_LIST_PTR_PTR list)
40 {
41 if (!list)
42 return CKR_ARGUMENTS_BAD;
43
44 #if !GLIB_CHECK_VERSION(2,35,0)
45 g_type_init ();
46 #endif
47
48 *list = gkm_gnome2_store_get_functions ();
49 return CKR_OK;
50 }