updates.
[silc.git] / lib / silcske / silcske_status.h
1 /*
2
3   silcske_status.h
4
5   Author: Pekka Riikonen <priikone@silcnet.org>
6
7   Copyright (C) 2000 - 2001 Pekka Riikonen
8
9   This program is free software; you can redistribute it and/or modify
10   it under the terms of the GNU General Public License as published by
11   the Free Software Foundation; either version 2 of the License, or
12   (at your option) any later version.
13   
14   This program is distributed in the hope that it will be useful,
15   but WITHOUT ANY WARRANTY; without even the implied warranty of
16   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
17   GNU General Public License for more details.
18
19 */
20
21 #ifndef SILCSKE_STATUS_H
22 #define SILCSKE_STATUS_H
23
24 /* Status flags returned by all SKE routines */
25 typedef enum {
26   /* These are defined by the protocol */
27   SILC_SKE_STATUS_OK                     = 0,
28   SILC_SKE_STATUS_ERROR                  = 1,
29   SILC_SKE_STATUS_BAD_PAYLOAD            = 2,
30   SILC_SKE_STATUS_UNKNOWN_GROUP          = 3,
31   SILC_SKE_STATUS_UNKNOWN_CIPHER         = 4,
32   SILC_SKE_STATUS_UNKNOWN_PKCS           = 5,
33   SILC_SKE_STATUS_UNKNOWN_HASH_FUNCTION  = 6,
34   SILC_SKE_STATUS_UNKNOWN_HMAC           = 7,
35   SILC_SKE_STATUS_UNSUPPORTED_PUBLIC_KEY = 8,
36   SILC_SKE_STATUS_INCORRECT_SIGNATURE    = 9,
37   SILC_SKE_STATUS_BAD_VERSION            = 10,
38   SILC_SKE_STATUS_INVALID_COOKIE         = 11,
39
40   SILC_SKE_STATUS_PENDING,
41   SILC_SKE_STATUS_PUBLIC_KEY_NOT_PROVIDED,
42   SILC_SKE_STATUS_KEY_EXCHANGE_NOT_ACTIVE,
43   SILC_SKE_STATUS_BAD_RESERVED_FIELD,
44   SILC_SKE_STATUS_BAD_PAYLOAD_LENGTH,
45   SILC_SKE_STATUS_INCORRECT_HASH,
46   SILC_SKE_STATUS_FREED,
47 } SilcSKEStatus;
48
49 extern const char *silc_ske_status_string[];
50
51 #endif