Merge branch 'vendor/TEXINFO'
[dragonfly.git] / contrib / file / ChangeLog
1 2011-03-30  15:45  Christos Zoulas <christos@zoulas.com>
2
3         * Fix cdf string buffer setting (Sven Anders)
4
5 2011-03-20  16:35  Christos Zoulas <christos@zoulas.com>
6
7         * Eliminate MAXPATHLEN and use dynamic allocation for
8           path and file buffers.
9
10 2011-03-15  18:15  Christos Zoulas <christos@zoulas.com>
11
12         * binary tests on magic entries with masks could spuriously
13           get converted to ascii.
14
15 2011-03-12  18:06  Reuben Thomas <rrt@sc3d.org>
16
17         * Improve file.man (remove BUGS, present email addresses consistently).
18
19 2011-03-07  19:38  Christos Zoulas <christos@zoulas.com>
20
21         * add lrzip support (from Ville Skytta)
22
23 2011-02-10  16:36  Christos Zoulas <christos@zoulas.com>
24
25         * fix CDF bounds checking (Guy Helmer)
26
27 2011-02-10  12:03  Christos Zoulas <christos@zoulas.com>
28
29         * add cdf_ctime() that prints a meaningful error when time cannot
30           be converted.
31
32 2011-02-02  20:40  Christos Zoulas <christos@zoulas.com>
33
34         * help and version output to stdout.
35
36         * When matching softmagic for ascii files, don't just print
37           the softmagic classification, keep going and print the
38           text classification too. This fixes broken troff files when
39           we moved them from keyword recognition to softmagic
40           (they stopped printing "with CRLF" etc.)
41           Reported by Doug McIlroy.
42
43 2011-01-16  19:31  Reuben Thomas <rrt@sc3d.org>
44
45         * Fix two potential buffer overruns in apprentice_list.
46
47 2011-01-14  22:33  Reuben Thomas <rrt@sc3d.org>
48
49         * New Python binding in pure Python.
50         * Update libmagic(3).
51
52 2011-01-06  21:40  Reuben Thomas <rrt@sc3d.org>
53
54         * Fix Python bindings (including recent Python 3 compatibility
55           update).
56
57 2011-01-04  18:43  Reuben Thomas <rrt@sc3d.org>
58
59         * magic/Makefile.am: make it easier to recover from magic build failures.
60         * Fix pstring length specifier parsing to avoid generating invalid
61           magic files.
62         * Add pstring length "J" (for "JPEG") to specify that the length
63           include itself.
64         * Fix JPEG comment parsing at last using pstring/HJ!
65         * Ignore section 5 man pages in doc/.cvsignore.
66
67 2010-12-22  13:12  Christos Zoulas <christos@zoulas.com>
68
69         * Add pstring/BHhLl to specify the type of the length of pascal
70           strings.
71
72 2010-11-26  18:39  Reuben Thomas <rrt@sc3d.org>
73
74         * Fix "-e soft": it was ignored when softmagic was called
75           during asciimagic.
76         * Improve comments and use "unsigned char" in tar.h/is_tar.c.
77
78 2010-11-05  17:26  Reuben Thomas <rrt@sc3d.org>
79
80         * Make bug reporting addresses more visible.
81
82 2010-11-01  18:35  Reuben Thomas <rrt@sc3d.org>
83
84         * Add tcl magic from Gustaf Neumann
85
86 2010-10-24  10:42  Christos Zoulas <christos@zoulas.com>
87
88         * Fix the whitespace comparing code (Christopher Chittleborough)
89
90 2010-10-06  21:05  Christos Zoulas <christos@zoulas.com>
91
92         * allow string/t to work (Jan Kaluza)
93
94 2010-09-20  22:11  Reuben Thomas <rrt@sc3d.org>
95
96         * Apply some patches from Ubuntu and Fedora.
97
98 2010-09-20  21:16  Reuben Thomas <rrt@sc3d.org>
99
100         * Apply all patches from Debian package 5.04-6 which have not
101           already been applied and are not Debian-specific.
102
103 2010-09-20  15:24  Reuben Thomas <rrt@sc3d.org>
104
105         * Minor security fix to softmagic.c (don't use untrusted
106           string as printf format).
107
108 2010-07-21  12:20  Christos Zoulas <christos@zoulas.com>
109
110         * MINGW32 portability from LRN
111
112         * Don't warn about escaping magic regex chars when we are in a regex.
113
114 2010-07-19  10:55  Christos Zoulas <christos@zoulas.com>
115
116         * Only try to print prpsinfo for core files. (Jan Kaluza)
117
118 2010-04-22  12:55  Christos Zoulas <christos@zoulas.com>
119
120         * Try more elf offsets for Debian core files.  (Arnaud Giersch)
121
122 2010-02-20  15:18  Reuben Thomas <rrt@sc3d.org>
123
124         * Clarify which sort of CDF we mean.
125
126 2010-02-14  22:58  Reuben Thomas <rrt@sc3d.org>
127
128         * Re-jig Zip file type magic so that unsupported special
129           Zip types (those with "mimetype" at offset 30) can be
130           recognized.
131
132 2010-02-02  21:50  Reuben Thomas <rrt@sc3d.org>
133
134         * Add support for OCF (EPUB) files (application/epub+zip)
135
136 2010-01-28  18:25  Christos Zoulas <christos@zoulas.com>
137
138         * Fix core-dump from unbound loop:
139           https://bugzilla.redhat.com/show_bug.cgi?id=533245
140
141 2010-01-22  15:45  Christos Zoulas <christos@zoulas.com>
142
143         * print proper mime for crystal reports file
144
145         * print the last summary information of a cdf document, not the
146           first so that nested documents print the right info
147
148 2010-01-16  18:42  Charles Longeau <chl@tuxfamily.org>
149
150         * bring back some fixes from OpenBSD:
151                 - make gcc2 builds file
152                 - fix typos in a magic file comment
153
154 2009-11-17  18:35  Christos Zoulas <christos@zoulas.com>
155
156         * ctime/asctime can return NULL on some OS's although
157           they should not (Toshit Antani)
158
159 2009-09-14  13:49  Christos Zoulas <christos@zoulas.com>
160
161         * Centralize magic path handling routines and remove the
162           special-casing from file.c so that the python module for
163           example comes up with the same magic path (Fixes ~/.magic
164           handling) (from Gab)
165
166 2009-09-11  23:38  Reuben Thomas <rrt@sc3d.org>
167
168         * When magic argument is a directory, read the files in
169           strcmp-sorted order (fixes Debian bug #488562 and our own FIXME).
170
171 2009-09-11  13:11  Reuben Thomas <rrt@sc3d.org>
172
173         * Combine overlapping epoc and psion magic files into one (epoc).
174
175         * Add some more EPOC MIME types.
176
177 2009-08-19  15:55  Christos Zoulas <christos@zoulas.com>
178
179         * Fix 3 bugs (From Ian Darwin):
180             - file_showstr could move one past the end of the array
181             - parse_apple did not nul terminate the string in the overflow case
182             - parse_mime truncated the wrong string in the overflow case
183
184 2009-08-12  12:28  Robert Byrnes  <byrnes@wildpumpkin.net>
185
186         * Include Localstuff when compiling magic.
187
188 2009-07-15  10:05  Christos Zoulas <christos@zoulas.com>
189
190         * Fix logic for including mygetopts.h
191
192         * Make cdf.c compile again with debugging
193
194         * Add the necessary field handling for crystal reports files to work
195
196 2009-06-23 01:34  Reuben Thomas <rrt@sc3d.org>
197
198         * Stop "(if" identifying Lisp files, that's plain dumb!
199
200 2009-06-09 22:13  Reuben Thomas <rrt@sc3d.org>
201
202         * Add a couple of missing MP3 MIME types.
203
204 2009-05-27 23:00  Reuben Thomas <rrt@sc3d.org>
205
206         * Add full range of hash-bang tests for Python and Ruby.
207
208         * Add MIME types for Python and Ruby scripts.
209
210 2009-05-13  10:44  Christos Zoulas <christos@zoulas.com>
211
212         * off by one in parsing hw capabilities in elf
213           (Cheng Renquan)
214
215 2009-05-08  13:40  Christos Zoulas <christos@zoulas.com>
216         
217         * lint fixes and more from NetBSD
218
219 2009-05-06  10:25  Christos Zoulas <christos@zoulas.com>
220
221         * Avoid null dereference in cdf code (Drew Yao)
222
223         * More cdf bounds checks and overflow checks
224
225 2009-05-01  18:37  Christos Zoulas <christos@zoulas.com>
226
227         * Buffer overflow fixes from Drew Yao
228
229 2009-04-30  17:10  Christos Zoulas <christos@zoulas.com>
230
231         * Fix more cdf lossage. All the documents I have
232           right now print the correct information.
233
234 2009-03-27  18:43  Christos Zoulas <christos@zoulas.com>
235
236         * don't print \012- separators in the same magic entry 
237           if it consists of multiple magic printing lines.
238
239 2009-03-23  10:20  Christos Zoulas <christos@zoulas.com>
240
241         * Avoid file descriptor leak in compress code from
242           (Daniel Novotny)
243
244 2009-03-18  16:50  Christos Zoulas <christos@zoulas.com>
245
246         * Allow escaping of relation characters, so that we can say \^[A-Z]
247           and the ^ is not eaten as a relation char.
248
249         * Fix troff and fortran to their previous glory using
250           regex. This was broken since their removel from ascmagic.
251
252 2009-03-10  16:50  Christos Zoulas <christos@zoulas.com>
253
254         * don't use strlen in strndup() (Toby Peterson)
255
256 2009-03-10  7:45  Christos Zoulas <christos@zoulas.com>
257
258         * avoid c99 syntax.
259
260 2009-02-23 15:45  Christos Zoulas <christos@zoulas.com>
261
262         * make the cdf code use the buffer first if available,
263           and then the fd code.
264
265 2009-02-13 13:45  Christos Zoulas <christos@zoulas.com>
266
267         * look for struct option to determine if getopt.h is usable for IRIX.
268
269         * sanitize cdf document strings
270
271 2009-02-04 13:25  Christos Zoulas <christos@zoulas.com>
272
273         * fix OS/2 warnings.
274
275 2008-12-12 15:50  Christos Zoulas <christos@zoulas.com>
276
277         * fix initial offset calculation for non 4K sector files
278
279         * add loop limits to avoid DoS attacks by constructing
280           looping sector references.
281
282 2008-12-03 13:05  Christos Zoulas <christos@zoulas.com>
283
284         * fix memory botches on cdf file parsing.
285
286         * exit with non-zero value for any error, not just for the last
287           file processed.
288
289 2008-11-09 20:42  Charles Longeau <chl@tuxfamily.org>
290
291         * Replace all str{cpy,cat} functions with strl{cpy,cat}
292         * Ensure that strl{cpy,cat} are included in libmagic,
293           as needed.
294
295 2008-11-06 18:18  Christos Zoulas <christos@zoulas.com>
296
297         * Handle ID3 format files.
298
299 2008-11-06 23:00  Reuben Thomas <rrt@sc3d.org>
300
301         * Fix --mime, --mime-type and --mime-encoding under new scheme.
302
303         * Rename "ascii" to "text" and add "encoding" test.
304
305         * Return a precise ("utf-16le" or "utf-16be") MIME charset for
306           UTF-16.
307
308         * Fix error in comment caused by automatic indentation adding
309           words!
310
311 2008-11-06 10:35  Christos Zoulas <christos@astron.com>
312
313         * use memchr instead of strchr because the string
314           might not be NUL terminated (Scott MacVicar)
315
316 2008-11-03 07:31  Reuben Thomas <rrt@sc3d.org>
317
318         * Fix a printf with a non-literal format string.
319
320         * Fix formatting and punctuation of help for "--apple".
321
322 2008-10-30 11:00  Reuben Thomas <rrt@sc3d.org>
323
324         * Correct words counts in comments of struct magic.
325
326         * Fix handle_annotation to allow both Apple and MIME types to be
327           printed, and to return correct code if MIME type is
328           printed (1, not 0) or if there's an error (-1 not 1).
329
330         * Fix output of charset for MIME type (precede with semi-colon;
331           fixes Debian bug #501460).
332
333         * Fix potential attacks via conversion specifications in magic
334           strings.
335
336         * Add a FIXME for Debian bug #488562 (magic files should be
337           read in a defined order, by sorting the names).
338
339 2008-10-18 16:45  Christos Zoulas <christos@astron.com>
340
341         * Added APPLE file creator/type
342
343 2008-10-12 10:20  Christos Zoulas <christos@astron.com>
344
345         * Added CDF parsing
346
347 2008-10-09 16:40  Christos Zoulas <christos@astron.com>
348
349         * filesystem and msdos patches (Joerg Jenderek)
350
351 2008-10-09 13:20  Christos Zoulas <christos@astron.com>
352
353         * correct --exclude documentation issues: remove troff and fortran
354           and rename "token" to "tokens". (Randy McMurchy)
355
356 2008-10-01 10:30  Christos Zoulas <christos@astron.com>
357
358         * Read ~/.magic in addition to the default magic file not instead
359           of, as documented in the man page.
360
361 2008-09-10 21:30  Reuben Thomas  <rrt@sc3d.org>
362
363         * Comment out graphviz patterns, as they match too many files.
364
365 2008-08-30 12:54  Christos Zoulas <christos@astron.com>
366
367         * Don't eat trailing \n in magic enties.
368
369         * Cast defines to allow compilation using a c++ compiler.
370
371 2008-08-25 23:56  Reuben Thomas  <rrt@sc3d.org>
372
373         * Add text/x-lua MIME type for Lua scripts.
374
375         * Escape { in regex in graphviz patterns.
376
377 2008-07-26 00:59  Reuben Thomas  <rrt@sc3d.org>
378
379         * Add MIME types for special files.
380
381         * Use access to give more accurate information for files that
382           can't be opened.
383
384         * Add a TODO list.
385
386 2008-07-02 11:15  Christos Zoulas  <christos@astron.com>
387
388         * add !:strength op to adjust magic strength (experimental)
389
390 2008-06-16 21:41  Reuben Thomas  <rrt@sc3d.org>
391
392         * Fix automake error in configure.ac.
393
394         * Add MIME type for Psion Sketch files.
395
396 2008-06-05 08:59  Christos Zoulas  <christos@astron.com>
397
398         * Don't print warnings about bad namesize in stripped
399           binaries with PT_NOTE is still there, and the actual
400           note is gone (Jakub Jelinek)
401
402 2008-05-28 15:12  Robert Byrnes  <byrnes@wildpumpkin.net>
403
404         * magic/Magdir/elf:
405           Note invalid byte order for little-endian SPARC32PLUS.
406           Add SPARC V9 vendor extensions and memory model.
407
408         * src/elfclass.h:
409           Pass target machine to doshn (for Solaris hardware capabilities).
410
411         * src/readelf.c (doshn):
412           Add support for Solaris hardware/software capabilities.
413
414         * src/readelf.h:
415           Ditto.
416
417         * src/vasprintf.c (dispatch):
418           Add support for ll modifier.
419
420 2008-05-16 10:25  Christos Zoulas  <christos@astron.com>
421
422         * Fix compiler warnings.
423
424         * remove stray printf, and fix a vprintf bug. (Martin Dorey)
425
426 2008-05-06 00:13  Robert Byrnes  <byrnes@wildpumpkin.net>
427
428         * src/Makefile.am:
429           Ensure that getopt_long and [v]asprintf are included in libmagic,
430           as needed.
431
432           Remove unnecessary EXTRA_DIST.
433
434         * src/Makefile.in:
435           Rerun automake.
436
437         * src/vasprintf.c (dispatch):
438           Fix variable precision bug: be sure to step past '*'.
439
440         * src/vasprintf.c (core):
441           Remove unreachable code.
442
443         * src/apprentice.c (set_test_type):
444           Add cast to avoid compiler warning.
445
446 2008-04-22 23:45  Christos Zoulas  <christos@astron.com>
447
448         * Add magic submission guidelines (Abel Cheung)
449
450         * split msdos and windows magic (Abel Cheung)
451
452 2008-04-04 11:00  Christos Zoulas  <christos@astron.com>
453
454         * >= <= is not supported, so fix the magic and warn about it.
455           reported by: Thien-Thi Nguyen <ttn@gnuvola.org>
456
457 2008-03-27 16:16  Robert Byrnes  <byrnes@wildpumpkin.net>
458
459         * src/readelf.c (donote):
460           ELF core file command name/line bug fixes and enhancements:
461
462           Try larger offsets first to avoid false matches
463           from earlier data that happen to look like strings;
464           this primarily affected SunOS 5.x 32-bit Intel core files.
465
466           Add support for command line (instead of just short name)
467           for SunOS 5.x.
468
469           Add information about NT_PSINFO for SunOS 5.x.
470
471           Only trim whitespace from end of command line.
472
473 2007-02-11 01:36 Reuben Thomas <rrt@sc3d.org>
474
475         * Change strength of ! from MULT to 0, as it matches almost
476                   anything (Reuben Thomas)
477
478         * Debian fixes (Reuben Thomas)
479
480 2007-02-11 00:17 Reuben Thomas <rrt@sc3d.org>
481
482         * Clarify UTF-8 BOM message (Reuben Thomas)
483
484         * Add HTML comment to token list in names.h
485
486 2007-02-04 15:50 Christos Zoulas <christos@astron.com>
487
488         * Debian fixes (Reuben Thomas)
489
490 2007-02-04 11:31 Christos Zoulas <christos@astron.com>
491
492         * !:mime annotations in magic files (Reuben Thomas)
493
494 2007-01-29 15:35 Christos Zoulas <christos@astron.com>
495
496         * zero out utime/utimes structs (Gavin Atkinson)
497
498 2007-01-26 13:45 Christos Zoulas <christos@astron.com>
499
500         * reduce writable data from Diego "Flameeyes" Petten
501
502 2007-12-28 15:06 Christos Zoulas <christos@astron.com>
503
504         * strtof detection
505
506         * remove bogus regex magic that could cause a DoS
507
508         * better mismatch version message
509
510 2007-12-27 11:35 Christos Zoulas <christos@astron.com>
511
512         * bring back some fixes from OpenBSD
513
514         * treat ELF dynamic objects as executables
515
516         * fix gcc warnings
517
518 2007-12-01 19:55 Christos Zoulas <christos@astron.com>
519
520         * make sure we have zlib.h and libz to compile the builtin
521           decompress code
522
523 2007-10-28 20:48 Christos Zoulas <christos@astron.com>
524
525         * float and double magic support (Behan Webster)
526
527 2007-10-28 20:48 Christos Zoulas <christos@astron.com>
528
529         * Convert fortran to a soft test (Reuben Thomas)
530
531 2007-10-23  5:25 Christos Zoulas <christos@astron.com>
532
533         * Add --with-filename, and --no-filename (Reuben Thomas)
534
535 2007-10-23  3:59 Christos Zoulas <christos@astron.com>
536
537         * Rest of the mime split (Reuben Thomas)
538
539         * Make usage message generated from the flags so that
540           they stay consistent (Reuben Thomas)
541
542 2007-10-20  3:06 Christos Zoulas <christos@astron.com>
543
544         * typo in comment, missing ifdef QUICK, remove unneeded code
545                 (Charles Longeau)
546
547 2007-10-17  3:33 Christos Zoulas <christos@astron.com>
548
549         * Fix problem printing -\012 in some entries
550
551         * Separate magic type and encoding flags (Reuben Thomas)
552
553 2007-10-09  3:55 Christos Zoulas <christos@astron.com>
554
555         * configure fix for int64 and strndup (Reuben Thomas)
556
557 2007-09-26  4:45 Christos Zoulas <christos@astron.com>
558
559         * Add magic_descriptor() function.
560
561         * Fix regression in elf reading code where the core name was
562           not being printed.
563
564         * Don't convert NUL's to spaces in {l,b}estring16 (Daniel Dawson)
565
566 2007-08-19  6:30 Christos Zoulas <christos@astron.com>
567
568         * Make mime format consistent so that it can
569           be easily parsed:
570               mimetype [charset=character-set] [encoding=encoding-mime-type]
571
572           Remove spurious extra text from some MIME type printouts
573           (mostly in is_tar).
574
575           Fix one case where -i produced nothing at all (for a 1-byte file,
576           which is now classed as application/octet-stream).
577
578           Remove 7/8bit classifications, since they were arbitrary
579           and not based on the file data.
580
581           This work was done by Reuben Thomas
582
583 2007-05-24 10:00 Christos Zoulas <christos@astron.com>
584
585         * Fix another integer overflow (Colin Percival)
586
587 2007-03-26 13:58 Christos Zoulas <christos@astron.com>
588
589         * make sure that all of struct magic_set is initialized appropriately
590           (Brett)
591
592 2007-03-25 17:44 Christos Zoulas <christos@astron.com>
593
594         * reset left bytes in the buffer (Dmitry V. Levin)
595
596         * compilation failed with COMPILE_ONLY and ENABLE_CONDITIONALS
597           (Peter Avalos)
598
599 2007-03-15 10:51 Christos Zoulas <christos@astron.com>
600
601         * fix fortran and nroff reversed tests (Dmitry V. Levin)
602
603         * fix exclude option (Dmitry V. Levin)
604
605 2007-02-08 17:30 Christos Zoulas <christos@astron.com>
606
607         * fix integer underflow in file_printf which can lead to
608           to exploitable heap overflow (Jean-Sebastien Guay-Lero)
609
610 2007-02-05 11:35 Christos Zoulas <christos@astron.com>
611
612         * make socket/pipe reading more robust
613
614 2007-01-25 16:01 Christos Zoulas <christos@astron.com>
615
616         * Centralize all the tests in file_buffer.
617
618         * Add exclude flag.
619
620 2007-01-18 05:29 Anon Ymous <do@not.spam.me>
621
622         * Move the "type" detection code from parse() into its own table
623           driven routine.  This avoids maintaining multiple lists in
624           file.h.
625
626         * Add an optional conditional field (ust before the type field).
627           This code is wrapped in "#ifdef ENABLE_CONDITIONALS" as it is
628           likely to go away.
629
630 2007-01-16 23:24 Anon Ymous <do@not.spam.me>
631
632         * Fix an initialization bug in check_mem().
633
634 2007-01-16 14:58 Anon Ymous <do@not.spam.me>
635
636         * Add a "default" type to print a message if nothing previously
637           matched at that level or since the last default at that
638           level.  This is useful for setting up switch-like statements.
639           It can also be used to do if/else constructions without a
640           redundant second test.
641
642         * Fix the "x" special case test so that one can test for that
643           string with "=x".
644
645         * Allow "search" to search the entire buffer if the "/N"
646           search count is missing.
647
648         * Make "regex" work!  It now starts its search at the
649           specified offset and takes an (optional) "/N" line count to
650           specify the search range; otherwise it searches to the end
651           of the file.  The match is now grabbed correctly for format
652           strings and the offset set to the end of the match.
653
654         * Add a "/s" flag to "regex" and "search" to set the offset to
655           the start of the match.  By default the offset is set to the
656           end of the match, as it is with other tests.  This is mostly
657           useful for "regex".
658
659         * Make "search", "string" and "pstring" use the same
660           file_strncmp() routine so that they support the same flags;
661           "bestring16" and "lestring16" call the same routine, but
662           with flags = 0.  Also add a "/C" flag (in analogy to "/c")
663           to ignore the case on uppercase (lowercase) characters in
664           the test string.
665
666         * Strict adherence to C style string escapes.  A warnings are
667           printed when compiling.  Note: previously "\a" was
668           incorrectly translated to 'a' instead of an <alert> (i.e.,
669           BELL, typically 0x07).
670
671         * Make this compile with "-Wall -Wextra" and all the warning
672           flags used with WARNS=4 in the NetBSD source.  Also make it
673           pass lint.
674
675         * Many "cleanups" and hopefully not too many new bugs!
676
677 2007-01-16 14:56 Anon Ymous <do@not.spam.me>
678
679         * make several more files compile with gcc warnings
680           on and also make them pass lint.
681
682 2007-01-16 14:54 Anon Ymous <do@not.spam.me>
683
684         * fix a puts()/putc() usage goof in file.c
685
686         * make file.c compile with gcc warnings and pass lint
687
688 2006-12-11 16:49 Christos Zoulas <christos@astron.com>
689
690         * fix byteswapping issue
691
692         * report the number of bytes we tried to
693           allocate when allocation fails
694
695         * add a few missed cases in the strength routine
696
697 2006-12-08 16:32 Christos Zoulas <christos@astron.com>
698
699         * store and print the line number of the magic
700           entry for debugging.
701
702         * if the magic entry did not print anything,
703           don't treat it as a match
704
705         * change the magic strength algorithm to take
706           into account the relationship op.
707
708         * fix a bug in search where we could accidentally
709           return a match.
710
711         * propagate the error return from match to
712           file_softmagic.
713
714 2006-11-25 13:35 Christos Zoulas <christos@astron.com>
715
716         * Don't store the current offset in the magic
717           struct, because it needs to be restored and
718           it was not done properly all the time. Bug
719           found by: Arkadiusz Miskiewicz
720
721         * Fix problem in the '\0' separator; and don't
722           print it as an additional separator; print
723           it as the only separator.
724
725 2006-11-17 10:51 Christos Zoulas <christos@astron.com>
726
727         * Added a -0 option to print a '\0' separator
728           Etienne Buira <etienne.buira@free.fr>
729
730 2006-10-31 15:14 Christos Zoulas <christos@astron.com>
731
732         * Check offset before copying (Mike Frysinger)
733
734         * merge duplicated code
735
736         * add quad date support
737
738         * make sure that we nul terminate desc (Ryoji Kanai)
739
740         * don't process elf notes multiple times
741
742         * allow -z to report empty compressed files
743
744         * use calloc to initialize the ascii buffers (Jos van den Oever)
745
746 2006-06-08 11:11 Christos Zoulas <christos@astron.com>
747
748         * QNX fixes (Mike Gorchak)
749
750         * Add quad support.
751
752         * FIFO checks (Dr. Werner Fink)
753
754         * Linux ELF fixes (Dr. Werner Fink)
755
756         * Magic format checks (Dr. Werner Fink)
757
758         * Magic format function improvent (Karl Chen)
759
760 2006-05-03 11:11 Christos Zoulas <christos@astron.com>
761
762         * Pick up some elf changes and some constant fixes from SUSE
763
764         * Identify gnu tar vs. posix tar
765
766         * When keep going, don't print spurious newlines (Radek Vokál)
767
768 2006-04-01 12:02 Christos Zoulas <christos@astron.com>
769
770         * Use calloc instead of malloc (Mike Frysinger)
771
772         * Fix configure script to detect wctypes.h (Mike Frysinger)
773
774 2006-03-02 16:06 Christos Zoulas <christos@astron.com>
775
776         * Print empty if the file is (Mike Frysinger)
777
778         * Don't try to read past the end of the buffer (Mike Frysinger)
779
780         * Sort magic entries by strength [experimental]
781
782 2005-11-29 13:26 Christos Zoulas <christos@astron.com>
783
784         * Use iswprint() to convert the output string.
785             (Bastien Nocera)
786
787 2005-10-31 8:54 Christos Zoulas <christos@astron.com>
788
789         * Fix regression where the core info was not completely processed
790             (Radek Vokál)
791
792 2005-10-20 11:15 Christos Zoulas <christos@astron.com>
793
794         * Middle Endian magic (Diomidis Spinellis)
795
796 2005-10-17 11:15 Christos Zoulas <christos@astron.com>
797
798         * Open with O_BINARY for CYGWIN (Corinna Vinschen)
799
800         * Don't close stdin (Arkadiusz Miskiewicz)
801
802         * Look for note sections in non executables.
803
804 2005-09-20 13:33 Christos Zoulas <christos@astron.com>
805
806         * Don't print SVR4 Style in core files multiple times
807             (Radek Vokál)
808
809 2005-08-27 04:09 Christos Zoulas <christos@astron.com>
810
811         * Cygwin changes Corinna Vinschen
812
813 2005-08-18 09:53 Christos Zoulas <christos@astron.com>
814
815         * Remove erroreous mention of /etc/magic in the file man page
816           This is gentoo bug 101639. (Mike Frysinger)
817
818         * Cross-compile support and detection (Mike Frysinger)
819
820 2005-08-12 10:17 Christos Zoulas <christos@astron.com>
821
822         * Add -h flag and dereference symlinks if POSIXLY_CORRECT
823           is set.
824
825 2005-07-29 13:57 Christos Zoulas <christos@astron.com>
826
827         * Avoid search and regex buffer overflows (Kelledin)
828
829 2005-07-12 11:48 Christos Zoulas <christos@astron.com>
830
831         * Provide stub implementations for {v,}nsprintf() for older
832           OS's that don't have them.
833         * Change mbstate_t autoconf detection macro from AC_MBSTATE_T
834           to AC_TYPE_MBSTATE_T.
835
836 2005-06-25 11:48 Christos Zoulas <christos@astron.com>
837
838         * Dynamically allocate the string buffers and make the
839           default read size 256K.
840
841 2005-06-01 00:00 Joerg Sonnenberger <joerg@britannica.bec.de>
842
843         * Dragonfly ELF note support
844
845 2005-03-14 00:00 Giuliano Bertoletti <gb@symbolic.it>
846
847         * Avoid NULL pointer dereference in time conversion.
848
849 2005-03-06 00:00  Joerg Walter <jwalt@mail.garni.ch>
850
851         * Add indirect magic offset support, and search mode.
852
853 2005-01-12 00:00  Stepan Kasal  <kasal@ucw.cz>
854
855         * src/ascmagic.c (file_ascmagic): Fix three bugs about text files:
856           If a CRLF text file happens to have CR at offset HOWMANY - 1
857           (currently 0xffff), it should not be counted as CR line
858           terminator.
859           If a line has length exactly MAXLINELEN, it should not yet be
860           treated as a ``very long line'', as MAXLINELEN is ``longest sane
861           line length''.
862           With CRLF, the line length was not computed correctly, and even
863           lines of length MAXLINELEN - 1 were treated as ``very long''.
864
865 2004-12-07 14:15  Christos Zoulas  <christos@astron.com>
866
867         * bzip2 needs a lot of input buffer space on some files
868           before it can begin uncompressing. This makes file -z
869           fail on some bz2 files. Fix it by giving it a copy of
870           the file descriptor to read as much as it wants if we
871           have access to it. <christos@astron.com>
872
873 2004-11-24 12:39  Christos Zoulas  <christos@astron.com>
874
875         * Stack smash fix, and ELF more conservative reading.
876           Jakub Bogusz <qboosh@pld-linux.org>
877
878 2004-11-20 18:50  Christos Zoulas  <christos@astron.com>
879
880         * New FreeBSD version parsing code:
881           Jon Noack <noackjr@alumni.rice.edu>
882
883         * Hackish support for ucs16 strings <christos@astron.com>
884
885 2004-11-13 03:07  Christos Zoulas  <christos@astron.com>
886
887         * print the file name and line number in syntax errors.
888
889 2004 10-12 10:50  Christos Zoulas  <christos@astron.com>
890
891         * Fix stack overwriting on 0 length strings: Tim Waugh
892             <twaugh@redhat.com> Ned Ludd <solar@gentoo.org>
893
894 2004-09-27 11:30  Christos Zoulas  <christos@astron.com>
895
896         * Remove 3rd and 4th copyright clause; approved by Ian Darwin.
897
898         * Fix small memory leaks; caught by: Tamas Sarlos
899             <stamas@csillag.ilab.sztaki.hu>
900
901 2004-07-24 16:33  Christos Zoulas  <christos@astron.com>
902
903         * magic.mime update Danny Milosavljevic <danny.milo@gmx.net>
904
905         * FreeBSD version update Oliver Eikemeier <eikemeier@fillmore-labs.com>
906
907         * utime/utimes detection Ian Lance Taylor <ian@wasabisystems.com>
908
909         * errors reading elf magic Jakub Bogusz <qboosh@pld-linux.org>
910
911 2004-04-12 10:55  Christos Zoulas  <christos@astron.com>
912
913         * make sure that magic formats match magic types during compilation
914
915         * fix broken sgi magic file
916
917 2004-04-06 20:36  Christos Zoulas  <christos@astron.com>
918
919         * detect present of mbstate_t Petter Reinholdtsen <pere@hungry.com>
920
921         * magic fixes
922
923 2004-03-22 15:25  Christos Zoulas  <christos@astron.com>
924
925         * Lots of mime fixes
926           (Joerg Ostertag) <ostertag@rechengilde.de>
927
928         * FreeBSD ELF version handling
929           (Edwin Groothuis) <edwin@mavetju.org>
930
931         * correct cleanup in all cases; don't just close the file.
932           (Christos Zoulas) <christos@astron.com>
933
934         * add gettext message catalogue support
935           (Michael Piefel) <piefel@debian.org>
936
937         * better printout for unreadable files
938           (Michael Piefel) <piefel@debian.org>
939
940         * compensate for missing MAXPATHLEN
941           (Michael Piefel) <piefel@debian.org>
942
943         * add wide character string length computation
944           (Michael Piefel) <piefel@debian.org>
945
946         * Avoid infinite loops caused by bad elf alignments
947           or name and description note sizes. Reported by
948           (Mikael Magnusson) <mmikael@comhem.se>
949
950 2004-03-09 13:55  Christos Zoulas  <christos@astron.com>
951
952         * Fix possible memory leak on error and add missing regfree
953           (Dmitry V. Levin) <ldv@altlinux.org>
954
955 2003-12-23 12:12  Christos Zoulas  <christos@astron.com>
956
957         * fix -k flag (Maciej W. Rozycki)
958
959 2003-11-18 14:10  Christos Zoulas  <christos@astron.com>
960
961         * Try to give us much info as possible on corrupt elf files.
962           (Willy Tarreau) <willy@w.ods.org>
963         * Updated python bindings (Brett Funderburg)
964            <brettf@deepfile.com>
965
966 2003-11-11 15:03  Christos Zoulas  <christos@astron.com>
967
968         * Include file.h first, because it includes config.h
969           breaks largefile test macros otherwise.
970           (Paul Eggert <eggert@CS.UCLA.EDU> via
971            Lars Hecking <lhecking@nmrc.ie>)
972
973 2003-10-14 21:39  Christos Zoulas  <christos@astron.com>
974
975         * Python bindings (Brett Funderburg) <brettf@deepfile.com>
976         * Don't lookup past the end of the buffer
977           (Chad Hanson) <chanson@tcs-sec.com>
978         * Add MAGIC_ERROR and api on magic_errno()
979
980 2003-10-08 12:40  Christos Zoulas  <christos@astron.com>
981
982         * handle error conditions from compile as fatal
983           (Antti Kantee) <pooka@netbsd.org>
984         * handle magic filename parsing sanely
985         * more magic fixes.
986         * fix a memory leak (Illes Marton) <illes.marton@balabit.hu>
987         * describe magic file handling
988           (Bryan Henderson) <bryanh@giraffe-data.com>
989
990 2003-09-12 15:09  Christos Zoulas  <christos@astron.com>
991
992         * update magic files.
993         * remove largefile support from file.h; it breaks things on most OS's
994
995 2003-08-10 10:25  Christos Zoulas  <christos@astron.com>
996
997         * fix unmapping'ing of mmaped files.
998
999 2003-07-10 12:03  Christos Zoulas  <christos@astron.com>
1000
1001         * don't exit with -1 on error; always exit 1 (Marty Leisner)
1002         * restore utimes code.
1003
1004 2003-06-10 17:03  Christos Zoulas  <christos@astron.com>
1005
1006         * make sure we don't access uninitialized memory.
1007         * pass lint
1008         * #ifdef __cplusplus in magic.h
1009
1010 2003-05-25 19:23  Christos Zoulas  <christos@astron.com>
1011
1012         * rename cvs magic file to revision to deal with
1013           case insensitive filesystems.
1014
1015 2003-05-23 17:03  Christos Zoulas  <christos@astron.com>
1016
1017         * documentation fixes from Michael Piefel <piefel@debian.org>
1018         * magic fixes (various)
1019         * revert basename magic in .mgc name determination
1020         * buffer protection in uncompress,
1021           signness issues,
1022           close files
1023           Maciej W. Rozycki <macro@ds2.pg.gda.pl
1024
1025 2003-04-21 20:12  Christos Zoulas  <christos@astron.com>
1026
1027         * fix zsh magic
1028
1029 2003-04-04 16:59  Christos Zoulas  <christos@astron.com>
1030
1031         * fix operand sort order in string.
1032
1033 2003-04-02 17:30  Christos Zoulas  <christos@astron.com>
1034
1035         * cleanup namespace in magic.h
1036
1037 2003-04-02 13:50  Christos Zoulas  <christos@astron.com>
1038
1039         * Magic additions (Alex Ott)
1040         * Fix bug that broke VPATH compilation (Peter Breitenlohner)
1041
1042 2003-03-28 16:03  Christos Zoulas  <christos@astron.com>
1043
1044         * remove packed attribute from magic struct.
1045         * make the magic struct properly aligned.
1046         * bump version number of compiled files to 2.
1047
1048 2003-03-27 13:10  Christos Zoulas  <christos@astron.com>
1049
1050         * separate tar detection and run it before softmagic.
1051         * fix reversed symlink test.
1052         * fix version printing.
1053         * make separator a string instead of a char.
1054         * update manual page and sort options.
1055
1056 2003-03-26 11:00  Christos Zoulas  <christos@astron.com>
1057
1058         * Pass lint
1059         * make NULL in magic_file mean stdin
1060         * Fix "-" argument to file to pass NULL to magic_file
1061         * avoid pointer casts by using memcpy
1062         * rename magic_buf -> magic_buffer
1063         * keep only the first error
1064         * manual page: new sentence, new line
1065         * fix typo in api function (magic_buf -> magic_buffer)