root/WizardsToolkit/trunk/utilities/content.h

Revision 1, 2.0 KB (checked in by cristy, 3 months ago)


Line 
1/*
2  Copyright 1999-2009 ImageMagick Studio LLC, a non-profit organization
3  dedicated to making software imaging solutions freely available.
4
5  You may not use this file except in compliance with the License.
6  obtain a copy of the License at
7
8    http://www.wizards-toolkit.org/script/license.php
9
10  Unless required by applicable law or agreed to in writing, software
11  distributed under the License is distributed on an "AS IS" BASIS,
12  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13  See the License for the specific language governing permissions and
14  limitations under the License.
15
16  Wizard's Toolkit cipher content methods.
17*/
18#ifndef WIZARDSTOOLKIT_UTILITIES_CONTENT_H
19#define WIZARDSTOOLKIT_UTILITIES_CONTENT_H
20
21#if defined(__cplusplus) || defined(c_plusplus)
22extern "C" {
23#endif
24
25#define CipherProtocolMajor  1
26#define CipherProtocolMinor  0
27
28typedef struct _ContentInfo
29{
30  BlobInfo
31    *plainblob,
32    *cipherblob;
33
34  char
35    *content,
36    *properties;
37
38  CipherInfo
39    *cipher_info;
40
41  CipherType
42    cipher;
43
44  CipherMode
45    mode;
46
47  char
48    *nonce;
49
50  AuthenticateInfo
51    *authenticate_info;
52
53  AuthenticateMethod
54    authenticate_method;
55
56  HashType
57    key_hash;
58
59  char
60    *keyring,
61    *id,
62    *passphrase;
63
64  unsigned int
65    key_length;
66
67  EntropyInfo
68    *entropy_info;
69
70  EntropyType
71    entropy;
72
73  unsigned int
74    level;
75
76  HMACInfo
77    *hmac_info;
78
79  HashType
80    hmac;
81
82  RandomInfo
83    *random_info;
84
85  HashType
86    random_hash;
87
88  size_t
89    chunksize;
90
91  time_t
92    access_date,
93    modify_date,
94    create_date,
95    timestamp;
96
97  char
98    *version;
99
100  unsigned int
101    protocol_major,
102    protocol_minor;
103
104  unsigned long
105    signature;
106} ContentInfo;
107
108extern WizardExport ContentInfo
109  *AcquireContentInfo(void),
110  *DestroyContentInfo(ContentInfo *);
111
112extern WizardExport WizardBooleanType
113  GetContentInfo(ContentInfo *,BlobInfo *,ExceptionInfo *),
114  PrintCipherProperties(const ContentInfo *,FILE *);
115
116#if defined(__cplusplus) || defined(c_plusplus)
117}
118#endif
119
120#endif
Note: See TracBrowser for help on using the browser.