summaryrefslogtreecommitdiffstats
path: root/g13/g13.h
blob: 9c0acb5b46c553e163c9cafdbec34f7e60930a3e (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
/* g13.h - Global definitions for G13.
 * Copyright (C) 2009 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 3 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, see <https://www.gnu.org/licenses/>.
 */

#ifndef G13_H
#define G13_H

#include "g13-common.h"


/* Forward declaration for an object defined in server.c.  */
struct server_local_s;
/* Forward declaration for an object defined in call-syshelp.c.  */
struct call_syshelp_s;


/* Session control object.  This object is passed down to most
   functions.  The default values for it are set by
   g13_init_default_ctrl(). */
struct server_control_s
{
  int no_server;      /* We are not running under server control */
  int  status_fd;     /* Only for non-server mode */
  struct server_local_s *server_local;
  struct call_syshelp_s *syshelp_local;

  int agent_seen;     /* Flag indicating that the gpg-agent has been
                         accessed.  */

  int with_colons;    /* Use column delimited output format */

  /* Type of the current container.  See the CONTTYPE_ constants.  */
  int conttype;

  strlist_t recipients; /* List of recipients.  */

};


/*-- g13.c --*/
void g13_init_default_ctrl (ctrl_t ctrl);
void g13_deinit_default_ctrl (ctrl_t ctrl);
void g13_request_shutdown (void);

#endif /*G13_H*/