1 2022-09-13 14:55 Christos Zoulas <christos@zoulas.com>
5 2022-09-10 9:17 Christos Zoulas <christos@zoulas.com>
7 * Add octal indirect magic (Michal Gorny)
9 2022-08-17 11:43 Christos Zoulas <christos@zoulas.com>
11 * PR/374: avoid infinite loop in non-wide code (piru)
12 * PR/373: Obey MAGIC_CONTINUE with multiple magic files (vismarli)
14 2022-07-26 11:10 Christos Zoulas <christos@zoulas.com>
16 * Fix bug with large flist (Florian Weimer)
18 2022-07-07 13:21 Christos Zoulas <christos@zoulas.com>
20 * PR/364: Detect non-nul-terminated core filenames from QEMU
23 2022-07-04 15:45 Christos Zoulas <christos@zoulas.com>
25 * PR/359: Add support for http://ndjson.org/ (darose)
26 * PR/362: Fix wide printing (ro-ee)
27 * PR/358: Fix width for -f - (jpalus)
28 * PR/356: Fix JSON constant parsing (davewhite)
30 2022-06-10 9:40 Christos Zoulas <christos@zoulas.com>
34 2022-05-31 14:50 Christos Zoulas <christos@zoulas.com>
36 * PR/348: add missing cases to prevent file from aborting on
39 2022-05-27 21:05 Christos Zoulas <christos@zoulas.com>
41 * PR/351: octalify filenames when not raw before printing.
43 2022-04-18 17:51 Christos Zoulas <christos@zoulas.com>
45 * fix regex cacheing bug (Dirk Mueller)
46 * merge file_regcomp and file_regerror() to simplify the code
47 and reduce memory requirements for storing regexes (Dirk Mueller)
49 2022-03-19 12:56 Christos Zoulas <christos@zoulas.com>
51 * cache regex (Dirk Mueller)
52 * detect filesystem full by flushing output (Dirk Mueller)
54 2021-11-19 12:36 Christos Zoulas <christos@zoulas.com>
56 * implement running decompressor programs using
57 posix_spawnp(2) instead of vfork(2)
59 2021-10-24 11:51 Christos Zoulas <christos@zoulas.com>
61 * Add support for msdos dates and times
63 2021-10-20 9:55 Christos Zoulas <christos@zoulas.com>
65 * use the system byte swapping functions if available (Werner Fink)
67 2021-10-18 11:57 Christos Zoulas <christos@zoulas.com>
71 2021-09-23 03:51 Christos Zoulas <christos@zoulas.com>
73 * Avinash Sonawane: Fix tzname detection
75 2021-09-03 09:17 Christos Zoulas <christos@zoulas.com>
77 * Fix relationship tests with "search" magic, don't short circuit
80 2021-07-13 01:06 Christos Zoulas <christos@zoulas.com>
82 * Fix memory leak in compile mode
84 2021-07-01 03:51 Christos Zoulas <christos@zoulas.com>
86 * PR/272: kiefermat: Only set returnval = 1 when we printed something
87 (in all cases print or !print). This simplifies the logic and fixes
88 the issue in the PR with -k and --mime-type there was no continuation
89 printed before the default case.
91 2021-06-30 13:07 Christos Zoulas <christos@zoulas.com>
93 * PR/270: Don't translate unprintable characters in %s magic formats
95 * PR/269: Avoid undefined behavior with clang (adding offset to NULL)
97 2021-05-09 18:38 Christos Zoulas <christos@zoulas.com>
99 * Add a new flag (f) that requires that the match is a full word,
100 not a partial word match.
101 * Add varint types (unused)
103 2021-04-19 17:17 Christos Zoulas <christos@zoulas.com>
105 * PR/256: mutableVoid: If the file is less than 3 bytes, use the file
106 length to determine type
107 * PR/259: aleksandr.v.novichkov: mime printing through indirect magic
108 is not taken into account, use match directly so that it does.
110 2021-04-04 17:02 Christos Zoulas <christos@zoulas.com>
112 * count the total bytes found not the total byte positions
113 in order to determine encoding (Anatol Belski)
115 2021-03-30 20:21 Christos Zoulas <christos@zoulas.com>
119 2021-02-05 16:31 Christos Zoulas <christos@zoulas.com>
121 * PR/234: Add limit to the number of bytes to scan for encoding
122 * PR/230: Fix /T (trim flag) for regex
124 2021-02-01 12:31 Christos Zoulas <christos@zoulas.com>
125 * PR/77: Trim trailing separator.
127 2020-12-17 15:44 Christos Zoulas <christos@zoulas.com>
129 * PR/211: Convert system read errors from corrupt ELF
130 files into human readable error messages
132 2020-12-08 16:24 Christos Zoulas <christos@zoulas.com>
134 * fix multithreaded decompression file descriptor issue
135 by using close-on-exec (Denys Vlasenko)
137 2020-06-27 11:58 Christos Zoulas <christos@zoulas.com>
139 * Exclude surrogate pairs from utf-8 detection (Michael Liu)
141 2020-06-25 12:53 Christos Zoulas <christos@zoulas.com>
143 * Include # to the list of ignored format chars (Werner Fink)
145 2020-06-14 20:02 Christos Zoulas <christos@zoulas.com>
149 2020-06-07 20:00 Christos Zoulas <christos@zoulas.com>
151 * Remove unused subtype_mime (Steve Grubb)
152 * Remove unused check in okstat (Steve Grubb)
153 * Fix mime-type in elf binaries by making sure $x is set
154 * Fix indirect negative offsets broken by OFFNEGATIVE
155 * Fix GUID equality check
156 * PR/165: Handle empty array and strings in JSON
157 * PR/162: Add --exclude-quiet
159 2020-06-06 15:33 Christos Zoulas <christos@zoulas.com>
161 * Fix memory leak in ascmagic (Steve Grubb)
163 2020-06-04 00:21 Christos Zoulas <christos@zoulas.com>
165 * Fix string comparison length with ignore whitespace
167 2020-05-31 00:11 Christos Zoulas <christos@zoulas.com>
169 * Fix mingwin 64 compilation
171 2020-05-30 23:56 Christos Zoulas <christos@zoulas.com>
173 * PR/159: whitelist getpid needed for file_pipe2file()
175 2020-05-09 18:57 Christos Zoulas <christos@zoulas.com>
177 * Indicate negative offsets with a flag OFFNEGATIVE
179 * Introduce "offset" magic type that can be used to
180 detect the file size, and bail on short files.
181 * document DER better in the magic man page.
183 2020-03-11 21:53 Christos Zoulas <christos@zoulas.com>
185 * fix memory leaks (SonarQube)
187 2020-03-08 21:33 Christos Zoulas <christos@zoulas.com>
189 * fix memory leaks (SonarQube)
190 * rewrite confusing loops (SonarQube)
191 * fix bogus test (SonarQube)
192 * pass a sized buffer to file_fmttime() (SonarQube)
194 * fix memory leaks (SonarQube)
196 2020-02-20 15:50 Christos Zoulas <christos@zoulas.com>
198 * Don't allow * in printf formats, or the code itself (Christoph Biedl)
199 * Introduce a printf output size checker to avoid DoS attacks
201 2020-02-17 17:22 Christos Zoulas <christos@zoulas.com>
203 * Avoid memory leak on error (oss-fuzz)
204 * Check length of string on DER before derefercing and add new types
205 * Add missing DER string (oss-fuzz)
207 2020-02-16 20:45 Christos Zoulas <christos@zoulas.com>
209 * Add missing DER types, and debugging
211 2020-02-13 13:10 Christos Zoulas <christos@zoulas.com>
213 * PR/140: Avoid abort with hand-crafted magic file (gockelhahn)
214 * PR/139 Avoid DoS in printf with hand-crafted magic file (gockelhahn)
215 * PR/138: Avoid crash with hand-crafted magic file (gockelhahn)
217 2020-02-12 17:30 Christos Zoulas <christos@zoulas.com>
219 * PR/136: Fix static build by adding a libmagic.pc (Fabrice Fontaine)
221 2019-12-24 14:16 Christos Zoulas <christos@zoulas.com>
225 2019-12-16 21:11 Christos Zoulas <christos@zoulas.com>
229 2019-12-15 22:13 Christos Zoulas <christos@zoulas.com>
230 Document changes since the previous release:
231 - Always accept -S (no sandbox) even if we don't support sandboxing
232 - More syscalls elided for sandboxiing
233 - For ELF dynamic means having an interpreter not just PT_DYNAMIC
234 - Check for large ELF session header offset
235 - When saving and restoring a locale, keep the locale name in our
237 - Add a flag to disable CSV file detection.
238 - Don't pass NULL/0 to memset to appease sanitizers.
239 - Avoid spurious prints when looks for extensions or apple strings
241 - Add builtin decompressors for xz and and bzip.
242 - Add a limit for the number of CDF elements.
243 - More checks for overflow in CDF.
245 2019-05-14 22:26 Christos Zoulas <christos@zoulas.com>
249 2019-05-09 22:27 Christos Zoulas <christos@zoulas.com>
251 * Make sure that continuation separators are printed
252 with -k within softmagic
254 2019-05-06 22:27 Christos Zoulas <christos@zoulas.com>
256 * Change SIGPIPE saving and restoring during compression to use
257 sigaction(2) instead of signal(3) and cache it. (Denys Vlasenko)
258 * Cache stat(2) calls more to reduce number of calls (Denys Vlasenko)
260 2019-05-06 17:25 Christos Zoulas <christos@zoulas.com>
262 * PR/77: Handle --mime-type and -k correctly.
264 2019-05-03 15:26 Christos Zoulas <christos@zoulas.com>
266 * Switch decompression code to use vfork() because
267 tools like rpmdiff and rpmbuild call libmagic
268 with large process footprints (Denys Vlasenko)
270 2019-04-07 14:05 Christos Zoulas <christos@zoulas.com>
272 * PR/75: --enable-zlib, did not work.
274 2019-02-27 11:54 Christos Zoulas <christos@zoulas.com>
276 * Improve regex efficiency (Michael Schroeder) by:
277 1. Prefixing regex searches with regular search
278 for keywords where possible
279 2. Using memmem(3) where available
281 2019-02-20 10:16 Christos Zoulas <christos@zoulas.com>
285 2019-02-19 15:30 Christos Zoulas <christos@zoulas.com>
287 * Fix cast to use cast macros
288 * Add UCS-32 builtin detection (PR/61) reported by tmc
290 2019-02-18 18:24 Christos Zoulas <christos@zoulas.com>
292 * Fix stack read (PR/62) and write (PR/64) stack overflows
295 2018-10-18 19:32 Christos Zoulas <christos@zoulas.com>
299 2018-09-10 20:38 Christos Zoulas <christos@zoulas.com>
301 * Add FreeBSD ELF core file support (John Baldwin)
303 2018-08-20 18:40 Christos Zoulas <christos@zoulas.com>
305 * PR/30: Allow all parameter values to be set (don't treat 0 specially)
306 * handle default annotations on the softmagic match instead at the
309 2018-07-25 10:17 Christos Zoulas <christos@zoulas.com>
311 * PR/23: Recognize JSON files
313 2018-07-25 10:17 Christos Zoulas <christos@zoulas.com>
315 * PR/18: file --mime-encoding should not print mime-type
317 2018-07-25 8:50 Christos Zoulas <christos@zoulas.com>
321 2018-06-22 16:38 Christos Zoulas <christos@zoulas.com>
323 * Add Quad indirect offsets
325 2018-05-24 14:10 Christos Zoulas <christos@zoulas.com>
327 * Enable parsing of ELF dynamic sections to handle PIE better
329 2018-04-15 14:52 Christos Zoulas <christos@zoulas.com>
333 2018-02-24 14:50 Christos Zoulas <christos@zoulas.com>
335 * extend the support for ${x?:} expansions for magic descriptions
337 2018-02-21 16:25 Christos Zoulas <christos@zoulas.com>
339 * add support for ${x?:} in mime types to handle
342 2017-11-03 9:23 Christos Zoulas <christos@zoulas.com>
344 * add support for negative offsets (offsets from the end of file)
346 2017-09-26 8:22 Christos Zoulas <christos@zoulas.com>
348 * close the file on error when writing magic (Steve Grubb)
350 2017-09-24 12:02 Christos Zoulas <christos@zoulas.com>
352 * seccomp support (Paul Moore)
354 2017-09-02 11:53 Christos Zoulas <christos@zoulas.com>
358 2017-08-28 16:37 Christos Zoulas <christos@zoulas.com>
360 * Always reset state in {file,buffer}_apprentice (Krzysztof Wilczynski)
362 2017-08-27 03:55 Christos Zoulas <christos@zoulas.com>
364 * Fix always true condition (Thomas Jarosch)
366 2017-05-24 17:30 Christos Zoulas <christos@zoulas.com>
368 * pickier parsing of numeric values in magic files.
370 2017-05-23 17:55 Christos Zoulas <christos@zoulas.com>
372 * PR/615 add magic_getflags()
374 2017-05-23 13:55 Christos Zoulas <christos@zoulas.com>
378 2017-03-17 20:32 Christos Zoulas <christos@zoulas.com>
380 * remove trailing spaces from magic files
382 * better bounds checks for cdf
384 2017-02-10 12:24 Christos Zoulas <christos@zoulas.com>
388 2017-02-07 23:27 Christos Zoulas <christos@zoulas.com>
390 * If we exceeded the offset in a search return no match
392 * Be more lenient on corrupt CDF files (Christoph Biedl)
394 2017-02-04 16:46 Christos Zoulas <christos@zoulas.com>
396 * pacify ubsan sign extension (oss-fuzz/524)
398 2017-02-01 12:42 Christos Zoulas <christos@zoulas.com>
400 * off by one in cdf parsing (PR/593)
401 * report debugging sections in elf (PR/591)
403 2016-11-06 10:52 Christos Zoulas <christos@zoulas.com>
405 * Allow @@@ in extensions
406 * Add missing overflow check in der magic (Jonas Wagner)
408 2016-10-25 10:40 Christos Zoulas <christos@zoulas.com>
412 2016-10-24 11:20 Christos Zoulas <christos@zoulas.com>
414 * der getlength overflow (Jonas Wagner)
415 * multiple magic file load failure (Christoph Biedl)
417 2016-10-17 11:26 Christos Zoulas <christos@zoulas.com>
419 * CDF parsing improvements (Guy Helmer)
421 2016-07-20 7:26 Christos Zoulas <christos@zoulas.com>
423 * Add support for signed indirect offsets
425 2016-07-18 7:41 Christos Zoulas <christos@zoulas.com>
427 * cat /dev/null | file - should print empty (Christoph Biedl)
429 2016-07-05 15:20 Christos Zoulas <christos@zoulas.com>
431 * Bump string size from 64 to 96.
433 2016-06-13 20:20 Christos Zoulas <christos@zoulas.com>
435 * PR/556: Fix separators on annotations.
437 2016-06-13 19:40 Christos Zoulas <christos@zoulas.com>
440 * fix leak on allocation failure
442 2016-06-01 1:20 Christos Zoulas <christos@zoulas.com>
444 * PR/555: Avoid overflow for offset > nbytes
445 * PR/550: Segv on DER parsing:
446 - use the correct variable for length
447 - set offset to 0 on failure.
449 2016-05-13 12:00 Christos Zoulas <christos@zoulas.com>
453 2016-04-18 9:35 Christos Zoulas <christos@zoulas.com>
455 * Errors comparing DER entries or computing offsets
456 are just indications of malformed non-DER files.
458 * Offset comparison was off-by-one.
459 * Fix compression code (Werner Fink)
460 * Put new bytes constant in the right file (not the generated one)
462 2016-04-16 18:34 Christos Zoulas <christos@zoulas.com>
466 2016-03-31 13:50 Christos Zoulas <christos@zoulas.com>
468 * make the number of bytes read from files configurable.
470 2016-03-21 13:40 Christos Zoulas <christos@zoulas.com>
472 * Add bounds checks for DER code (discovered by Thomas Jarosch)
473 * Change indirect recursion limit to indirect use count and
474 bump from 15 to 50 to prevent abuse.
476 2016-03-13 20:39 Christos Zoulas <christos@zoulas.com>
478 * Add -00 which prints filename\0description\0
480 2016-03-01 13:28 Christos Zoulas <christos@zoulas.com>
482 * Fix ID3 indirect parsing
484 2016-01-19 10:18 Christos Zoulas <christos@zoulas.com>
486 * add DER parsing capability
488 2015-11-13 10:35 Christos Zoulas <christos@zoulas.com>
490 * provide dprintf(3) for the OS's that don't have it.
492 2015-11-11 16:25 Christos Zoulas <christos@zoulas.com>
494 * redo the compression code report decompression errors
496 2015-11-10 23:25 Christos Zoulas <christos@zoulas.com>
498 * REG_STARTEND code is not working as expected, delete it.
500 2015-11-09 16:05 Christos Zoulas <christos@zoulas.com>
502 * Add zlib support if we have it.
504 2015-11-05 11:22 Christos Zoulas <christos@zoulas.com>
506 * PR/492: compression forking was broken with magic_buffer.
508 2015-09-16 9:50 Christos Zoulas <christos@zoulas.com>
512 2015-09-11 13:25 Christos Zoulas <christos@zoulas.com>
514 * add a limit to the length of regex searches
516 2015-09-08 9:50 Christos Zoulas <christos@zoulas.com>
518 * fix problems with --parameter (Christoph Biedl)
520 2015-07-11 10:35 Christos Zoulas <christos@zoulas.com>
522 * Windows fixes PR/466 (Jason Hood)
524 2015-07-09 10:35 Christos Zoulas <christos@zoulas.com>
528 2015-06-11 8:52 Christos Zoulas <christos@zoulas.com>
530 * redo long option encoding to fix off-by-one in 5.23
532 2015-06-10 13:50 Christos Zoulas <christos@zoulas.com>
536 2015-06-09 16:10 Christos Zoulas <christos@zoulas.com>
538 * Fix issue with regex range for magic with offset
539 * Always return true from mget with USE (success to mget not match
540 indication). Fixes mime evaluation after USE magic
541 * PR/459: Don't insert magic entries to the list if there are parsing
544 2015-06-03 16:00 Christos Zoulas <christos@zoulas.com>
546 * PR/455: Add utf-7 encoding
548 2015-06-03 14:30 Christos Zoulas <christos@zoulas.com>
550 * PR/455: Implement -Z, look inside, but don't report on compression
551 * PR/454: Fix allocation error on bad magic.
553 2015-05-29 10:30 Christos Zoulas <christos@zoulas.com>
555 * handle MAGIC_CONTINUE everywhere, not just in softmagic
557 2015-05-21 14:30 Christos Zoulas <christos@zoulas.com>
559 * don't print descriptions for NAME types when mime.
561 2015-04-09 15:59 Christos Zoulas <christos@zoulas.com>
563 * Add --extension to list the known extensions for this file type
564 Idea by Andrew J Roazen
566 2015-02-14 12:23 Christos Zoulas <christos@zoulas.com>
568 * Bump file search buffer size to 1M.
570 2015-01-09 14:35 Christos Zoulas <christos@zoulas.com>
572 * Fix multiple issues with date formats reported by Christoph Biedl:
573 - T_LOCAL meaning was reversed
574 - Arithmetic did not work
575 Also stop adjusting daylight savings for gmt printing.
577 2015-01-05 13:00 Christos Zoulas <christos@zoulas.com>
579 * PR/411: Fix memory corruption from corrupt cdf file.
581 2015-01-02 15:15 Christos Zoulas <christos@zoulas.com>
585 2015-01-01 12:01 Christos Zoulas <christos@zoulas.com>
587 * add indirect relative for TIFF/Exif
589 2014-12-16 18:10 Christos Zoulas <christos@zoulas.com>
591 * restructure elf note printing to avoid repeated messages
592 * add note limit, suggested by Alexander Cherepanov
594 2014-12-16 16:53 Christos Zoulas <christos@zoulas.com>
596 * Bail out on partial pread()'s (Alexander Cherepanov)
597 * Fix incorrect bounds check in file_printable (Alexander Cherepanov)
599 2014-12-11 20:01 Christos Zoulas <christos@zoulas.com>
601 * PR/405: ignore SIGPIPE from uncompress programs
602 * change printable -> file_printable and use it in
603 more places for safety
604 * in ELF, instead of "(uses dynamic libraries)" when PT_INTERP
605 is present print the interpreter name.
607 2014-12-10 20:01 Christos Zoulas <christos@zoulas.com>
611 2014-11-27 18:40 Christos Zoulas <christos@zoulas.com>
613 * Allow setting more parameters from the command line.
614 * Split name/use and indirect magic recursion limits.
616 2014-11-27 11:12 Christos Zoulas <christos@zoulas.com>
618 * Adjust ELF parameters and the default recursion
620 * Allow setting the recursion level dynamically.
622 2014-11-24 8:55 Christos Zoulas <christos@zoulas.com>
624 * The following fixes resulted from Thomas Jarosch's fuzzing
625 tests that revealed severe performance issues on pathological
627 - limit number of elf program and sections processing
628 - abort elf note processing quickly
629 - reduce the number of recursion levels from 20 to 10
630 - preserve error messages in indirect magic handling
632 This is tracked as CVE-2014-8116 and CVE-2014-8117
634 2014-11-12 10:30 Christos Zoulas <christos@zoulas.com>
636 * fix bogus free in the user buffer case.
638 2014-11-11 12:35 Christos Zoulas <christos@zoulas.com>
640 * fix out of bounds read for pascal strings
641 * fix memory leak (not freeing the head of each mlist)
643 2014-11-07 10:25 Christos Zoulas <christos@zoulas.com>
645 * When printing strings from a file, convert them to printable
646 on a byte by byte basis, so that we don't get issues with
647 locale's trying to interpret random byte streams as UTF-8 and
648 having printf error out with EILSEQ.
650 2014-10-17 11:48 Christos Zoulas <christos@zoulas.com>
652 * fix bounds in note reading (Francisco Alonso / Red Hat)
654 2014-10-11 15:02 Christos Zoulas <christos@zoulas.com>
656 * fix autoconf glue for setlocale and locale_t; some OS's
657 have locale_t in xlocale.h
659 2014-10-10 15:01 Christos Zoulas <christos@zoulas.com>
663 2014-08-17 10:01 Christos Zoulas <christos@zoulas.com>
665 * recognize encrypted CDF documents
667 2014-08-04 9:18 Christos Zoulas <christos@zoulas.com>
669 * add magic_load_buffers from Brooks Davis
671 2014-07-24 16:40 Christos Zoulas <christos@zoulas.com>
673 * add thumbs.db support
675 2014-06-12 12:28 Christos Zoulas <christos@zoulas.com>
679 2014-06-09 9:04 Christos Zoulas <christos@zoulas.com>
681 * Misc buffer overruns and missing buffer size tests in cdf parsing
682 (Francisco Alonso, Jan Kaluza)
684 2014-06-02 14:50 Christos Zoulas <christos@zoulas.com>
686 * Enforce limit of 8K on regex searches that have no limits
687 * Allow the l modifier for regex to mean line count. Default
688 to byte count. If line count is specified, assume a max
689 of 80 characters per line to limit the byte count.
690 * Don't allow conversions to be used for dates, allowing
691 the mask field to be used as an offset.
693 2014-05-30 12:51 Christos Zoulas <christos@zoulas.com>
695 * Make the range operator limit the length of the
698 2014-05-14 19:23 Christos Zoulas <christos@zoulas.com>
700 * PR/347: Windows fixes
701 * PR/352: Hangul word processor recognition
702 * PR/354: Encoding irregularities in text files
704 2014-05-06 6:12 Christos Zoulas <christos@zoulas.com>
706 * Fix uninitialized title in CDF files (Jan Kaluza)
708 2014-05-04 14:55 Christos Zoulas <christos@zoulas.com>
710 * PR/351: Fix compilation of empty files
712 2014-04-30 17:39 Christos Zoulas <christos@zoulas.com>
714 * Fix integer formats: We don't specify 'l' or
715 'h' and 'hh' specifiers anymore, only 'll' for
716 quads and nothing for the rest. This is so that
717 magic writing is simpler.
719 2014-04-01 15:25 Christos Zoulas <christos@zoulas.com>
721 * PR/341: Jan Kaluza, fix memory leak
722 * PR/342: Jan Kaluza, fix out of bounds read
724 2014-03-28 15:25 Christos Zoulas <christos@zoulas.com>
726 * Fix issue with long formats not matching fmtcheck
728 2014-03-26 11:25 Christos Zoulas <christos@zoulas.com>
732 2014-03-15 17:45 Christos Zoulas <christos@zoulas.com>
734 * add fmtcheck(3) for those who don't have it
736 2014-03-14 15:12 Christos Zoulas <christos@zoulas.com>
738 * prevent mime entries from being attached to magic
739 entries with no descriptions
741 * adjust magic strength for regex type
743 * remove superfluous ascmagic with encoding test
745 2014-03-06 12:01 Christos Zoulas <christos@zoulas.com>
747 * fix regression fix echo -ne "\012\013\014" | file -i -
748 which printed "binary" instead of "application/octet-stream"
750 * add size_t overflow check for magic file size
752 2014-02-27 16:01 Christos Zoulas <christos@zoulas.com>
754 * experimental support for matching with CFD CLSID
756 2014-02-18 13:04 Kimmo Suominen (kimmo@suominen.com)
758 * Cache old LC_CTYPE locale before setting it to "C", so
759 we can use it to restore LC_CTYPE instead of asking
760 setlocale() to scan the environment variables.
762 2014-02-12 18:21 Christos Zoulas <christos@zoulas.com>
764 * Count recursion levels through indirect magic
766 2014-02-11 10:40 Christos Zoulas <christos@zoulas.com>
768 * Prevent infinite recursion on files with indirect offsets of 0
770 2014-01-30 21:00 Christos Zoulas <christos@zoulas.com>
772 * Add -E flag that makes file print filesystem errors to stderr
775 2014-01-08 17:20 Christos Zoulas <christos@zoulas.com>
777 * mime printing could print results from multiple magic entries
778 if there were multiple matches.
779 * in some cases overflow was not detected when computing offsets
782 2013-12-05 12:00 Christos Zoulas <christos@zoulas.com>
784 * use strcasestr() to for cdf strings
785 * reset to the "C" locale while doing regex operations, or case
786 insensitive comparisons; this is provisional
788 2013-11-19 20:10 Christos Zoulas <christos@zoulas.com>
790 * always leave magic file loaded, don't unload for magic_check, etc.
791 * fix default encoding to binary instead of unknown which broke recently
792 * handle empty and one byte files, less specially so that
793 --mime-encoding does not break completely.
795 2013-11-06 14:40 Christos Zoulas <christos@zoulas.com>
797 * fix erroneous non-zero exit code from non-existent file and message
799 2013-10-29 14:25 Christos Zoulas <christos@zoulas.com>
801 * add CDF MSI file detection (Guy Helmer)
803 2013-09-03 11:56 Christos Zoulas <christos@zoulas.com>
805 * Don't mix errors and regular output if there was an error
806 * in magic_descriptor() don't close the file and try to restore
809 2013-05-30 17:25 Christos Zoulas <christos@zoulas.com>
811 * Don't treat magic as an error if offset was past EOF (Christoph Biedl)
813 2013-05-28 17:25 Christos Zoulas <christos@zoulas.com>
815 * Fix spacing issues in softmagic and elf (Jan Kaluza)
817 2013-05-02 18:00 Christos Zoulas <christos@zoulas.com>
819 * Fix segmentation fault with multiple magic_load commands.
821 2013-04-22 11:20 Christos Zoulas <christos@zoulas.com>
823 * The way "default" was implemented was not very useful
824 because the "if something was printed at that level"
825 was not easily controlled by the user, and the format
826 was bound to a string which is too restrictive. Add
827 a "clear" for that level keyword and make "default"
828 void. This way one can do:
834 >>>13 lelong x unknown %x
836 2013-03-25 13:20 Christos Zoulas <christos@zoulas.com>
838 * disallow strength setting in "name" entries
840 2013-03-06 21:24 Christos Zoulas <christos@zoulas.com>
842 * fix recursive magic separator printing
844 2013-02-26 19:28 Christos Zoulas <christos@zoulas.com>
846 * limit recursion level for mget
847 * fix pread() related breakage in cdf
848 * handle offsets properly in recursive "use"
850 2013-02-18 10:39 Christos Zoulas <christos@zoulas.com>
852 * add elf reading of debug info to determine if file is stripped
856 2013-01-25 18:05 Christos Zoulas <christos@zoulas.com>
858 * change mime description size from 64 to 80 to accommodate OOXML.
860 2013-01-11 14:50 Christos Zoulas <christos@zoulas.com>
862 * Warn about inconsistent continuation levels.
863 * Change fsmagic to add a space after it prints.
865 2013-01-10 21:00 Christos Zoulas <christos@zoulas.com>
867 * Make getline public so that file can link against it.
868 Perhaps it is better to rename it, or hide it differently.
869 Fixes builds on platforms that do not provide it.
871 2013-01-07 16:30 Christos Zoulas <christos@zoulas.com>
873 * Add SuS d{,1,2,4,8}, u{,1,2,4,8} and document
874 what long, int, short, etc is (Guy Harris)
876 2013-01-06 11:20 Christos Zoulas <christos@zoulas.com>
878 * add magic_version function and constant
879 * Redo memory allocation and de-allocation.
880 (prevents double frees on non mmap platforms)
881 * Fix bug with name/use having to do with passing
882 found state from the parent to the child and back.
884 2012-12-19 8:47 Christos Zoulas <christos@zoulas.com>
886 * Only print elf capabilities for archs we know (Jan Kaluza)
888 2012-10-30 19:14 Christos Zoulas <christos@zoulas.com>
890 * Add "name" and "use" file types in order to look
893 2012-09-06 10:40 Christos Zoulas <christos@zoulas.com>
895 * make --version exit 0 (Matthew Schultz)
896 * add string/T (Jan Kaluza)
898 2012-08-09 2:15 Christos Zoulas <christos@zoulas.com>
900 * add z and t modifiers for our own vasprintf
901 * search for $HOME/.magic.mgc if it is there first
902 * fix reads from a pipe, and preserve errno
904 2012-05-15 13:12 Christos Zoulas <christos@zoulas.com>
906 * use ctime_r, asctime_r
908 2012-04-06 17:18 Christos Zoulas <christos@zoulas.com>
910 * Fixes for indirect offsets to handle apple disk formats
912 2012-04-03 18:26 Christos Zoulas <christos@zoulas.com>
914 * Add windows date field types
915 * More info for windows shortcuts (incomplete)
917 2012-02-20 17:33 Christos Zoulas <christos@zoulas.com>
919 * Fix CDF parsing issues found by CERT's fuzzing tool (Will Dormann)
921 2011-12-15 12:17 Chris Metcalf <cmetcalf@tilera.com>
923 * Support Tilera architectures (tile64, tilepro, tilegx).
925 2011-12-16 16:33 Reuben Thomas <rrt@sc3d.org>
927 * Add magic for /usr/bin/env Perl scripts
928 * Weaken generic script magic to avoid clashing with
929 language-specific magic.
931 2011-12-08 13:37 Reuben Thomas <rrt@sc3d.org>
933 * Simplify if (p) free(p) to free(p).
935 2011-12-08 13:07 Reuben Thomas <rrt@sc3d.org>
937 * Remove hardwired token finding (names.h), turning it into soft
938 magic. Patterns are either anchored regexs or search/8192. English
939 language detection and PL/1 detection have been removed as they
940 were too fragile. -e tokens is still accepted for backwards
942 * Move 3ds patterns (which are commented out anyway) into autodesk
943 (they were, oddly, in c-lang).
945 2011-12-06 00:16 Reuben Thomas <rrt@sc3d.org>
947 * Tweak strength of generic hash-bang detectors to be less than
949 * Make an inconsistent description of Python scripts consistent.
951 2011-12-05 23:58 Reuben Thomas <rrt@sc3d.org>
953 * Fix minor error in file(1).
955 2011-11-05 00:00 Reuben Thomas <rrt@sc3d.org>
957 * Fix issue #150 (I hope).
959 2011-09-22 12:57 Christos Zoulas <christos@zoulas.com>
961 * Python3 binding fixes from Kelly Anderson
963 2011-09-20 11:32 Christos Zoulas <christos@zoulas.com>
965 * If a string type magic entry is marked as text or binary
966 only match text files against text entries and binary
967 files against binary entries.
969 2011-09-01 12:12 Christos Zoulas <christos@zoulas.com>
971 * Don't wait for any subprocess, just the one we forked.
973 2011-08-26 16:40 Christos Zoulas <christos@zoulas.com>
975 * If the application name is not set in a cdf file, try to see
976 if it has a directory with the application name on it.
978 2011-08-17 14:32 Christos Zoulas <christos@zoulas.com>
980 * Fix ELF lseek(2) madness. Inspired by PR/134 by Jan Kaluza
982 2011-08-14 09:03 Christos Zoulas <christos@zoulas.com>
984 * Don't use variable string formats.
986 2011-07-12 12:32 Reuben Thomas <rrt@sc3d.org>
988 * Fix detection of Zip files (Mantis #128).
989 * Make some minor improvements to file(1).
990 * Rename MIME types for filesystem objects for consistency with
991 xdg-utils. Typically this means that application/x-foo becomes
992 inode/foo, but some names also change slightly, e.g.
993 application/x-character-device becomes inode/chardevice.
995 2011-05-10 20:57 Christos Zoulas <christos@zoulas.com>
997 * fix mingw compilation (Abradoks)
999 2011-05-10 20:57 Christos Zoulas <christos@zoulas.com>
1001 * remove patchlevel.h
1002 * Fix read past allocated memory caused by double-incrementing
1003 a pointer in a loop (reported by Roberto Maar)
1005 2011-03-30 15:45 Christos Zoulas <christos@zoulas.com>
1007 * Fix cdf string buffer setting (Sven Anders)
1009 2011-03-20 16:35 Christos Zoulas <christos@zoulas.com>
1011 * Eliminate MAXPATHLEN and use dynamic allocation for
1012 path and file buffers.
1014 2011-03-15 18:15 Christos Zoulas <christos@zoulas.com>
1016 * binary tests on magic entries with masks could spuriously
1017 get converted to ascii.
1019 2011-03-12 18:06 Reuben Thomas <rrt@sc3d.org>
1021 * Improve file.man (remove BUGS, present email addresses consistently).
1023 2011-03-07 19:38 Christos Zoulas <christos@zoulas.com>
1025 * add lrzip support (from Ville Skytta)
1027 2011-02-10 16:36 Christos Zoulas <christos@zoulas.com>
1029 * fix CDF bounds checking (Guy Helmer)
1031 2011-02-10 12:03 Christos Zoulas <christos@zoulas.com>
1033 * add cdf_ctime() that prints a meaningful error when time cannot
1036 2011-02-02 20:40 Christos Zoulas <christos@zoulas.com>
1038 * help and version output to stdout.
1040 * When matching softmagic for ascii files, don't just print
1041 the softmagic classification, keep going and print the
1042 text classification too. This fixes broken troff files when
1043 we moved them from keyword recognition to softmagic
1044 (they stopped printing "with CRLF" etc.)
1045 Reported by Doug McIlroy.
1047 2011-01-16 19:31 Reuben Thomas <rrt@sc3d.org>
1049 * Fix two potential buffer overruns in apprentice_list.
1051 2011-01-14 22:33 Reuben Thomas <rrt@sc3d.org>
1053 * New Python binding in pure Python.
1054 * Update libmagic(3).
1056 2011-01-06 21:40 Reuben Thomas <rrt@sc3d.org>
1058 * Fix Python bindings (including recent Python 3 compatibility
1061 2011-01-04 18:43 Reuben Thomas <rrt@sc3d.org>
1063 * magic/Makefile.am: make it easier to recover from magic build failures.
1064 * Fix pstring length specifier parsing to avoid generating invalid
1066 * Add pstring length "J" (for "JPEG") to specify that the length
1068 * Fix JPEG comment parsing at last using pstring/HJ!
1069 * Ignore section 5 man pages in doc/.cvsignore.
1071 2010-12-22 13:12 Christos Zoulas <christos@zoulas.com>
1073 * Add pstring/BHhLl to specify the type of the length of pascal
1076 2010-11-26 18:39 Reuben Thomas <rrt@sc3d.org>
1078 * Fix "-e soft": it was ignored when softmagic was called
1080 * Improve comments and use "unsigned char" in tar.h/is_tar.c.
1082 2010-11-05 17:26 Reuben Thomas <rrt@sc3d.org>
1084 * Make bug reporting addresses more visible.
1086 2010-11-01 18:35 Reuben Thomas <rrt@sc3d.org>
1088 * Add tcl magic from Gustaf Neumann
1090 2010-10-24 10:42 Christos Zoulas <christos@zoulas.com>
1092 * Fix the whitespace comparing code (Christopher Chittleborough)
1094 2010-10-06 21:05 Christos Zoulas <christos@zoulas.com>
1096 * allow string/t to work (Jan Kaluza)
1098 2010-09-20 22:11 Reuben Thomas <rrt@sc3d.org>
1100 * Apply some patches from Ubuntu and Fedora.
1102 2010-09-20 21:16 Reuben Thomas <rrt@sc3d.org>
1104 * Apply all patches from Debian package 5.04-6 which have not
1105 already been applied and are not Debian-specific.
1107 2010-09-20 15:24 Reuben Thomas <rrt@sc3d.org>
1109 * Minor security fix to softmagic.c (don't use untrusted
1110 string as printf format).
1112 2010-07-21 12:20 Christos Zoulas <christos@zoulas.com>
1114 * MINGW32 portability from LRN
1116 * Don't warn about escaping magic regex chars when we are in a regex.
1118 2010-07-19 10:55 Christos Zoulas <christos@zoulas.com>
1120 * Only try to print prpsinfo for core files. (Jan Kaluza)
1122 2010-04-22 12:55 Christos Zoulas <christos@zoulas.com>
1124 * Try more elf offsets for Debian core files. (Arnaud Giersch)
1126 2010-02-20 15:18 Reuben Thomas <rrt@sc3d.org>
1128 * Clarify which sort of CDF we mean.
1130 2010-02-14 22:58 Reuben Thomas <rrt@sc3d.org>
1132 * Re-jig Zip file type magic so that unsupported special
1133 Zip types (those with "mimetype" at offset 30) can be
1136 2010-02-02 21:50 Reuben Thomas <rrt@sc3d.org>
1138 * Add support for OCF (EPUB) files (application/epub+zip)
1140 2010-01-28 18:25 Christos Zoulas <christos@zoulas.com>
1142 * Fix core-dump from unbound loop:
1143 https://bugzilla.redhat.com/show_bug.cgi?id=533245
1145 2010-01-22 15:45 Christos Zoulas <christos@zoulas.com>
1147 * print proper mime for crystal reports file
1149 * print the last summary information of a cdf document, not the
1150 first so that nested documents print the right info
1152 2010-01-16 18:42 Charles Longeau <chl@tuxfamily.org>
1154 * bring back some fixes from OpenBSD:
1155 - make gcc2 builds file
1156 - fix typos in a magic file comment
1158 2009-11-17 18:35 Christos Zoulas <christos@zoulas.com>
1160 * ctime/asctime can return NULL on some OS's although
1161 they should not (Toshit Antani)
1163 2009-09-14 13:49 Christos Zoulas <christos@zoulas.com>
1165 * Centralize magic path handling routines and remove the
1166 special-casing from file.c so that the python module for
1167 example comes up with the same magic path (Fixes ~/.magic
1168 handling) (from Gab)
1170 2009-09-11 23:38 Reuben Thomas <rrt@sc3d.org>
1172 * When magic argument is a directory, read the files in
1173 strcmp-sorted order (fixes Debian bug #488562 and our own FIXME).
1175 2009-09-11 13:11 Reuben Thomas <rrt@sc3d.org>
1177 * Combine overlapping epoc and psion magic files into one (epoc).
1179 * Add some more EPOC MIME types.
1181 2009-08-19 15:55 Christos Zoulas <christos@zoulas.com>
1183 * Fix 3 bugs (From Ian Darwin):
1184 - file_showstr could move one past the end of the array
1185 - parse_apple did not nul terminate the string in the overflow case
1186 - parse_mime truncated the wrong string in the overflow case
1188 2009-08-12 12:28 Robert Byrnes <byrnes@wildpumpkin.net>
1190 * Include Localstuff when compiling magic.
1192 2009-07-15 10:05 Christos Zoulas <christos@zoulas.com>
1194 * Fix logic for including mygetopts.h
1196 * Make cdf.c compile again with debugging
1198 * Add the necessary field handling for crystal reports files to work
1200 2009-06-23 01:34 Reuben Thomas <rrt@sc3d.org>
1202 * Stop "(if" identifying Lisp files, that's plain dumb!
1204 2009-06-09 22:13 Reuben Thomas <rrt@sc3d.org>
1206 * Add a couple of missing MP3 MIME types.
1208 2009-05-27 23:00 Reuben Thomas <rrt@sc3d.org>
1210 * Add full range of hash-bang tests for Python and Ruby.
1212 * Add MIME types for Python and Ruby scripts.
1214 2009-05-13 10:44 Christos Zoulas <christos@zoulas.com>
1216 * off by one in parsing hw capabilities in elf
1219 2009-05-08 13:40 Christos Zoulas <christos@zoulas.com>
1221 * lint fixes and more from NetBSD
1223 2009-05-06 10:25 Christos Zoulas <christos@zoulas.com>
1225 * Avoid null dereference in cdf code (Drew Yao)
1227 * More cdf bounds checks and overflow checks
1229 2009-05-01 18:37 Christos Zoulas <christos@zoulas.com>
1231 * Buffer overflow fixes from Drew Yao
1233 2009-04-30 17:10 Christos Zoulas <christos@zoulas.com>
1235 * Fix more cdf lossage. All the documents I have
1236 right now print the correct information.
1238 2009-03-27 18:43 Christos Zoulas <christos@zoulas.com>
1240 * don't print \012- separators in the same magic entry
1241 if it consists of multiple magic printing lines.
1243 2009-03-23 10:20 Christos Zoulas <christos@zoulas.com>
1245 * Avoid file descriptor leak in compress code from
1248 2009-03-18 16:50 Christos Zoulas <christos@zoulas.com>
1250 * Allow escaping of relation characters, so that we can say \^[A-Z]
1251 and the ^ is not eaten as a relation char.
1253 * Fix troff and fortran to their previous glory using
1254 regex. This was broken since their removel from ascmagic.
1256 2009-03-10 16:50 Christos Zoulas <christos@zoulas.com>
1258 * don't use strlen in strndup() (Toby Peterson)
1260 2009-03-10 7:45 Christos Zoulas <christos@zoulas.com>
1264 2009-02-23 15:45 Christos Zoulas <christos@zoulas.com>
1266 * make the cdf code use the buffer first if available,
1267 and then the fd code.
1269 2009-02-13 13:45 Christos Zoulas <christos@zoulas.com>
1271 * look for struct option to determine if getopt.h is usable for IRIX.
1273 * sanitize cdf document strings
1275 2009-02-04 13:25 Christos Zoulas <christos@zoulas.com>
1277 * fix OS/2 warnings.
1279 2008-12-12 15:50 Christos Zoulas <christos@zoulas.com>
1281 * fix initial offset calculation for non 4K sector files
1283 * add loop limits to avoid DoS attacks by constructing
1284 looping sector references.
1286 2008-12-03 13:05 Christos Zoulas <christos@zoulas.com>
1288 * fix memory botches on cdf file parsing.
1290 * exit with non-zero value for any error, not just for the last
1293 2008-11-09 20:42 Charles Longeau <chl@tuxfamily.org>
1295 * Replace all str{cpy,cat} functions with strl{cpy,cat}
1296 * Ensure that strl{cpy,cat} are included in libmagic,
1299 2008-11-06 18:18 Christos Zoulas <christos@zoulas.com>
1301 * Handle ID3 format files.
1303 2008-11-06 23:00 Reuben Thomas <rrt@sc3d.org>
1305 * Fix --mime, --mime-type and --mime-encoding under new scheme.
1307 * Rename "ascii" to "text" and add "encoding" test.
1309 * Return a precise ("utf-16le" or "utf-16be") MIME charset for
1312 * Fix error in comment caused by automatic indentation adding
1315 2008-11-06 10:35 Christos Zoulas <christos@astron.com>
1317 * use memchr instead of strchr because the string
1318 might not be NUL terminated (Scott MacVicar)
1320 2008-11-03 07:31 Reuben Thomas <rrt@sc3d.org>
1322 * Fix a printf with a non-literal format string.
1324 * Fix formatting and punctuation of help for "--apple".
1326 2008-10-30 11:00 Reuben Thomas <rrt@sc3d.org>
1328 * Correct words counts in comments of struct magic.
1330 * Fix handle_annotation to allow both Apple and MIME types to be
1331 printed, and to return correct code if MIME type is
1332 printed (1, not 0) or if there's an error (-1 not 1).
1334 * Fix output of charset for MIME type (precede with semi-colon;
1335 fixes Debian bug #501460).
1337 * Fix potential attacks via conversion specifications in magic
1340 * Add a FIXME for Debian bug #488562 (magic files should be
1341 read in a defined order, by sorting the names).
1343 2008-10-18 16:45 Christos Zoulas <christos@astron.com>
1345 * Added APPLE file creator/type
1347 2008-10-12 10:20 Christos Zoulas <christos@astron.com>
1351 2008-10-09 16:40 Christos Zoulas <christos@astron.com>
1353 * filesystem and msdos patches (Joerg Jenderek)
1355 2008-10-09 13:20 Christos Zoulas <christos@astron.com>
1357 * correct --exclude documentation issues: remove troff and fortran
1358 and rename "token" to "tokens". (Randy McMurchy)
1360 2008-10-01 10:30 Christos Zoulas <christos@astron.com>
1362 * Read ~/.magic in addition to the default magic file not instead
1363 of, as documented in the man page.
1365 2008-09-10 21:30 Reuben Thomas <rrt@sc3d.org>
1367 * Comment out graphviz patterns, as they match too many files.
1369 2008-08-30 12:54 Christos Zoulas <christos@astron.com>
1371 * Don't eat trailing \n in magic enties.
1373 * Cast defines to allow compilation using a c++ compiler.
1375 2008-08-25 23:56 Reuben Thomas <rrt@sc3d.org>
1377 * Add text/x-lua MIME type for Lua scripts.
1379 * Escape { in regex in graphviz patterns.
1381 2008-07-26 00:59 Reuben Thomas <rrt@sc3d.org>
1383 * Add MIME types for special files.
1385 * Use access to give more accurate information for files that
1390 2008-07-02 11:15 Christos Zoulas <christos@astron.com>
1392 * add !:strength op to adjust magic strength (experimental)
1394 2008-06-16 21:41 Reuben Thomas <rrt@sc3d.org>
1396 * Fix automake error in configure.ac.
1398 * Add MIME type for Psion Sketch files.
1400 2008-06-05 08:59 Christos Zoulas <christos@astron.com>
1402 * Don't print warnings about bad namesize in stripped
1403 binaries with PT_NOTE is still there, and the actual
1404 note is gone (Jakub Jelinek)
1406 2008-05-28 15:12 Robert Byrnes <byrnes@wildpumpkin.net>
1409 Note invalid byte order for little-endian SPARC32PLUS.
1410 Add SPARC V9 vendor extensions and memory model.
1413 Pass target machine to doshn (for Solaris hardware capabilities).
1415 * src/readelf.c (doshn):
1416 Add support for Solaris hardware/software capabilities.
1421 * src/vasprintf.c (dispatch):
1422 Add support for ll modifier.
1424 2008-05-16 10:25 Christos Zoulas <christos@astron.com>
1426 * Fix compiler warnings.
1428 * remove stray printf, and fix a vprintf bug. (Martin Dorey)
1430 2008-05-06 00:13 Robert Byrnes <byrnes@wildpumpkin.net>
1433 Ensure that getopt_long and [v]asprintf are included in libmagic,
1436 Remove unnecessary EXTRA_DIST.
1441 * src/vasprintf.c (dispatch):
1442 Fix variable precision bug: be sure to step past '*'.
1444 * src/vasprintf.c (core):
1445 Remove unreachable code.
1447 * src/apprentice.c (set_test_type):
1448 Add cast to avoid compiler warning.
1450 2008-04-22 23:45 Christos Zoulas <christos@astron.com>
1452 * Add magic submission guidelines (Abel Cheung)
1454 * split msdos and windows magic (Abel Cheung)
1456 2008-04-04 11:00 Christos Zoulas <christos@astron.com>
1458 * >= <= is not supported, so fix the magic and warn about it.
1459 reported by: Thien-Thi Nguyen <ttn@gnuvola.org>
1461 2008-03-27 16:16 Robert Byrnes <byrnes@wildpumpkin.net>
1463 * src/readelf.c (donote):
1464 ELF core file command name/line bug fixes and enhancements:
1466 Try larger offsets first to avoid false matches
1467 from earlier data that happen to look like strings;
1468 this primarily affected SunOS 5.x 32-bit Intel core files.
1470 Add support for command line (instead of just short name)
1473 Add information about NT_PSINFO for SunOS 5.x.
1475 Only trim whitespace from end of command line.
1477 2007-02-11 01:36 Reuben Thomas <rrt@sc3d.org>
1479 * Change strength of ! from MULT to 0, as it matches almost
1480 anything (Reuben Thomas)
1482 * Debian fixes (Reuben Thomas)
1484 2007-02-11 00:17 Reuben Thomas <rrt@sc3d.org>
1486 * Clarify UTF-8 BOM message (Reuben Thomas)
1488 * Add HTML comment to token list in names.h
1490 2007-02-04 15:50 Christos Zoulas <christos@astron.com>
1492 * Debian fixes (Reuben Thomas)
1494 2007-02-04 11:31 Christos Zoulas <christos@astron.com>
1496 * !:mime annotations in magic files (Reuben Thomas)
1498 2007-01-29 15:35 Christos Zoulas <christos@astron.com>
1500 * zero out utime/utimes structs (Gavin Atkinson)
1502 2007-01-26 13:45 Christos Zoulas <christos@astron.com>
1504 * reduce writable data from Diego "Flameeyes" Petten
1506 2007-12-28 15:06 Christos Zoulas <christos@astron.com>
1510 * remove bogus regex magic that could cause a DoS
1512 * better mismatch version message
1514 2007-12-27 11:35 Christos Zoulas <christos@astron.com>
1516 * bring back some fixes from OpenBSD
1518 * treat ELF dynamic objects as executables
1522 2007-12-01 19:55 Christos Zoulas <christos@astron.com>
1524 * make sure we have zlib.h and libz to compile the builtin
1527 2007-10-28 20:48 Christos Zoulas <christos@astron.com>
1529 * float and double magic support (Behan Webster)
1531 2007-10-28 20:48 Christos Zoulas <christos@astron.com>
1533 * Convert fortran to a soft test (Reuben Thomas)
1535 2007-10-23 5:25 Christos Zoulas <christos@astron.com>
1537 * Add --with-filename, and --no-filename (Reuben Thomas)
1539 2007-10-23 3:59 Christos Zoulas <christos@astron.com>
1541 * Rest of the mime split (Reuben Thomas)
1543 * Make usage message generated from the flags so that
1544 they stay consistent (Reuben Thomas)
1546 2007-10-20 3:06 Christos Zoulas <christos@astron.com>
1548 * typo in comment, missing ifdef QUICK, remove unneeded code
1551 2007-10-17 3:33 Christos Zoulas <christos@astron.com>
1553 * Fix problem printing -\012 in some entries
1555 * Separate magic type and encoding flags (Reuben Thomas)
1557 2007-10-09 3:55 Christos Zoulas <christos@astron.com>
1559 * configure fix for int64 and strndup (Reuben Thomas)
1561 2007-09-26 4:45 Christos Zoulas <christos@astron.com>
1563 * Add magic_descriptor() function.
1565 * Fix regression in elf reading code where the core name was
1568 * Don't convert NUL's to spaces in {l,b}estring16 (Daniel Dawson)
1570 2007-08-19 6:30 Christos Zoulas <christos@astron.com>
1572 * Make mime format consistent so that it can
1574 mimetype [charset=character-set] [encoding=encoding-mime-type]
1576 Remove spurious extra text from some MIME type printouts
1579 Fix one case where -i produced nothing at all (for a 1-byte file,
1580 which is now classed as application/octet-stream).
1582 Remove 7/8bit classifications, since they were arbitrary
1583 and not based on the file data.
1585 This work was done by Reuben Thomas
1587 2007-05-24 10:00 Christos Zoulas <christos@astron.com>
1589 * Fix another integer overflow (Colin Percival)
1591 2007-03-26 13:58 Christos Zoulas <christos@astron.com>
1593 * make sure that all of struct magic_set is initialized appropriately
1596 2007-03-25 17:44 Christos Zoulas <christos@astron.com>
1598 * reset left bytes in the buffer (Dmitry V. Levin)
1600 * compilation failed with COMPILE_ONLY and ENABLE_CONDITIONALS
1603 2007-03-15 10:51 Christos Zoulas <christos@astron.com>
1605 * fix fortran and nroff reversed tests (Dmitry V. Levin)
1607 * fix exclude option (Dmitry V. Levin)
1609 2007-02-08 17:30 Christos Zoulas <christos@astron.com>
1611 * fix integer underflow in file_printf which can lead to
1612 to exploitable heap overflow (Jean-Sebastien Guay-Lero)
1614 2007-02-05 11:35 Christos Zoulas <christos@astron.com>
1616 * make socket/pipe reading more robust
1618 2007-01-25 16:01 Christos Zoulas <christos@astron.com>
1620 * Centralize all the tests in file_buffer.
1624 2007-01-18 05:29 Anon Ymous <do@not.spam.me>
1626 * Move the "type" detection code from parse() into its own table
1627 driven routine. This avoids maintaining multiple lists in
1630 * Add an optional conditional field (ust before the type field).
1631 This code is wrapped in "#ifdef ENABLE_CONDITIONALS" as it is
1634 2007-01-16 23:24 Anon Ymous <do@not.spam.me>
1636 * Fix an initialization bug in check_mem().
1638 2007-01-16 14:58 Anon Ymous <do@not.spam.me>
1640 * Add a "default" type to print a message if nothing previously
1641 matched at that level or since the last default at that
1642 level. This is useful for setting up switch-like statements.
1643 It can also be used to do if/else constructions without a
1644 redundant second test.
1646 * Fix the "x" special case test so that one can test for that
1649 * Allow "search" to search the entire buffer if the "/N"
1650 search count is missing.
1652 * Make "regex" work! It now starts its search at the
1653 specified offset and takes an (optional) "/N" line count to
1654 specify the search range; otherwise it searches to the end
1655 of the file. The match is now grabbed correctly for format
1656 strings and the offset set to the end of the match.
1658 * Add a "/s" flag to "regex" and "search" to set the offset to
1659 the start of the match. By default the offset is set to the
1660 end of the match, as it is with other tests. This is mostly
1663 * Make "search", "string" and "pstring" use the same
1664 file_strncmp() routine so that they support the same flags;
1665 "bestring16" and "lestring16" call the same routine, but
1666 with flags = 0. Also add a "/C" flag (in analogy to "/c")
1667 to ignore the case on uppercase (lowercase) characters in
1670 * Strict adherence to C style string escapes. A warnings are
1671 printed when compiling. Note: previously "\a" was
1672 incorrectly translated to 'a' instead of an <alert> (i.e.,
1673 BELL, typically 0x07).
1675 * Make this compile with "-Wall -Wextra" and all the warning
1676 flags used with WARNS=4 in the NetBSD source. Also make it
1679 * Many "cleanups" and hopefully not too many new bugs!
1681 2007-01-16 14:56 Anon Ymous <do@not.spam.me>
1683 * make several more files compile with gcc warnings
1684 on and also make them pass lint.
1686 2007-01-16 14:54 Anon Ymous <do@not.spam.me>
1688 * fix a puts()/putc() usage goof in file.c
1690 * make file.c compile with gcc warnings and pass lint
1692 2006-12-11 16:49 Christos Zoulas <christos@astron.com>
1694 * fix byteswapping issue
1696 * report the number of bytes we tried to
1697 allocate when allocation fails
1699 * add a few missed cases in the strength routine
1701 2006-12-08 16:32 Christos Zoulas <christos@astron.com>
1703 * store and print the line number of the magic
1704 entry for debugging.
1706 * if the magic entry did not print anything,
1707 don't treat it as a match
1709 * change the magic strength algorithm to take
1710 into account the relationship op.
1712 * fix a bug in search where we could accidentally
1715 * propagate the error return from match to
1718 2006-11-25 13:35 Christos Zoulas <christos@astron.com>
1720 * Don't store the current offset in the magic
1721 struct, because it needs to be restored and
1722 it was not done properly all the time. Bug
1723 found by: Arkadiusz Miskiewicz
1725 * Fix problem in the '\0' separator; and don't
1726 print it as an additional separator; print
1727 it as the only separator.
1729 2006-11-17 10:51 Christos Zoulas <christos@astron.com>
1731 * Added a -0 option to print a '\0' separator
1732 Etienne Buira <etienne.buira@free.fr>
1734 2006-10-31 15:14 Christos Zoulas <christos@astron.com>
1736 * Check offset before copying (Mike Frysinger)
1738 * merge duplicated code
1740 * add quad date support
1742 * make sure that we nul terminate desc (Ryoji Kanai)
1744 * don't process elf notes multiple times
1746 * allow -z to report empty compressed files
1748 * use calloc to initialize the ascii buffers (Jos van den Oever)
1750 2006-06-08 11:11 Christos Zoulas <christos@astron.com>
1752 * QNX fixes (Mike Gorchak)
1756 * FIFO checks (Dr. Werner Fink)
1758 * Linux ELF fixes (Dr. Werner Fink)
1760 * Magic format checks (Dr. Werner Fink)
1762 * Magic format function improvent (Karl Chen)
1764 2006-05-03 11:11 Christos Zoulas <christos@astron.com>
1766 * Pick up some elf changes and some constant fixes from SUSE
1768 * Identify gnu tar vs. posix tar
1770 * When keep going, don't print spurious newlines (Radek Vokal)
1772 2006-04-01 12:02 Christos Zoulas <christos@astron.com>
1774 * Use calloc instead of malloc (Mike Frysinger)
1776 * Fix configure script to detect wctypes.h (Mike Frysinger)
1778 2006-03-02 16:06 Christos Zoulas <christos@astron.com>
1780 * Print empty if the file is (Mike Frysinger)
1782 * Don't try to read past the end of the buffer (Mike Frysinger)
1784 * Sort magic entries by strength [experimental]
1786 2005-11-29 13:26 Christos Zoulas <christos@astron.com>
1788 * Use iswprint() to convert the output string.
1791 2005-10-31 8:54 Christos Zoulas <christos@astron.com>
1793 * Fix regression where the core info was not completely processed
1796 2005-10-20 11:15 Christos Zoulas <christos@astron.com>
1798 * Middle Endian magic (Diomidis Spinellis)
1800 2005-10-17 11:15 Christos Zoulas <christos@astron.com>
1802 * Open with O_BINARY for CYGWIN (Corinna Vinschen)
1804 * Don't close stdin (Arkadiusz Miskiewicz)
1806 * Look for note sections in non executables.
1808 2005-09-20 13:33 Christos Zoulas <christos@astron.com>
1810 * Don't print SVR4 Style in core files multiple times
1813 2005-08-27 04:09 Christos Zoulas <christos@astron.com>
1815 * Cygwin changes Corinna Vinschen
1817 2005-08-18 09:53 Christos Zoulas <christos@astron.com>
1819 * Remove erroreous mention of /etc/magic in the file man page
1820 This is gentoo bug 101639. (Mike Frysinger)
1822 * Cross-compile support and detection (Mike Frysinger)
1824 2005-08-12 10:17 Christos Zoulas <christos@astron.com>
1826 * Add -h flag and dereference symlinks if POSIXLY_CORRECT
1829 2005-07-29 13:57 Christos Zoulas <christos@astron.com>
1831 * Avoid search and regex buffer overflows (Kelledin)
1833 2005-07-12 11:48 Christos Zoulas <christos@astron.com>
1835 * Provide stub implementations for {v,}nsprintf() for older
1836 OS's that don't have them.
1837 * Change mbstate_t autoconf detection macro from AC_MBSTATE_T
1838 to AC_TYPE_MBSTATE_T.
1840 2005-06-25 11:48 Christos Zoulas <christos@astron.com>
1842 * Dynamically allocate the string buffers and make the
1843 default read size 256K.
1845 2005-06-01 00:00 Joerg Sonnenberger <joerg@britannica.bec.de>
1847 * Dragonfly ELF note support
1849 2005-03-14 00:00 Giuliano Bertoletti <gb@symbolic.it>
1851 * Avoid NULL pointer dereference in time conversion.
1853 2005-03-06 00:00 Joerg Walter <jwalt@mail.garni.ch>
1855 * Add indirect magic offset support, and search mode.
1857 2005-01-12 00:00 Stepan Kasal <kasal@ucw.cz>
1859 * src/ascmagic.c (file_ascmagic): Fix three bugs about text files:
1860 If a CRLF text file happens to have CR at offset HOWMANY - 1
1861 (currently 0xffff), it should not be counted as CR line
1863 If a line has length exactly MAXLINELEN, it should not yet be
1864 treated as a ``very long line'', as MAXLINELEN is ``longest sane
1866 With CRLF, the line length was not computed correctly, and even
1867 lines of length MAXLINELEN - 1 were treated as ``very long''.
1869 2004-12-07 14:15 Christos Zoulas <christos@astron.com>
1871 * bzip2 needs a lot of input buffer space on some files
1872 before it can begin uncompressing. This makes file -z
1873 fail on some bz2 files. Fix it by giving it a copy of
1874 the file descriptor to read as much as it wants if we
1875 have access to it. <christos@astron.com>
1877 2004-11-24 12:39 Christos Zoulas <christos@astron.com>
1879 * Stack smash fix, and ELF more conservative reading.
1880 Jakub Bogusz <qboosh@pld-linux.org>
1882 2004-11-20 18:50 Christos Zoulas <christos@astron.com>
1884 * New FreeBSD version parsing code:
1885 Jon Noack <noackjr@alumni.rice.edu>
1887 * Hackish support for ucs16 strings <christos@astron.com>
1889 2004-11-13 03:07 Christos Zoulas <christos@astron.com>
1891 * print the file name and line number in syntax errors.
1893 2004 10-12 10:50 Christos Zoulas <christos@astron.com>
1895 * Fix stack overwriting on 0 length strings: Tim Waugh
1896 <twaugh@redhat.com> Ned Ludd <solar@gentoo.org>
1898 2004-09-27 11:30 Christos Zoulas <christos@astron.com>
1900 * Remove 3rd and 4th copyright clause; approved by Ian Darwin.
1902 * Fix small memory leaks; caught by: Tamas Sarlos
1903 <stamas@csillag.ilab.sztaki.hu>
1905 2004-07-24 16:33 Christos Zoulas <christos@astron.com>
1907 * magic.mime update Danny Milosavljevic <danny.milo@gmx.net>
1909 * FreeBSD version update Oliver Eikemeier <eikemeier@fillmore-labs.com>
1911 * utime/utimes detection Ian Lance Taylor <ian@wasabisystems.com>
1913 * errors reading elf magic Jakub Bogusz <qboosh@pld-linux.org>
1915 2004-04-12 10:55 Christos Zoulas <christos@astron.com>
1917 * make sure that magic formats match magic types during compilation
1919 * fix broken sgi magic file
1921 2004-04-06 20:36 Christos Zoulas <christos@astron.com>
1923 * detect present of mbstate_t Petter Reinholdtsen <pere@hungry.com>
1927 2004-03-22 15:25 Christos Zoulas <christos@astron.com>
1929 * Lots of mime fixes
1930 (Joerg Ostertag) <ostertag@rechengilde.de>
1932 * FreeBSD ELF version handling
1933 (Edwin Groothuis) <edwin@mavetju.org>
1935 * correct cleanup in all cases; don't just close the file.
1936 (Christos Zoulas) <christos@astron.com>
1938 * add gettext message catalogue support
1939 (Michael Piefel) <piefel@debian.org>
1941 * better printout for unreadable files
1942 (Michael Piefel) <piefel@debian.org>
1944 * compensate for missing MAXPATHLEN
1945 (Michael Piefel) <piefel@debian.org>
1947 * add wide character string length computation
1948 (Michael Piefel) <piefel@debian.org>
1950 * Avoid infinite loops caused by bad elf alignments
1951 or name and description note sizes. Reported by
1952 (Mikael Magnusson) <mmikael@comhem.se>
1954 2004-03-09 13:55 Christos Zoulas <christos@astron.com>
1956 * Fix possible memory leak on error and add missing regfree
1957 (Dmitry V. Levin) <ldv@altlinux.org>
1959 2003-12-23 12:12 Christos Zoulas <christos@astron.com>
1961 * fix -k flag (Maciej W. Rozycki)
1963 2003-11-18 14:10 Christos Zoulas <christos@astron.com>
1965 * Try to give us much info as possible on corrupt elf files.
1966 (Willy Tarreau) <willy@w.ods.org>
1967 * Updated python bindings (Brett Funderburg)
1968 <brettf@deepfile.com>
1970 2003-11-11 15:03 Christos Zoulas <christos@astron.com>
1972 * Include file.h first, because it includes config.h
1973 breaks largefile test macros otherwise.
1974 (Paul Eggert <eggert@CS.UCLA.EDU> via
1975 Lars Hecking <lhecking@nmrc.ie>)
1977 2003-10-14 21:39 Christos Zoulas <christos@astron.com>
1979 * Python bindings (Brett Funderburg) <brettf@deepfile.com>
1980 * Don't lookup past the end of the buffer
1981 (Chad Hanson) <chanson@tcs-sec.com>
1982 * Add MAGIC_ERROR and api on magic_errno()
1984 2003-10-08 12:40 Christos Zoulas <christos@astron.com>
1986 * handle error conditions from compile as fatal
1987 (Antti Kantee) <pooka@netbsd.org>
1988 * handle magic filename parsing sanely
1990 * fix a memory leak (Illes Marton) <illes.marton@balabit.hu>
1991 * describe magic file handling
1992 (Bryan Henderson) <bryanh@giraffe-data.com>
1994 2003-09-12 15:09 Christos Zoulas <christos@astron.com>
1996 * update magic files.
1997 * remove largefile support from file.h; it breaks things on most OS's
1999 2003-08-10 10:25 Christos Zoulas <christos@astron.com>
2001 * fix unmapping'ing of mmaped files.
2003 2003-07-10 12:03 Christos Zoulas <christos@astron.com>
2005 * don't exit with -1 on error; always exit 1 (Marty Leisner)
2006 * restore utimes code.
2008 2003-06-10 17:03 Christos Zoulas <christos@astron.com>
2010 * make sure we don't access uninitialized memory.
2012 * #ifdef __cplusplus in magic.h
2014 2003-05-25 19:23 Christos Zoulas <christos@astron.com>
2016 * rename cvs magic file to revision to deal with
2017 case insensitive filesystems.
2019 2003-05-23 17:03 Christos Zoulas <christos@astron.com>
2021 * documentation fixes from Michael Piefel <piefel@debian.org>
2022 * magic fixes (various)
2023 * revert basename magic in .mgc name determination
2024 * buffer protection in uncompress,
2027 Maciej W. Rozycki <macro@ds2.pg.gda.pl
2029 2003-04-21 20:12 Christos Zoulas <christos@astron.com>
2033 2003-04-04 16:59 Christos Zoulas <christos@astron.com>
2035 * fix operand sort order in string.
2037 2003-04-02 17:30 Christos Zoulas <christos@astron.com>
2039 * cleanup namespace in magic.h
2041 2003-04-02 13:50 Christos Zoulas <christos@astron.com>
2043 * Magic additions (Alex Ott)
2044 * Fix bug that broke VPATH compilation (Peter Breitenlohner)
2046 2003-03-28 16:03 Christos Zoulas <christos@astron.com>
2048 * remove packed attribute from magic struct.
2049 * make the magic struct properly aligned.
2050 * bump version number of compiled files to 2.
2052 2003-03-27 13:10 Christos Zoulas <christos@astron.com>
2054 * separate tar detection and run it before softmagic.
2055 * fix reversed symlink test.
2056 * fix version printing.
2057 * make separator a string instead of a char.
2058 * update manual page and sort options.
2060 2003-03-26 11:00 Christos Zoulas <christos@astron.com>
2063 * make NULL in magic_file mean stdin
2064 * Fix "-" argument to file to pass NULL to magic_file
2065 * avoid pointer casts by using memcpy
2066 * rename magic_buf -> magic_buffer
2067 * keep only the first error
2068 * manual page: new sentence, new line
2069 * fix typo in api function (magic_buf -> magic_buffer)