Added SILC Thread Queue API
[crypto.git] / lib / silccore / silcmessage_i.h
1 /*
2
3   silcmessage_i.h
4
5   Author: Pekka Riikonen <priikone@silcnet.org>
6
7   Copyright (C) 2006 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; version 2 of the License.
12
13   This program is distributed in the hope that it will be useful,
14   but WITHOUT ANY WARRANTY; without even the implied warranty of
15   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
16   GNU General Public License for more details.
17
18 */
19
20 #ifndef SILCMESSAGE_I_H
21 #define SILCMESSAGE_I_H
22
23 #ifndef SILCMESSAGE_I_H
24 #error "Do not include this header directly"
25 #endif
26
27 /* The SILC_MESSAGE_FLAG_SIGNED Payload */
28 typedef struct SilcMessageSignedPayloadStruct {
29   unsigned char *pk_data;
30   unsigned char *sign_data;
31   SilcUInt16 pk_len;
32   SilcUInt16 pk_type;
33   SilcUInt16 sign_len;
34 } *SilcMessageSignedPayload;
35
36 /* Message Payload structure. */
37 struct SilcMessagePayloadObject {
38   unsigned char *data;
39   unsigned char *pad;
40   unsigned char *mac;
41   struct SilcMessageSignedPayloadStruct sig;
42   SilcMessageFlags flags;
43   SilcUInt16 data_len;
44   SilcUInt16 pad_len;
45   SilcUInt16 iv_len;
46   unsigned int allocated  : 1;
47 };
48
49 #endif /* SILCMESSAGE_I_H */