2006-09-24 Marcus Brinkmann <marcus@g10code.de>
[gnupg.git] / common / errors.h
blob131891f65d07dcaa15e8638bdb17c5239c80ae0e
1 /* errors.h - Globally used error codes
2 * Copyright (C) 2001 Free Software Foundation, Inc.
4 * This file is part of GnuPG.
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.
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.
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., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301,
19 * USA.
22 #ifndef GNUPG_COMMON_ERRORS_H
23 #define GNUPG_COMMON_ERRORS_H
25 #include "util.h"
27 /* Status codes - fixme: should go into another file */
28 enum {
29 STATUS_ENTER,
30 STATUS_LEAVE,
31 STATUS_ABORT,
32 STATUS_GOODSIG,
33 STATUS_BADSIG,
34 STATUS_ERRSIG,
35 STATUS_BADARMOR,
36 STATUS_RSA_OR_IDEA,
37 STATUS_SIGEXPIRED,
38 STATUS_KEYREVOKED,
39 STATUS_TRUST_UNDEFINED,
40 STATUS_TRUST_NEVER,
41 STATUS_TRUST_MARGINAL,
42 STATUS_TRUST_FULLY,
43 STATUS_TRUST_ULTIMATE,
45 STATUS_SHM_INFO,
46 STATUS_SHM_GET,
47 STATUS_SHM_GET_BOOL,
48 STATUS_SHM_GET_HIDDEN,
50 STATUS_NEED_PASSPHRASE,
51 STATUS_VALIDSIG,
52 STATUS_SIG_ID,
53 STATUS_ENC_TO,
54 STATUS_NODATA,
55 STATUS_BAD_PASSPHRASE,
56 STATUS_NO_PUBKEY,
57 STATUS_NO_SECKEY,
58 STATUS_NEED_PASSPHRASE_SYM,
59 STATUS_DECRYPTION_FAILED,
60 STATUS_DECRYPTION_OKAY,
61 STATUS_MISSING_PASSPHRASE,
62 STATUS_GOOD_PASSPHRASE,
63 STATUS_GOODMDC,
64 STATUS_BADMDC,
65 STATUS_ERRMDC,
66 STATUS_IMPORTED,
67 STATUS_IMPORT_OK,
68 STATUS_IMPORT_PROBLEM,
69 STATUS_IMPORT_RES,
70 STATUS_FILE_START,
71 STATUS_FILE_DONE,
72 STATUS_FILE_ERROR,
74 STATUS_BEGIN_DECRYPTION,
75 STATUS_END_DECRYPTION,
76 STATUS_BEGIN_ENCRYPTION,
77 STATUS_END_ENCRYPTION,
79 STATUS_DELETE_PROBLEM,
80 STATUS_GET_BOOL,
81 STATUS_GET_LINE,
82 STATUS_GET_HIDDEN,
83 STATUS_GOT_IT,
84 STATUS_PROGRESS,
85 STATUS_SIG_CREATED,
86 STATUS_SESSION_KEY,
87 STATUS_NOTATION_NAME,
88 STATUS_NOTATION_DATA,
89 STATUS_POLICY_URL,
90 STATUS_BEGIN_STREAM,
91 STATUS_END_STREAM,
92 STATUS_KEY_CREATED,
93 STATUS_USERID_HIN,
94 STATUS_UNEXPECTED,
95 STATUS_INV_RECP,
96 STATUS_NO_RECP,
97 STATUS_ALREADY_SIGNED,
99 STATUS_EXPSIG,
100 STATUS_EXPKEYSIG,
102 STATUS_TRUNCATED,
103 STATUS_ERROR,
104 STATUS_NEWSIG
108 /*-- errors.c (build by mkerror and mkerrtok) --*/
109 const char *gnupg_strerror (int err);
110 const char *gnupg_error_token (int err);
113 #endif /*GNUPG_COMMON_ERRORS_H*/