2 *****************************************************************************
6 * Author: Damien S. Stuart
8 * Purpose: fko context definition.
10 * Copyright 2009-2010 Damien Stuart (dstuart@dstuart.org)
12 * License (GNU Public License):
14 * This program is free software; you can redistribute it and/or
15 * modify it under the terms of the GNU General Public License
16 * as published by the Free Software Foundation; either version 2
17 * of the License, or (at your option) any later version.
19 * This program is distributed in the hope that it will be useful,
20 * but WITHOUT ANY WARRANTY; without even the implied warranty of
21 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
22 * GNU General Public License for more details.
24 * You should have received a copy of the GNU General Public License
25 * along with this program; if not, write to the Free Software
26 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
29 *****************************************************************************
32 #define FKO_CONTEXT_H 1
34 #include "fko_common.h"
37 /* Stucture to hold a list of the gpg signature information
38 * we are interested in.
41 struct fko_gpg_sig *next;
42 gpgme_sigsum_t summary;
47 typedef struct fko_gpg_sig *fko_gpg_sig_t;
48 #endif /* HAVE_LIBGPGME */
50 /* The pieces we need to make an FKO SPA data packet.
53 /* FKO SPA user-definable message data */
61 unsigned int client_timeout;
63 /* FKO SPA user-settable message encoding types */
65 short encryption_type;
67 /* Computed or predefined data */
71 /* Digest of raw encrypted/base64 data - this is used
72 * for replay attack detection
75 short raw_digest_type;
77 /* Computed processed data (encodings, etc.) */
83 unsigned char initval;
86 /* For gpgme support */
92 unsigned char have_gpgme_context;
95 gpgme_key_t recipient_key;
96 gpgme_key_t signer_key;
98 unsigned char verify_gpg_sigs;
99 unsigned char ignore_gpg_sig_error;
101 fko_gpg_sig_t gpg_sigs;
103 gpgme_error_t gpg_err;
104 #endif /* HAVE_LIBGPGME */
107 #endif /* FKO_CONTEXT_H */