aboutsummaryrefslogtreecommitdiff
path: root/src/plugins/test_ole2.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/plugins/test_ole2.c')
-rw-r--r--src/plugins/test_ole2.c907
1 files changed, 463 insertions, 444 deletions
diff --git a/src/plugins/test_ole2.c b/src/plugins/test_ole2.c
index 2859bb4..2870050 100644
--- a/src/plugins/test_ole2.c
+++ b/src/plugins/test_ole2.c
@@ -36,457 +36,476 @@
36int 36int
37main (int argc, char *argv[]) 37main (int argc, char *argv[])
38{ 38{
39 struct SolutionData ole2_msword_sol[] = 39 struct SolutionData ole2_msword_sol[] = {
40 { 40 {
41 { 41 EXTRACTOR_METATYPE_CREATOR,
42 EXTRACTOR_METATYPE_CREATOR, 42 EXTRACTOR_METAFORMAT_UTF8,
43 EXTRACTOR_METAFORMAT_UTF8, 43 "text/plain",
44 "text/plain", 44 "Nils Durner",
45 "Nils Durner", 45 strlen ("Nils Durner") + 1,
46 strlen ("Nils Durner") + 1, 46 0
47 0 47 },
48 }, 48 {
49 { 49 EXTRACTOR_METATYPE_UNKNOWN_DATE,
50 EXTRACTOR_METATYPE_UNKNOWN_DATE, 50 EXTRACTOR_METAFORMAT_UTF8,
51 EXTRACTOR_METAFORMAT_UTF8, 51 "text/plain",
52 "text/plain", 52 "2005-03-21T06:11:12Z",
53 "2005-03-21T06:11:12Z", 53 strlen ("2005-03-21T06:11:12Z") + 1,
54 strlen ("2005-03-21T06:11:12Z") + 1, 54 0
55 0 55 },
56 }, 56 {
57 { 57 EXTRACTOR_METATYPE_DESCRIPTION,
58 EXTRACTOR_METATYPE_DESCRIPTION, 58 EXTRACTOR_METAFORMAT_UTF8,
59 EXTRACTOR_METAFORMAT_UTF8, 59 "text/plain",
60 "text/plain", 60 "This is a small document to test meta data extraction by GNU libextractor.",
61 "This is a small document to test meta data extraction by GNU libextractor.", 61 strlen (
62 strlen ("This is a small document to test meta data extraction by GNU libextractor.") + 1, 62 "This is a small document to test meta data extraction by GNU libextractor.")
63 0 63 + 1,
64 }, 64 0
65 { 65 },
66 EXTRACTOR_METATYPE_KEYWORDS, 66 {
67 EXTRACTOR_METAFORMAT_UTF8, 67 EXTRACTOR_METATYPE_KEYWORDS,
68 "text/plain", 68 EXTRACTOR_METAFORMAT_UTF8,
69 "ole ole2 eole2extractor", 69 "text/plain",
70 strlen ("ole ole2 eole2extractor") + 1, 70 "ole ole2 eole2extractor",
71 0 71 strlen ("ole ole2 eole2extractor") + 1,
72 }, 72 0
73 { 73 },
74 EXTRACTOR_METATYPE_SUBJECT, 74 {
75 EXTRACTOR_METAFORMAT_UTF8, 75 EXTRACTOR_METATYPE_SUBJECT,
76 "text/plain", 76 EXTRACTOR_METAFORMAT_UTF8,
77 "GNU libextractor", 77 "text/plain",
78 strlen ("GNU libextractor") + 1, 78 "GNU libextractor",
79 0 79 strlen ("GNU libextractor") + 1,
80 }, 80 0
81 { 81 },
82 EXTRACTOR_METATYPE_TITLE, 82 {
83 EXTRACTOR_METAFORMAT_UTF8, 83 EXTRACTOR_METATYPE_TITLE,
84 "text/plain", 84 EXTRACTOR_METAFORMAT_UTF8,
85 "Testcase for the ole2 extractor", 85 "text/plain",
86 strlen ("Testcase for the ole2 extractor") + 1, 86 "Testcase for the ole2 extractor",
87 0 87 strlen ("Testcase for the ole2 extractor") + 1,
88 }, 88 0
89 { 89 },
90 EXTRACTOR_METATYPE_LAST_SAVED_BY, 90 {
91 EXTRACTOR_METAFORMAT_UTF8, 91 EXTRACTOR_METATYPE_LAST_SAVED_BY,
92 "text/plain", 92 EXTRACTOR_METAFORMAT_UTF8,
93 "Nils Durner", 93 "text/plain",
94 strlen ("Nils Durner") + 1, 94 "Nils Durner",
95 0 95 strlen ("Nils Durner") + 1,
96 }, 96 0
97 { 97 },
98 EXTRACTOR_METATYPE_CREATION_DATE, 98 {
99 EXTRACTOR_METAFORMAT_UTF8, 99 EXTRACTOR_METATYPE_CREATION_DATE,
100 "text/plain", 100 EXTRACTOR_METAFORMAT_UTF8,
101 "2005-03-21T06:10:19Z", 101 "text/plain",
102 strlen ("2005-03-21T06:10:19Z") + 1, 102 "2005-03-21T06:10:19Z",
103 0 103 strlen ("2005-03-21T06:10:19Z") + 1,
104 }, 104 0
105 { 105 },
106 EXTRACTOR_METATYPE_EDITING_CYCLES, 106 {
107 EXTRACTOR_METAFORMAT_UTF8, 107 EXTRACTOR_METATYPE_EDITING_CYCLES,
108 "text/plain", 108 EXTRACTOR_METAFORMAT_UTF8,
109 "2", 109 "text/plain",
110 strlen ("2") + 1, 110 "2",
111 0 111 strlen ("2") + 1,
112 }, 112 0
113 { 0, 0, NULL, NULL, 0, -1 } 113 },
114 }; 114 { 0, 0, NULL, NULL, 0, -1 }
115 };
115 116
116 struct SolutionData ole2_starwriter_sol[] = 117 struct SolutionData ole2_starwriter_sol[] = {
117 { 118 {
118 { 119 EXTRACTOR_METATYPE_CREATOR,
119 EXTRACTOR_METATYPE_CREATOR, 120 EXTRACTOR_METAFORMAT_UTF8,
120 EXTRACTOR_METAFORMAT_UTF8, 121 "text/plain",
121 "text/plain", 122 "Christian Grothoff",
122 "Christian Grothoff", 123 strlen ("Christian Grothoff") + 1,
123 strlen ("Christian Grothoff") + 1, 124 0
124 0 125 },
125 }, 126 {
126 { 127 EXTRACTOR_METATYPE_UNKNOWN_DATE,
127 EXTRACTOR_METATYPE_UNKNOWN_DATE, 128 EXTRACTOR_METAFORMAT_UTF8,
128 EXTRACTOR_METAFORMAT_UTF8, 129 "text/plain",
129 "text/plain", 130 "2004-09-24T02:54:31Z",
130 "2004-09-24T02:54:31Z", 131 strlen ("2004-09-24T02:54:31Z") + 1,
131 strlen ("2004-09-24T02:54:31Z") + 1, 132 0
132 0 133 },
133 }, 134 {
134 { 135 EXTRACTOR_METATYPE_DESCRIPTION,
135 EXTRACTOR_METATYPE_DESCRIPTION, 136 EXTRACTOR_METAFORMAT_UTF8,
136 EXTRACTOR_METAFORMAT_UTF8, 137 "text/plain",
137 "text/plain", 138 "The comments",
138 "The comments", 139 strlen ("The comments") + 1,
139 strlen ("The comments") + 1, 140 0
140 0 141 },
141 }, 142 {
142 { 143 EXTRACTOR_METATYPE_KEYWORDS,
143 EXTRACTOR_METATYPE_KEYWORDS, 144 EXTRACTOR_METAFORMAT_UTF8,
144 EXTRACTOR_METAFORMAT_UTF8, 145 "text/plain",
145 "text/plain", 146 "The Keywords",
146 "The Keywords", 147 strlen ("The Keywords") + 1,
147 strlen ("The Keywords") + 1, 148 0
148 0 149 },
149 }, 150 {
150 { 151 EXTRACTOR_METATYPE_SUBJECT,
151 EXTRACTOR_METATYPE_SUBJECT, 152 EXTRACTOR_METAFORMAT_UTF8,
152 EXTRACTOR_METAFORMAT_UTF8, 153 "text/plain",
153 "text/plain", 154 "The Subject",
154 "The Subject", 155 strlen ("The Subject") + 1,
155 strlen ("The Subject") + 1, 156 0
156 0 157 },
157 }, 158 {
158 { 159 EXTRACTOR_METATYPE_TITLE,
159 EXTRACTOR_METATYPE_TITLE, 160 EXTRACTOR_METAFORMAT_UTF8,
160 EXTRACTOR_METAFORMAT_UTF8, 161 "text/plain",
161 "text/plain", 162 "The Title",
162 "The Title", 163 strlen ("The Title") + 1,
163 strlen ("The Title") + 1, 164 0
164 0 165 },
165 }, 166 {
166 { 167 EXTRACTOR_METATYPE_LAST_SAVED_BY,
167 EXTRACTOR_METATYPE_LAST_SAVED_BY, 168 EXTRACTOR_METAFORMAT_UTF8,
168 EXTRACTOR_METAFORMAT_UTF8, 169 "text/plain",
169 "text/plain", 170 "Christian Grothoff",
170 "Christian Grothoff", 171 strlen ("Christian Grothoff") + 1,
171 strlen ("Christian Grothoff") + 1, 172 0
172 0 173 },
173 }, 174 {
174 { 175 EXTRACTOR_METATYPE_CREATION_DATE,
175 EXTRACTOR_METATYPE_CREATION_DATE, 176 EXTRACTOR_METAFORMAT_UTF8,
176 EXTRACTOR_METAFORMAT_UTF8, 177 "text/plain",
177 "text/plain", 178 "2004-09-24T02:53:15Z",
178 "2004-09-24T02:53:15Z", 179 strlen ("2004-09-24T02:53:15Z") + 1,
179 strlen ("2004-09-24T02:53:15Z") + 1, 180 0
180 0 181 },
181 }, 182 {
182 { 183 EXTRACTOR_METATYPE_EDITING_CYCLES,
183 EXTRACTOR_METATYPE_EDITING_CYCLES, 184 EXTRACTOR_METAFORMAT_UTF8,
184 EXTRACTOR_METAFORMAT_UTF8, 185 "text/plain",
185 "text/plain", 186 "4",
186 "4", 187 strlen ("4") + 1,
187 strlen ("4") + 1, 188 0
188 0 189 },
189 }, 190 {
190 { 191 EXTRACTOR_METATYPE_TITLE,
191 EXTRACTOR_METATYPE_TITLE, 192 EXTRACTOR_METAFORMAT_UTF8,
192 EXTRACTOR_METAFORMAT_UTF8, 193 "text/plain",
193 "text/plain", 194 "The Title",
194 "The Title", 195 strlen ("The Title") + 1,
195 strlen ("The Title") + 1, 196 0
196 0 197 },
197 }, 198 {
198 { 199 EXTRACTOR_METATYPE_SUBJECT,
199 EXTRACTOR_METATYPE_SUBJECT, 200 EXTRACTOR_METAFORMAT_UTF8,
200 EXTRACTOR_METAFORMAT_UTF8, 201 "text/plain",
201 "text/plain", 202 "The Subject",
202 "The Subject", 203 strlen ("The Subject") + 1,
203 strlen ("The Subject") + 1, 204 0
204 0 205 },
205 }, 206 {
206 { 207 EXTRACTOR_METATYPE_COMMENT,
207 EXTRACTOR_METATYPE_COMMENT, 208 EXTRACTOR_METAFORMAT_UTF8,
208 EXTRACTOR_METAFORMAT_UTF8, 209 "text/plain",
209 "text/plain", 210 "The comments",
210 "The comments", 211 strlen ("The comments") + 1,
211 strlen ("The comments") + 1, 212 0
212 0 213 },
213 }, 214 {
214 { 215 EXTRACTOR_METATYPE_KEYWORDS,
215 EXTRACTOR_METATYPE_KEYWORDS, 216 EXTRACTOR_METAFORMAT_UTF8,
216 EXTRACTOR_METAFORMAT_UTF8, 217 "text/plain",
217 "text/plain", 218 "The Keywords",
218 "The Keywords", 219 strlen ("The Keywords") + 1,
219 strlen ("The Keywords") + 1, 220 0
220 0 221 },
221 }, 222 { 0, 0, NULL, NULL, 0, -1 }
222 { 0, 0, NULL, NULL, 0, -1 } 223 };
223 };
224#if HAVE_ICONV 224#if HAVE_ICONV
225 struct SolutionData ole2_blair_sol[] = 225 struct SolutionData ole2_blair_sol[] = {
226 { 226 {
227 { 227 EXTRACTOR_METATYPE_LANGUAGE,
228 EXTRACTOR_METATYPE_LANGUAGE, 228 EXTRACTOR_METAFORMAT_UTF8,
229 EXTRACTOR_METAFORMAT_UTF8, 229 "text/plain",
230 "text/plain", 230 "U.S. English",
231 "U.S. English", 231 strlen ("U.S. English") + 1,
232 strlen ("U.S. English") + 1, 232 0
233 0 233 },
234 }, 234 {
235 { 235 EXTRACTOR_METATYPE_CREATOR,
236 EXTRACTOR_METATYPE_CREATOR, 236 EXTRACTOR_METAFORMAT_UTF8,
237 EXTRACTOR_METAFORMAT_UTF8, 237 "text/plain",
238 "text/plain", 238 "default",
239 "default", 239 strlen ("default") + 1,
240 strlen ("default") + 1, 240 0
241 0 241 },
242 }, 242 {
243 { 243 EXTRACTOR_METATYPE_UNKNOWN_DATE,
244 EXTRACTOR_METATYPE_UNKNOWN_DATE, 244 EXTRACTOR_METAFORMAT_UTF8,
245 EXTRACTOR_METAFORMAT_UTF8, 245 "text/plain",
246 "text/plain", 246 "2003-02-03T11:18:00Z",
247 "2003-02-03T11:18:00Z", 247 strlen ("2003-02-03T11:18:00Z") + 1,
248 strlen ("2003-02-03T11:18:00Z") + 1, 248 0
249 0 249 },
250 }, 250 {
251 { 251 EXTRACTOR_METATYPE_TITLE,
252 EXTRACTOR_METATYPE_TITLE, 252 EXTRACTOR_METAFORMAT_UTF8,
253 EXTRACTOR_METAFORMAT_UTF8, 253 "text/plain",
254 "text/plain", 254 "Iraq- ITS INFRASTRUCTURE OF CONCEALMENT, DECEPTION AND INTIMIDATION",
255 "Iraq- ITS INFRASTRUCTURE OF CONCEALMENT, DECEPTION AND INTIMIDATION", 255 strlen (
256 strlen ("Iraq- ITS INFRASTRUCTURE OF CONCEALMENT, DECEPTION AND INTIMIDATION") + 1, 256 "Iraq- ITS INFRASTRUCTURE OF CONCEALMENT, DECEPTION AND INTIMIDATION")
257 0 257 + 1,
258 }, 258 0
259 { 259 },
260 EXTRACTOR_METATYPE_CHARACTER_COUNT, 260 {
261 EXTRACTOR_METAFORMAT_UTF8, 261 EXTRACTOR_METATYPE_CHARACTER_COUNT,
262 "text/plain", 262 EXTRACTOR_METAFORMAT_UTF8,
263 "22090", 263 "text/plain",
264 strlen ("22090") + 1, 264 "22090",
265 0 265 strlen ("22090") + 1,
266 }, 266 0
267 { 267 },
268 EXTRACTOR_METATYPE_LAST_SAVED_BY, 268 {
269 EXTRACTOR_METAFORMAT_UTF8, 269 EXTRACTOR_METATYPE_LAST_SAVED_BY,
270 "text/plain", 270 EXTRACTOR_METAFORMAT_UTF8,
271 "MKhan", 271 "text/plain",
272 strlen ("MKhan") + 1, 272 "MKhan",
273 0 273 strlen ("MKhan") + 1,
274 }, 274 0
275 { 275 },
276 EXTRACTOR_METATYPE_PAGE_COUNT, 276 {
277 EXTRACTOR_METAFORMAT_UTF8, 277 EXTRACTOR_METATYPE_PAGE_COUNT,
278 "text/plain", 278 EXTRACTOR_METAFORMAT_UTF8,
279 "1", 279 "text/plain",
280 strlen ("1") + 1, 280 "1",
281 0 281 strlen ("1") + 1,
282 }, 282 0
283 { 283 },
284 EXTRACTOR_METATYPE_WORD_COUNT, 284 {
285 EXTRACTOR_METAFORMAT_UTF8, 285 EXTRACTOR_METATYPE_WORD_COUNT,
286 "text/plain", 286 EXTRACTOR_METAFORMAT_UTF8,
287 "3875", 287 "text/plain",
288 strlen ("3875") + 1, 288 "3875",
289 0 289 strlen ("3875") + 1,
290 }, 290 0
291 { 291 },
292 EXTRACTOR_METATYPE_CREATION_DATE, 292 {
293 EXTRACTOR_METAFORMAT_UTF8, 293 EXTRACTOR_METATYPE_CREATION_DATE,
294 "text/plain", 294 EXTRACTOR_METAFORMAT_UTF8,
295 "2003-02-03T09:31:00Z", 295 "text/plain",
296 strlen ("2003-02-03T09:31:00Z") + 1, 296 "2003-02-03T09:31:00Z",
297 0 297 strlen ("2003-02-03T09:31:00Z") + 1,
298 }, 298 0
299 { 299 },
300 EXTRACTOR_METATYPE_EDITING_CYCLES, 300 {
301 EXTRACTOR_METAFORMAT_UTF8, 301 EXTRACTOR_METATYPE_EDITING_CYCLES,
302 "text/plain", 302 EXTRACTOR_METAFORMAT_UTF8,
303 "4", 303 "text/plain",
304 strlen ("4") + 1, 304 "4",
305 0 305 strlen ("4") + 1,
306 }, 306 0
307 { 307 },
308 EXTRACTOR_METATYPE_MIMETYPE, 308 {
309 EXTRACTOR_METAFORMAT_UTF8, 309 EXTRACTOR_METATYPE_MIMETYPE,
310 "text/plain", 310 EXTRACTOR_METAFORMAT_UTF8,
311 "application/vnd.ms-files", 311 "text/plain",
312 strlen ("application/vnd.ms-files") + 1, 312 "application/vnd.ms-files",
313 0 313 strlen ("application/vnd.ms-files") + 1,
314 }, 314 0
315 { 315 },
316 EXTRACTOR_METATYPE_CREATED_BY_SOFTWARE, 316 {
317 EXTRACTOR_METAFORMAT_UTF8, 317 EXTRACTOR_METATYPE_CREATED_BY_SOFTWARE,
318 "text/plain", 318 EXTRACTOR_METAFORMAT_UTF8,
319 "Microsoft Word 8.0", 319 "text/plain",
320 strlen ("Microsoft Word 8.0") + 1, 320 "Microsoft Word 8.0",
321 0 321 strlen ("Microsoft Word 8.0") + 1,
322 }, 322 0
323 { 323 },
324 EXTRACTOR_METATYPE_TEMPLATE, 324 {
325 EXTRACTOR_METAFORMAT_UTF8, 325 EXTRACTOR_METATYPE_TEMPLATE,
326 "text/plain", 326 EXTRACTOR_METAFORMAT_UTF8,
327 "Normal.dot", 327 "text/plain",
328 strlen ("Normal.dot") + 1, 328 "Normal.dot",
329 0 329 strlen ("Normal.dot") + 1,
330 }, 330 0
331 { 331 },
332 EXTRACTOR_METATYPE_LINE_COUNT, 332 {
333 EXTRACTOR_METAFORMAT_UTF8, 333 EXTRACTOR_METATYPE_LINE_COUNT,
334 "text/plain", 334 EXTRACTOR_METAFORMAT_UTF8,
335 "184", 335 "text/plain",
336 strlen ("184") + 1, 336 "184",
337 0 337 strlen ("184") + 1,
338 }, 338 0
339 { 339 },
340 EXTRACTOR_METATYPE_PARAGRAPH_COUNT, 340 {
341 EXTRACTOR_METAFORMAT_UTF8, 341 EXTRACTOR_METATYPE_PARAGRAPH_COUNT,
342 "text/plain", 342 EXTRACTOR_METAFORMAT_UTF8,
343 "44", 343 "text/plain",
344 strlen ("44") + 1, 344 "44",
345 0 345 strlen ("44") + 1,
346 }, 346 0
347 { 347 },
348 EXTRACTOR_METATYPE_REVISION_HISTORY, 348 {
349 EXTRACTOR_METAFORMAT_UTF8, 349 EXTRACTOR_METATYPE_REVISION_HISTORY,
350 "text/plain", 350 EXTRACTOR_METAFORMAT_UTF8,
351 "Revision #0: Author `cic22' worked on `C:\\DOCUME~1\\phamill\\LOCALS~1\\Temp\\AutoRecovery save of Iraq - security.asd'", 351 "text/plain",
352 strlen ("Revision #0: Author `cic22' worked on `C:\\DOCUME~1\\phamill\\LOCALS~1\\Temp\\AutoRecovery save of Iraq - security.asd'") + 1, 352 "Revision #0: Author `cic22' worked on `C:\\DOCUME~1\\phamill\\LOCALS~1\\Temp\\AutoRecovery save of Iraq - security.asd'",
353 0 353 strlen (
354 }, 354 "Revision #0: Author `cic22' worked on `C:\\DOCUME~1\\phamill\\LOCALS~1\\Temp\\AutoRecovery save of Iraq - security.asd'")
355 { 355 + 1,
356 EXTRACTOR_METATYPE_REVISION_HISTORY, 356 0
357 EXTRACTOR_METAFORMAT_UTF8, 357 },
358 "text/plain", 358 {
359 "Revision #1: Author `cic22' worked on `C:\\DOCUME~1\\phamill\\LOCALS~1\\Temp\\AutoRecovery save of Iraq - security.asd'", 359 EXTRACTOR_METATYPE_REVISION_HISTORY,
360 strlen ("Revision #1: Author `cic22' worked on `C:\\DOCUME~1\\phamill\\LOCALS~1\\Temp\\AutoRecovery save of Iraq - security.asd'") + 1, 360 EXTRACTOR_METAFORMAT_UTF8,
361 0 361 "text/plain",
362 }, 362 "Revision #1: Author `cic22' worked on `C:\\DOCUME~1\\phamill\\LOCALS~1\\Temp\\AutoRecovery save of Iraq - security.asd'",
363 { 363 strlen (
364 EXTRACTOR_METATYPE_REVISION_HISTORY, 364 "Revision #1: Author `cic22' worked on `C:\\DOCUME~1\\phamill\\LOCALS~1\\Temp\\AutoRecovery save of Iraq - security.asd'")
365 EXTRACTOR_METAFORMAT_UTF8, 365 + 1,
366 "text/plain", 366 0
367 "Revision #2: Author `cic22' worked on `C:\\DOCUME~1\\phamill\\LOCALS~1\\Temp\\AutoRecovery save of Iraq - security.asd'", 367 },
368 strlen ("Revision #2: Author `cic22' worked on `C:\\DOCUME~1\\phamill\\LOCALS~1\\Temp\\AutoRecovery save of Iraq - security.asd'") + 1, 368 {
369 0 369 EXTRACTOR_METATYPE_REVISION_HISTORY,
370 }, 370 EXTRACTOR_METAFORMAT_UTF8,
371 { 371 "text/plain",
372 EXTRACTOR_METATYPE_REVISION_HISTORY, 372 "Revision #2: Author `cic22' worked on `C:\\DOCUME~1\\phamill\\LOCALS~1\\Temp\\AutoRecovery save of Iraq - security.asd'",
373 EXTRACTOR_METAFORMAT_UTF8, 373 strlen (
374 "text/plain", 374 "Revision #2: Author `cic22' worked on `C:\\DOCUME~1\\phamill\\LOCALS~1\\Temp\\AutoRecovery save of Iraq - security.asd'")
375 "Revision #3: Author `JPratt' worked on `C:\\TEMP\\Iraq - security.doc'", 375 + 1,
376 strlen ("Revision #3: Author `JPratt' worked on `C:\\TEMP\\Iraq - security.doc'") + 1, 376 0
377 0 377 },
378 }, 378 {
379 { 379 EXTRACTOR_METATYPE_REVISION_HISTORY,
380 EXTRACTOR_METATYPE_REVISION_HISTORY, 380 EXTRACTOR_METAFORMAT_UTF8,
381 EXTRACTOR_METAFORMAT_UTF8, 381 "text/plain",
382 "text/plain", 382 "Revision #3: Author `JPratt' worked on `C:\\TEMP\\Iraq - security.doc'",
383 "Revision #4: Author `JPratt' worked on `A:\\Iraq - security.doc'", 383 strlen (
384 strlen ("Revision #4: Author `JPratt' worked on `A:\\Iraq - security.doc'") + 1, 384 "Revision #3: Author `JPratt' worked on `C:\\TEMP\\Iraq - security.doc'")
385 0 385 + 1,
386 }, 386 0
387 { 387 },
388 EXTRACTOR_METATYPE_REVISION_HISTORY, 388 {
389 EXTRACTOR_METAFORMAT_UTF8, 389 EXTRACTOR_METATYPE_REVISION_HISTORY,
390 "text/plain", 390 EXTRACTOR_METAFORMAT_UTF8,
391 "Revision #5: Author `ablackshaw' worked on `C:\\ABlackshaw\\Iraq - security.doc'", 391 "text/plain",
392 strlen ("Revision #5: Author `ablackshaw' worked on `C:\\ABlackshaw\\Iraq - security.doc'") + 1, 392 "Revision #4: Author `JPratt' worked on `A:\\Iraq - security.doc'",
393 0 393 strlen (
394 }, 394 "Revision #4: Author `JPratt' worked on `A:\\Iraq - security.doc'") + 1,
395 { 395 0
396 EXTRACTOR_METATYPE_REVISION_HISTORY, 396 },
397 EXTRACTOR_METAFORMAT_UTF8, 397 {
398 "text/plain", 398 EXTRACTOR_METATYPE_REVISION_HISTORY,
399 "Revision #6: Author `ablackshaw' worked on `C:\\ABlackshaw\\A;Iraq - security.doc'", 399 EXTRACTOR_METAFORMAT_UTF8,
400 strlen ("Revision #6: Author `ablackshaw' worked on `C:\\ABlackshaw\\A;Iraq - security.doc'") + 1, 400 "text/plain",
401 0 401 "Revision #5: Author `ablackshaw' worked on `C:\\ABlackshaw\\Iraq - security.doc'",
402 }, 402 strlen (
403 { 403 "Revision #5: Author `ablackshaw' worked on `C:\\ABlackshaw\\Iraq - security.doc'")
404 EXTRACTOR_METATYPE_REVISION_HISTORY, 404 + 1,
405 EXTRACTOR_METAFORMAT_UTF8, 405 0
406 "text/plain", 406 },
407 "Revision #7: Author `ablackshaw' worked on `A:\\Iraq - security.doc'", 407 {
408 strlen ("Revision #7: Author `ablackshaw' worked on `A:\\Iraq - security.doc'") + 1, 408 EXTRACTOR_METATYPE_REVISION_HISTORY,
409 0 409 EXTRACTOR_METAFORMAT_UTF8,
410 }, 410 "text/plain",
411 { 411 "Revision #6: Author `ablackshaw' worked on `C:\\ABlackshaw\\A;Iraq - security.doc'",
412 EXTRACTOR_METATYPE_REVISION_HISTORY, 412 strlen (
413 EXTRACTOR_METAFORMAT_UTF8, 413 "Revision #6: Author `ablackshaw' worked on `C:\\ABlackshaw\\A;Iraq - security.doc'")
414 "text/plain", 414 + 1,
415 "Revision #8: Author `MKhan' worked on `C:\\TEMP\\Iraq - security.doc'", 415 0
416 strlen ("Revision #8: Author `MKhan' worked on `C:\\TEMP\\Iraq - security.doc'") + 1, 416 },
417 0 417 {
418 }, 418 EXTRACTOR_METATYPE_REVISION_HISTORY,
419 { 419 EXTRACTOR_METAFORMAT_UTF8,
420 EXTRACTOR_METATYPE_REVISION_HISTORY, 420 "text/plain",
421 EXTRACTOR_METAFORMAT_UTF8, 421 "Revision #7: Author `ablackshaw' worked on `A:\\Iraq - security.doc'",
422 "text/plain", 422 strlen (
423 "Revision #9: Author `MKhan' worked on `C:\\WINNT\\Profiles\\mkhan\\Desktop\\Iraq.doc'", 423 "Revision #7: Author `ablackshaw' worked on `A:\\Iraq - security.doc'")
424 strlen ("Revision #9: Author `MKhan' worked on `C:\\WINNT\\Profiles\\mkhan\\Desktop\\Iraq.doc'") + 1, 424 + 1,
425 0 425 0
426 }, 426 },
427 { 0, 0, NULL, NULL, 0, -1 } 427 {
428 }; 428 EXTRACTOR_METATYPE_REVISION_HISTORY,
429 EXTRACTOR_METAFORMAT_UTF8,
430 "text/plain",
431 "Revision #8: Author `MKhan' worked on `C:\\TEMP\\Iraq - security.doc'",
432 strlen (
433 "Revision #8: Author `MKhan' worked on `C:\\TEMP\\Iraq - security.doc'")
434 + 1,
435 0
436 },
437 {
438 EXTRACTOR_METATYPE_REVISION_HISTORY,
439 EXTRACTOR_METAFORMAT_UTF8,
440 "text/plain",
441 "Revision #9: Author `MKhan' worked on `C:\\WINNT\\Profiles\\mkhan\\Desktop\\Iraq.doc'",
442 strlen (
443 "Revision #9: Author `MKhan' worked on `C:\\WINNT\\Profiles\\mkhan\\Desktop\\Iraq.doc'")
444 + 1,
445 0
446 },
447 { 0, 0, NULL, NULL, 0, -1 }
448 };
429#endif 449#endif
430 struct SolutionData ole2_excel_sol[] = 450 struct SolutionData ole2_excel_sol[] = {
431 {
432 {
433 EXTRACTOR_METATYPE_CREATOR,
434 EXTRACTOR_METAFORMAT_UTF8,
435 "text/plain",
436 "JV",
437 strlen ("JV") + 1,
438 0
439 },
440 {
441 EXTRACTOR_METATYPE_LAST_SAVED_BY,
442 EXTRACTOR_METAFORMAT_UTF8,
443 "text/plain",
444 "JV",
445 strlen ("JV") + 1,
446 0
447 },
448 {
449 EXTRACTOR_METATYPE_CREATION_DATE,
450 EXTRACTOR_METAFORMAT_UTF8,
451 "text/plain",
452 "2002-03-20T21:26:28Z",
453 strlen ("2002-03-20T21:26:28Z") + 1,
454 0
455 },
456 {
457 EXTRACTOR_METATYPE_MIMETYPE,
458 EXTRACTOR_METAFORMAT_UTF8,
459 "text/plain",
460 "application/vnd.ms-files",
461 strlen ("application/vnd.ms-files") + 1,
462 0
463 },
464 {
465 EXTRACTOR_METATYPE_CREATED_BY_SOFTWARE,
466 EXTRACTOR_METAFORMAT_UTF8,
467 "text/plain",
468 "Microsoft Excel",
469 strlen ("Microsoft Excel") + 1,
470 0
471 },
472 { 0, 0, NULL, NULL, 0, -1 }
473 };
474
475 struct ProblemSet ps[] =
476 { 451 {
477 { "testdata/ole2_msword.doc", 452 EXTRACTOR_METATYPE_CREATOR,
478 ole2_msword_sol }, 453 EXTRACTOR_METAFORMAT_UTF8,
479 { "testdata/ole2_starwriter40.sdw", 454 "text/plain",
480 ole2_starwriter_sol }, 455 "JV",
456 strlen ("JV") + 1,
457 0
458 },
459 {
460 EXTRACTOR_METATYPE_LAST_SAVED_BY,
461 EXTRACTOR_METAFORMAT_UTF8,
462 "text/plain",
463 "JV",
464 strlen ("JV") + 1,
465 0
466 },
467 {
468 EXTRACTOR_METATYPE_CREATION_DATE,
469 EXTRACTOR_METAFORMAT_UTF8,
470 "text/plain",
471 "2002-03-20T21:26:28Z",
472 strlen ("2002-03-20T21:26:28Z") + 1,
473 0
474 },
475 {
476 EXTRACTOR_METATYPE_MIMETYPE,
477 EXTRACTOR_METAFORMAT_UTF8,
478 "text/plain",
479 "application/vnd.ms-files",
480 strlen ("application/vnd.ms-files") + 1,
481 0
482 },
483 {
484 EXTRACTOR_METATYPE_CREATED_BY_SOFTWARE,
485 EXTRACTOR_METAFORMAT_UTF8,
486 "text/plain",
487 "Microsoft Excel",
488 strlen ("Microsoft Excel") + 1,
489 0
490 },
491 { 0, 0, NULL, NULL, 0, -1 }
492 };
493
494 struct ProblemSet ps[] = {
495 { "testdata/ole2_msword.doc",
496 ole2_msword_sol },
497 { "testdata/ole2_starwriter40.sdw",
498 ole2_starwriter_sol },
481#if HAVE_ICONV 499#if HAVE_ICONV
482 { "testdata/ole2_blair.doc", 500 { "testdata/ole2_blair.doc",
483 ole2_blair_sol }, 501 ole2_blair_sol },
484#endif 502#endif
485 { "testdata/ole2_excel.xls", 503 { "testdata/ole2_excel.xls",
486 ole2_excel_sol }, 504 ole2_excel_sol },
487 { NULL, NULL } 505 { NULL, NULL }
488 }; 506 };
489 return ET_main ("ole2", ps); 507 return ET_main ("ole2", ps);
490} 508}
491 509
510
492/* end of test_ole2.c */ 511/* end of test_ole2.c */