Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/netbsd-3-0]: src Pull up following revision(s) (requested by pooka in ti...



details:   https://anonhg.NetBSD.org/src/rev/4192f8993bff
branches:  netbsd-3-0
changeset: 579422:4192f8993bff
user:      ghen <ghen%NetBSD.org@localhost>
date:      Sun Jun 24 19:43:05 2007 +0000

description:
Pull up following revision(s) (requested by pooka in ticket #1804):
        dist/file/: synced with HEAD on 20070615
        distrib/sets/lists/base/shl.elf: revision 1.222
        distrib/sets/lists/base/shl.mi: revision 1.375 via patch
        lib/Makefile: revision 1.108 via patch
        lib/libmagic/Makefile: revision 1.5
        lib/libmagic/config.h: patch
        lib/libmagic/shlib_version: revision 1.3-1.4
        tools/file/Makefile: revision 1.4
        usr.bin/file/Makefile: revision 1.51-1.53
Update file(1) to version 4.21, including security fixes (CVE-2007-1536 and
CVE-2007-2799).

diffstat:

 dist/file/ChangeLog                   |    270 +
 dist/file/LEGAL.NOTICE                |      4 +-
 dist/file/MAINT                       |     50 +-
 dist/file/Makefile.in                 |    491 +-
 dist/file/README                      |      5 +-
 dist/file/aclocal.m4                  |   9590 ++++++++-----
 dist/file/config.guess                |    341 +-
 dist/file/config.h.in                 |     84 +-
 dist/file/config.sub                  |    209 +-
 dist/file/configure                   |  22492 ++++++++++++++++++++++++-------
 dist/file/configure.in                |     21 +-
 dist/file/depcomp                     |    191 +-
 dist/file/doc/Makefile.in             |    342 +-
 dist/file/doc/file.1                  |    597 +-
 dist/file/doc/libmagic.3              |     28 +-
 dist/file/doc/magic.5                 |    456 +-
 dist/file/file2netbsd                 |     11 +-
 dist/file/install-sh                  |    446 +-
 dist/file/ltmain.sh                   |   3408 +++-
 dist/file/magic/Localstuff            |      2 +-
 dist/file/magic/Makefile.am           |     22 +-
 dist/file/magic/Makefile.in           |    280 +-
 dist/file/magic/magdir/adventure      |     54 +-
 dist/file/magic/magdir/amigaos        |      7 +
 dist/file/magic/magdir/animation      |     48 +-
 dist/file/magic/magdir/apple          |     41 +
 dist/file/magic/magdir/archive        |    457 +-
 dist/file/magic/magdir/audio          |    173 +-
 dist/file/magic/magdir/bFLT           |     12 -
 dist/file/magic/magdir/basis          |     16 +
 dist/file/magic/magdir/bflt           |     12 +
 dist/file/magic/magdir/bout           |      2 +-
 dist/file/magic/magdir/btsnoop        |     11 +
 dist/file/magic/magdir/c-lang         |      4 +-
 dist/file/magic/magdir/c64            |     19 +-
 dist/file/magic/magdir/cad            |     47 +-
 dist/file/magic/magdir/cafebabe       |     21 +
 dist/file/magic/magdir/commands       |      5 +-
 dist/file/magic/magdir/compress       |     33 +-
 dist/file/magic/magdir/console        |     58 +-
 dist/file/magic/magdir/cracklib       |     13 +
 dist/file/magic/magdir/ctags          |      2 +-
 dist/file/magic/magdir/diff           |      2 +
 dist/file/magic/magdir/digital        |      4 +-
 dist/file/magic/magdir/dump           |     12 +
 dist/file/magic/magdir/editors        |      4 +
 dist/file/magic/magdir/elf            |    144 +-
 dist/file/magic/magdir/filesystems    |    831 +-
 dist/file/magic/magdir/flash          |      3 +
 dist/file/magic/magdir/fonts          |      3 +
 dist/file/magic/magdir/fsav           |     71 +-
 dist/file/magic/magdir/gnu            |      6 +-
 dist/file/magic/magdir/iff            |     32 +-
 dist/file/magic/magdir/images         |     17 +-
 dist/file/magic/magdir/java           |      8 +-
 dist/file/magic/magdir/linux          |     70 +-
 dist/file/magic/magdir/lisp           |     16 +-
 dist/file/magic/magdir/mach           |     62 +-
 dist/file/magic/magdir/maple          |      1 -
 dist/file/magic/magdir/mathematica    |      2 +-
 dist/file/magic/magdir/mime           |      2 +-
 dist/file/magic/magdir/mips           |      4 +-
 dist/file/magic/magdir/misctools      |     12 +-
 dist/file/magic/magdir/msdos          |    490 +-
 dist/file/magic/magdir/mup            |     22 +
 dist/file/magic/magdir/ncr            |      4 +-
 dist/file/magic/magdir/os2            |      2 +-
 dist/file/magic/magdir/os400          |     37 +
 dist/file/magic/magdir/perl           |     25 +-
 dist/file/magic/magdir/psion          |      6 +-
 dist/file/magic/magdir/python         |      5 +
 dist/file/magic/magdir/revision       |      6 +-
 dist/file/magic/magdir/riff           |      8 +
 dist/file/magic/magdir/scientific     |     60 +
 dist/file/magic/magdir/sgi            |     12 +-
 dist/file/magic/magdir/sgml           |      3 +-
 dist/file/magic/magdir/sharc          |      2 +-
 dist/file/magic/magdir/sql            |     27 +
 dist/file/magic/magdir/sun            |      8 +
 dist/file/magic/magdir/sysex          |    127 +-
 dist/file/magic/magdir/tex            |     28 +-
 dist/file/magic/magdir/tgif           |      2 +-
 dist/file/magic/magdir/unicode        |     15 +
 dist/file/magic/magdir/varied.out     |     10 +
 dist/file/magic/magdir/varied.script  |      2 +-
 dist/file/magic/magdir/vmware         |      7 -
 dist/file/magic/magdir/wordprocessors |     31 +-
 dist/file/magic/magdir/xwindows       |      2 +-
 dist/file/magic/magic.mime            |    123 +-
 dist/file/magic/magic2mime            |      5 +-
 dist/file/missing                     |    146 +-
 dist/file/mkinstalldirs               |    171 +-
 dist/file/python/Makefile.in          |    252 +-
 dist/file/src/Makefile.am             |      2 +-
 dist/file/src/Makefile.in             |    435 +-
 dist/file/src/apprentice.c            |   1188 +-
 dist/file/src/apptype.c               |      7 +-
 dist/file/src/ascmagic.c              |    102 +-
 dist/file/src/compress.c              |     98 +-
 dist/file/src/file.c                  |    118 +-
 dist/file/src/file.h                  |    262 +-
 dist/file/src/fsmagic.c               |      8 +-
 dist/file/src/funcs.c                 |    230 +-
 dist/file/src/is_tar.c                |     16 +-
 dist/file/src/magic.c                 |    189 +-
 dist/file/src/magic.h                 |     33 +-
 dist/file/src/names.h                 |      6 +-
 dist/file/src/patchlevel.h            |     33 +-
 dist/file/src/print.c                 |    112 +-
 dist/file/src/readelf.c               |    515 +-
 dist/file/src/readelf.h               |      4 +-
 dist/file/src/softmagic.c             |   1490 +-
 dist/file/src/tar.h                   |     77 +-
 dist/file/src/test.c                  |     10 +-
 distrib/sets/lists/base/shl.elf       |      4 +-
 distrib/sets/lists/base/shl.mi        |      4 +-
 lib/Makefile                          |      7 +-
 lib/libmagic/Makefile                 |      3 +-
 lib/libmagic/config.h                 |    127 +-
 lib/libmagic/shlib_version            |      6 +-
 tools/file/Makefile                   |      4 +-
 usr.bin/file/Makefile                 |      6 +-
 122 files changed, 34936 insertions(+), 13479 deletions(-)

diffs (truncated from 60920 to 300 lines):

diff -r 8e20ac8120da -r 4192f8993bff dist/file/ChangeLog
--- a/dist/file/ChangeLog       Sat Jun 23 19:51:43 2007 +0000
+++ b/dist/file/ChangeLog       Sun Jun 24 19:43:05 2007 +0000
@@ -1,3 +1,273 @@
+2007-05-24 10:00 Christos Zoulas <christos%zoulas.com@localhost>
+
+       * Fix another integer overflow (Colin Percival)
+
+2007-03-26 13:58 Christos Zoulas <christos%zoulas.com@localhost>
+
+       * make sure that all of struct magic_set is initialized appropriately
+         (Brett)
+
+2007-03-25 17:44 Christos Zoulas <christos%zoulas.com@localhost>
+
+       * reset left bytes in the buffer (Dmitry V. Levin)
+
+       * compilation failed with COMPILE_ONLY and ENABLE_CONDITIONALS
+         (Peter Avalos)
+
+2007-03-15 10:51 Christos Zoulas <christos%zoulas.com@localhost>
+
+       * fix fortran and nroff reversed tests (Dmitry V. Levin)
+       
+       * fix exclude option (Dmitry V. Levin)
+
+2007-02-08 17:30 Christos Zoulas <christos%zoulas.com@localhost>
+
+       * fix integer underflow in file_printf which can lead to
+         to exploitable heap overflow (Jean-Sebastien Guay-Lero)
+
+2007-02-05 11:35 Christos Zoulas <christos%zoulas.com@localhost>
+
+       * make socket/pipe reading more robust
+
+2007-01-25 16:01 Christos Zoulas <christos%zoulas.com@localhost>
+
+       * Centralize all the tests in file_buffer.
+
+       * Add exclude flag.
+
+2007-01-18 05:29 Anon Ymous <do%not.spam.me@localhost>
+       
+       * Move the "type" detection code from parse() into its own table
+         driven routine.  This avoids maintaining multiple lists in
+         file.h.
+
+       * Add an optional conditional field (ust before the type field).
+         This code is wrapped in "#ifdef ENABLE_CONDITIONALS" as it is
+         likely to go away.
+       
+2007-01-16 23:24 Anon Ymous <do%not.spam.me@localhost>
+
+       * Fix an initialization bug in check_mem().
+
+2007-01-16 14:58 Anon Ymous <do%not.spam.me@localhost>
+
+       * Add a "default" type to print a message if nothing previously
+         matched at that level or since the last default at that
+         level.  This is useful for setting up switch-like statements.
+         It can also be used to do if/else constructions without a
+         redundant second test.
+
+       * Fix the "x" special case test so that one can test for that
+         string with "=x".
+
+       * Allow "search" to search the entire buffer if the "/N"
+         search count is missing.
+
+       * Make "regex" work!  It now starts its search at the
+         specified offset and takes an (optional) "/N" line count to
+         specify the search range; otherwise it searches to the end
+         of the file.  The match is now grabbed correctly for format
+         strings and the offset set to the end of the match.
+
+       * Add a "/s" flag to "regex" and "search" to set the offset to
+         the start of the match.  By default the offset is set to the
+         end of the match, as it is with other tests.  This is mostly
+         useful for "regex".
+
+       * Make "search", "string" and "pstring" use the same
+         file_strncmp() routine so that they support the same flags;
+         "bestring16" and "lestring16" call the same routine, but
+         with flags = 0.  Also add a "/C" flag (in analogy to "/c")
+         to ignore the case on uppercase (lowercase) characters in
+         the test string.
+
+       * Strict adherence to C style string escapes.  A warnings are
+         printed when compiling.  Note: previously "\a" was
+         incorrectly translated to 'a' instead of an <alert> (i.e.,
+         BELL, typically 0x07).
+
+       * Make this compile with "-Wall -Wextra" and all the warning
+         flags used with WARNS=4 in the NetBSD source.  Also make it
+         pass lint.
+
+       * Many "cleanups" and hopefully not too many new bugs!
+
+2007-01-16 14:56 Anon Ymous <do%not.spam.me@localhost>
+
+       * make several more files compile with gcc warnings
+         on and also make them pass lint.
+
+2007-01-16 14:54 Anon Ymous <do%not.spam.me@localhost>
+
+       * fix a puts()/putc() usage goof in file.c
+
+       * make file.c compile with gcc warnings and pass lint
+
+2006-12-11 16:49 Christos Zoulas <christos%zoulas.com@localhost>
+
+       * fix byteswapping issue
+
+       * report the number of bytes we tried to
+         allocate when allocation fails
+
+       * add a few missed cases in the strength routine
+
+2006-12-08 16:32 Christos Zoulas <christos%zoulas.com@localhost>
+
+       * store and print the line number of the magic
+         entry for debugging.         
+
+       * if the magic entry did not print anything,
+         don't treat it as a match
+
+       * change the magic strength algorithm to take
+         into account the relationship op.
+
+       * fix a bug in search where we could accidentally
+         return a match.
+
+       * propagate the error return from match to
+         file_softmagic.
+
+2006-11-25 13:35 Christos Zoulas <christos%zoulas.com@localhost>
+       
+       * Don't store the current offset in the magic
+         struct, because it needs to be restored and
+         it was not done properly all the time. Bug
+         found by: Arkadiusz Miskiewicz
+
+       * Fix problem in the '\0' separator; and don't
+         print it as an additional separator; print
+         it as the only separator.
+
+2006-11-17 10:51 Christos Zoulas <christos%zoulas.com@localhost>
+
+       * Added a -0 option to print a '\0' separator
+         Etienne Buira <etienne.buira%free.fr@localhost>
+
+2006-10-31 15:14 Christos Zoulas <christos%zoulas.com@localhost>
+
+       * Check offset before copying (Mike Frysinger)
+
+       * merge duplicated code
+
+       * add quad date support
+
+       * make sure that we nul terminate desc (Ryoji Kanai)
+
+       * don't process elf notes multiple times
+
+       * allow -z to report empty compressed files
+
+       * use calloc to initialize the ascii buffers (Jos van den Oever)
+
+2006-06-08 11:11 Christos Zoulas <christos%zoulas.com@localhost>
+
+       * QNX fixes (Mike Gorchak)
+
+       * Add quad support.
+
+       * FIFO checks (Dr. Werner Fink)
+
+       * Linux ELF fixes (Dr. Werner Fink)
+
+       * Magic format checks (Dr. Werner Fink)
+
+       * Magic format function improvent (Karl Chen)
+
+2006-05-03 11:11 Christos Zoulas <christos%zoulas.com@localhost>
+
+       * Pick up some elf changes and some constant fixes from SUSE
+
+       * Identify gnu tar vs. posix tar
+
+       * When keep going, don't print spurious newlines (Radek Vokál)
+
+2006-04-01 12:02 Christos Zoulas <christos%zoulas.com@localhost>
+
+       * Use calloc instead of malloc (Mike Frysinger)
+
+       * Fix configure script to detect wctypes.h (Mike Frysinger)
+
+2006-03-02 16:06 Christos Zoulas <christos%zoulas.com@localhost>
+
+       * Print empty if the file is (Mike Frysinger)
+
+       * Don't try to read past the end of the buffer (Mike Frysinger)
+
+       * Sort magic entries by strength [experimental]
+
+2005-11-29 13:26 Christos Zoulas <christos%zoulas.com@localhost>
+
+       * Use iswprint() to convert the output string.
+           (Bastien Nocera)
+
+2005-10-31 8:54 Christos Zoulas <christos%zoulas.com@localhost>
+
+       * Fix regression where the core info was not completely processed
+           (Radek Vokál)
+
+2005-10-20 11:15 Christos Zoulas <christos%zoulas.com@localhost>
+
+       * Middle Endian magic (Diomidis Spinellis)
+
+2005-10-17 11:15 Christos Zoulas <christos%zoulas.com@localhost>
+
+       * Open with O_BINARY for CYGWIN (Corinna Vinschen)
+
+       * Don't close stdin (Arkadiusz Miskiewicz)
+
+       * Look for note sections in non executables.
+
+2005-09-20 13:33 Christos Zoulas <christos%zoulas.com@localhost>
+       
+       * Don't print SVR4 Style in core files multiple times
+           (Radek Vokál)
+
+2005-08-27 04:09 Christos Zoulas <christos%zoulas.com@localhost>
+
+       * Cygwin changes Corinna Vinschen
+
+2005-08-18 09:53 Christos Zoulas <christos%zoulas.com@localhost>
+
+       * Remove erroreous mention of /etc/magic in the file man page
+         This is gentoo bug 101639. (Mike Frysinger) 
+
+       * Cross-compile support and detection (Mike Frysinger) 
+
+2005-08-12 10:17 Christos Zoulas <christos%zoulas.com@localhost>
+
+       * Add -h flag and dereference symlinks if POSIXLY_CORRECT
+         is set.
+
+2005-07-29 13:57 Christos Zoulas <christos%zoulas.com@localhost>
+
+       * Avoid search and regex buffer overflows (Kelledin)
+
+2005-07-12 11:48 Christos Zoulas <christos%zoulas.com@localhost>
+
+       * Provide stub implementations for {v,}nsprintf() for older
+         OS's that don't have them.
+       * Change mbstate_t autoconf detection macro from AC_MBSTATE_T
+         to AC_TYPE_MBSTATE_T.
+
+2005-06-25 11:48 Christos Zoulas <christos%zoulas.com@localhost>
+
+       * Dynamically allocate the string buffers and make the
+         default read size 256K.
+
+2005-06-01 00:00 Joerg Sonnenberger <joerg%britannica.bec.de@localhost>
+
+       * Dragonfly ELF note support
+
+2005-03-14 00:00 Giuliano Bertoletti <gb%symbolic.it@localhost>
+
+       * Avoid NULL pointer dereference in time conversion.
+
+2005-03-06 00:00  Joerg Walter <jwalt%mail.garni.ch@localhost>
+       
+       * Add indirect magic offset support, and search mode.
+
 2005-01-12 00:00  Stepan Kasal  <kasal%ucw.cz@localhost>
 
         * src/ascmagic.c (file_ascmagic): Fix three bugs about text files:
diff -r 8e20ac8120da -r 4192f8993bff dist/file/LEGAL.NOTICE
--- a/dist/file/LEGAL.NOTICE    Sat Jun 23 19:51:43 2007 +0000
+++ b/dist/file/LEGAL.NOTICE    Sun Jun 24 19:43:05 2007 +0000
@@ -1,7 +1,7 @@
-Id: LEGAL.NOTICE,v 1.14 2004/09/11 19:15:56 christos Exp
+$File: LEGAL.NOTICE,v 1.15 2006/05/03 18:48:33 christos Exp $
 Copyright (c) Ian F. Darwin 1986, 1987, 1989, 1990, 1991, 1992, 1994, 1995.
 Software written by Ian F. Darwin and others;
-maintained 1994-2004 Christos Zoulas.
+maintained 1994- Christos Zoulas.
 
 This software is not subject to any export provision of the United States
 Department of Commerce, and may be exported to any country or planet.
diff -r 8e20ac8120da -r 4192f8993bff dist/file/MAINT
--- a/dist/file/MAINT   Sat Jun 23 19:51:43 2007 +0000
+++ b/dist/file/MAINT   Sun Jun 24 19:43:05 2007 +0000
@@ -1,33 +1,45 @@
-Id: MAINT,v 1.5 2003/03/23 04:36:37 christos Exp
+$File: MAINT,v 1.9 2007/01/19 21:15:27 christos Exp $
 
 Maintenance notes:
 
 I am continuing to maintain the file command. I welcome your help,



Home | Main Index | Thread Index | Old Index