OpenBSD CVS

CVS log for src/usr.bin/file/file.h


[BACK] Up to [local] / src / usr.bin / file

Request diff between arbitrary revisions


Default branch: MAIN


Revision 1.30 / (download) - annotate - [select for diffs], Sun Jun 12 21:10:42 2016 UTC (7 years, 11 months ago) by nicm
Branch: MAIN
CVS Tags: OPENBSD_7_5_BASE, OPENBSD_7_5, OPENBSD_7_4_BASE, OPENBSD_7_4, OPENBSD_7_3_BASE, OPENBSD_7_3, OPENBSD_7_2_BASE, OPENBSD_7_2, OPENBSD_7_1_BASE, OPENBSD_7_1, OPENBSD_7_0_BASE, OPENBSD_7_0, OPENBSD_6_9_BASE, OPENBSD_6_9, OPENBSD_6_8_BASE, OPENBSD_6_8, OPENBSD_6_7_BASE, OPENBSD_6_7, OPENBSD_6_6_BASE, OPENBSD_6_6, OPENBSD_6_5_BASE, OPENBSD_6_5, OPENBSD_6_4_BASE, OPENBSD_6_4, OPENBSD_6_3_BASE, OPENBSD_6_3, OPENBSD_6_2_BASE, OPENBSD_6_2, OPENBSD_6_1_BASE, OPENBSD_6_1, OPENBSD_6_0_BASE, OPENBSD_6_0, HEAD
Changes since 1.29: +1 -4 lines
Diff to previous 1.29 (colored)

Remove old unused prototype, from Ilya Kaliman.

Revision 1.29 / (download) - annotate - [select for diffs], Mon Apr 27 13:52:17 2015 UTC (9 years ago) by nicm
Branch: MAIN
CVS Tags: OPENBSD_5_9_BASE, OPENBSD_5_9, OPENBSD_5_8_BASE, OPENBSD_5_8
Changes since 1.28: +4 -1 lines
Diff to previous 1.28 (colored)

Use a systrace(4) sandbox with a short whitelist of allowed syscalls for
the file(1) child process. Based on similar code in ssh sandbox-systrace.c.
Idea and help from deraadt@.

Revision 1.28 / (download) - annotate - [select for diffs], Mon Apr 27 13:48:06 2015 UTC (9 years ago) by nicm
Branch: MAIN
Changes since 1.27: +2 -2 lines
Diff to previous 1.27 (colored)

Add a _file user and use for privsep, ok deraadt

Revision 1.27 / (download) - annotate - [select for diffs], Mon Apr 27 13:41:45 2015 UTC (9 years ago) by nicm
Branch: MAIN
Changes since 1.26: +4 -1 lines
Diff to previous 1.26 (colored)

Add simple privilege separation to file(1). Two processes, file
descriptors and a few other bits are opened in parent and passed to
child using imsg. Child currently drops to "nobody" but this will change.

Revision 1.26 / (download) - annotate - [select for diffs], Fri Apr 24 16:47:32 2015 UTC (9 years ago) by nicm
Branch: MAIN
Changes since 1.25: +1 -4 lines
Diff to previous 1.25 (colored)

Trying to drop privileges means we can't handle ARG_MAX arguments, so
remove it for now.

Revision 1.25 / (download) - annotate - [select for diffs], Fri Apr 24 16:24:11 2015 UTC (9 years ago) by nicm
Branch: MAIN
Changes since 1.24: +25 -379 lines
Diff to previous 1.24 (colored)

New implementation of the file(1) utility. This is a simplified,
modernised version with a nearly complete magic(5) parser but omits some
of the complex builtin tests (notably ELF) and has a reduced set of
options.

ok deraadt

Revision 1.24 / (download) - annotate - [select for diffs], Sun May 18 17:50:11 2014 UTC (10 years ago) by espie
Branch: MAIN
CVS Tags: OPENBSD_5_7_BASE, OPENBSD_5_7, OPENBSD_5_6_BASE, OPENBSD_5_6
Changes since 1.23: +3 -2 lines
Diff to previous 1.23 (colored)

use reallocarray
okay ian@, chl@

Revision 1.23 / (download) - annotate - [select for diffs], Wed Apr 17 15:01:26 2013 UTC (11 years, 1 month ago) by deraadt
Branch: MAIN
CVS Tags: OPENBSD_5_5_BASE, OPENBSD_5_5, OPENBSD_5_4_BASE, OPENBSD_5_4
Changes since 1.22: +3 -3 lines
Diff to previous 1.22 (colored)

variety of fixes to correct large time_t code.  it is quite broken upstream.
ok chl

Revision 1.22 / (download) - annotate - [select for diffs], Tue Oct 27 23:59:37 2009 UTC (14 years, 6 months ago) by deraadt
Branch: MAIN
CVS Tags: OPENBSD_5_3_BASE, OPENBSD_5_3, OPENBSD_5_2_BASE, OPENBSD_5_2, OPENBSD_5_1_BASE, OPENBSD_5_1, OPENBSD_5_0_BASE, OPENBSD_5_0, OPENBSD_4_9_BASE, OPENBSD_4_9, OPENBSD_4_8_BASE, OPENBSD_4_8, OPENBSD_4_7_BASE, OPENBSD_4_7
Changes since 1.21: +2 -10 lines
Diff to previous 1.21 (colored)

rcsid[] and sccsid[] and copyright[] are essentially unmaintained (and
unmaintainable).  these days, people use source.  these id's do not provide
any benefit, and do hurt the small install media
(the 33,000 line diff is essentially mechanical)
ok with the idea millert, ok dms

Revision 1.21 / (download) - annotate - [select for diffs], Thu Aug 27 16:26:43 2009 UTC (14 years, 8 months ago) by deraadt
Branch: MAIN
Changes since 1.20: +3 -3 lines
Diff to previous 1.20 (colored)

Appease gcc2 (I wish people would write in C, rather than "latest crap
gcc added")
ok millert miod

Revision 1.20 / (download) - annotate - [select for diffs], Fri Apr 24 18:54:34 2009 UTC (15 years ago) by chl
Branch: MAIN
CVS Tags: OPENBSD_4_6_BASE, OPENBSD_4_6
Changes since 1.19: +58 -28 lines
Diff to previous 1.19 (colored)

file update to 4.24

The '-i' switch is now enabled so file(1) can output mime type strings.

ok ian@
builk ports build test on amd64 by jasper@

ok ray@ gilles@ on a almost identical diff
builk ports build test on sparc64 on this almost identical diff by ajacoutot@
also tested by landry@

Revision 1.19 / (download) - annotate - [select for diffs], Thu May 8 01:40:56 2008 UTC (16 years ago) by chl
Branch: MAIN
CVS Tags: OPENBSD_4_5_BASE, OPENBSD_4_5, OPENBSD_4_4_BASE, OPENBSD_4_4
Changes since 1.18: +184 -47 lines
Diff to previous 1.18 (colored)

Update file to 4.21.

tested by ian@ sthen@

OK ian@, "move ahead with it" deraadt@

Revision 1.18 / (download) - annotate - [select for diffs], Mon Nov 26 09:28:34 2007 UTC (16 years, 5 months ago) by martynas
Branch: MAIN
CVS Tags: OPENBSD_4_3_BASE, OPENBSD_4_3
Changes since 1.17: +3 -3 lines
Diff to previous 1.17 (colored)

typos;  ok jmc@
sys/netinet/in_pcb.c and sys/net/bridgestp.c ok henning@
sys/dev/pci/bktr/* ok jakemsr@

Revision 1.16.10.1 / (download) - annotate - [select for diffs], Mon Jul 9 17:32:51 2007 UTC (16 years, 10 months ago) by ckuethe
Branch: OPENBSD_4_0
Changes since 1.16: +3 -3 lines
Diff to previous 1.16 (colored) next main 1.17 (colored)

Backport security fix.
Original commit by: dim@openbsd.org
Original commit message:
Fix possible heap overflow in file(1), aka CVE-2007-1536.

When writing data into a buffer in the file_printf() function, the
length of the unused portion of the buffer is not correctly tracked,
resulting in a buffer overflow when processing certain files.

Adapted from FreeBSD's SA-07:04.file fix, with ok and some minor
tweaks from canacar@ and ray@.

Revision 1.16.12.1 / (download) - annotate - [select for diffs], Mon Jul 9 17:32:48 2007 UTC (16 years, 10 months ago) by ckuethe
Branch: OPENBSD_4_1
Changes since 1.16: +3 -3 lines
Diff to previous 1.16 (colored) next main 1.17 (colored)

Backport security fix.
Original commit by: dim@openbsd.org
Original commit message:
Fix possible heap overflow in file(1), aka CVE-2007-1536.

When writing data into a buffer in the file_printf() function, the
length of the unused portion of the buffer is not correctly tracked,
resulting in a buffer overflow when processing certain files.

Adapted from FreeBSD's SA-07:04.file fix, with ok and some minor
tweaks from canacar@ and ray@.

Revision 1.17 / (download) - annotate - [select for diffs], Mon Jul 9 16:39:48 2007 UTC (16 years, 10 months ago) by dim
Branch: MAIN
CVS Tags: OPENBSD_4_2_BASE, OPENBSD_4_2
Changes since 1.16: +3 -3 lines
Diff to previous 1.16 (colored)

Fix possible heap overflow in file(1), aka CVE-2007-1536.

When writing data into a buffer in the file_printf() function, the
length of the unused portion of the buffer is not correctly tracked,
resulting in a buffer overflow when processing certain files.

Adapted from FreeBSD's SA-07:04.file fix, with ok and some minor
tweaks from canacar@ and ray@.

Revision 1.16 / (download) - annotate - [select for diffs], Wed May 19 02:32:35 2004 UTC (20 years ago) by tedu
Branch: MAIN
CVS Tags: OPENBSD_4_1_BASE, OPENBSD_4_0_BASE, OPENBSD_3_9_BASE, OPENBSD_3_9, OPENBSD_3_8_BASE, OPENBSD_3_8, OPENBSD_3_7_BASE, OPENBSD_3_7, OPENBSD_3_6_BASE, OPENBSD_3_6
Branch point for: OPENBSD_4_1, OPENBSD_4_0
Changes since 1.15: +167 -94 lines
Diff to previous 1.15 (colored)

big update to file 4.09.  ok ian@

Revision 1.15 / (download) - annotate - [select for diffs], Sun Nov 9 20:13:57 2003 UTC (20 years, 6 months ago) by otto
Branch: MAIN
CVS Tags: OPENBSD_3_5_BASE, OPENBSD_3_5
Changes since 1.14: +2 -2 lines
Diff to previous 1.14 (colored)

Typos in comments from Jared Yanovich <jjy2+ at pitt dot edu>

Revision 1.14 / (download) - annotate - [select for diffs], Wed Jul 2 21:04:10 2003 UTC (20 years, 10 months ago) by deraadt
Branch: MAIN
CVS Tags: OPENBSD_3_4_BASE, OPENBSD_3_4
Changes since 1.13: +4 -1 lines
Diff to previous 1.13 (colored)

protos

Revision 1.13 / (download) - annotate - [select for diffs], Fri Jun 13 18:31:14 2003 UTC (20 years, 11 months ago) by deraadt
Branch: MAIN
Changes since 1.12: +1 -6 lines
Diff to previous 1.12 (colored)

ian gives permission for 3/4 removal

Revision 1.10.2.1 / (download) - annotate - [select for diffs], Wed Mar 12 02:14:16 2003 UTC (21 years, 2 months ago) by margarida
Branch: OPENBSD_3_2
Changes since 1.10: +14 -2 lines
Diff to previous 1.10 (colored) next main 1.11 (colored)

Pull patch from current.
Fix by ian@
Bring in readelf.c from Christos' version 3.41 to head off a local
stack attack noted by iDefense, and for more complete 64-bit ELF support.
Add hand-made config.h to avoid running configure but still be able
to use Christos' code.  In print.c add error(...)-->err(1,...) wrapper.
Tested on i386, sparc64, macppc.

ok millert@

Revision 1.12 / (download) - annotate - [select for diffs], Tue Mar 11 21:26:26 2003 UTC (21 years, 2 months ago) by ian
Branch: MAIN
CVS Tags: OPENBSD_3_3_BASE, OPENBSD_3_3
Changes since 1.11: +31 -23 lines
Diff to previous 1.11 (colored)

Replace TPUM license with standard BSD-style license

Revision 1.11 / (download) - annotate - [select for diffs], Mon Mar 3 22:24:08 2003 UTC (21 years, 2 months ago) by ian
Branch: MAIN
Changes since 1.10: +14 -2 lines
Diff to previous 1.10 (colored)

Bring in readelf.c from Christos' version 3.41 to head off a local
stack attack noted by iDefense, and for more complete 64-bit ELF support.
Add hand-made config.h to avoid running configure but still be able
to use Christos' code.  In print.c add error(...)-->err(1,...) wrapper.
Tested on i386, sparc64, macppc.

Revision 1.10 / (download) - annotate - [select for diffs], Wed Jun 5 13:46:44 2002 UTC (21 years, 11 months ago) by itojun
Branch: MAIN
CVS Tags: OPENBSD_3_2_BASE
Branch point for: OPENBSD_3_2
Changes since 1.9: +8 -12 lines
Diff to previous 1.9 (colored)

use types in inttypes.h directly

Revision 1.9 / (download) - annotate - [select for diffs], Sun Feb 17 19:42:30 2002 UTC (22 years, 3 months ago) by millert
Branch: MAIN
CVS Tags: OPENBSD_3_1_BASE, OPENBSD_3_1
Changes since 1.8: +1 -12 lines
Diff to previous 1.8 (colored)

Manual cleanup of remaining userland __P use (excluding packages maintained outside the tree)

Revision 1.8 / (download) - annotate - [select for diffs], Sat Feb 16 21:27:46 2002 UTC (22 years, 3 months ago) by millert
Branch: MAIN
Changes since 1.7: +17 -17 lines
Diff to previous 1.7 (colored)

Part one of userland __P removal.  Done with a simple regexp with some minor hand editing to make comments line up correctly.  Another pass is forthcoming that handles the cases that could not be done automatically.

Revision 1.7 / (download) - annotate - [select for diffs], Sun Sep 26 20:47:28 1999 UTC (24 years, 7 months ago) by ian
Branch: MAIN
CVS Tags: OPENBSD_3_0_BASE, OPENBSD_3_0, OPENBSD_2_9_BASE, OPENBSD_2_9, OPENBSD_2_8_BASE, OPENBSD_2_8, OPENBSD_2_7_BASE, OPENBSD_2_7, OPENBSD_2_6_BASE, OPENBSD_2_6
Changes since 1.6: +2 -2 lines
Diff to previous 1.6 (colored)

Increase MAXMAGIS again, and change the reallocation - don't need to
skimp on memory as much as when this code was written! (Thanks Theo).

Revision 1.6 / (download) - annotate - [select for diffs], Tue Oct 13 07:51:51 1998 UTC (25 years, 7 months ago) by deraadt
Branch: MAIN
CVS Tags: OPENBSD_2_5_BASE, OPENBSD_2_5, OPENBSD_2_4_BASE, OPENBSD_2_4
Changes since 1.5: +4 -3 lines
Diff to previous 1.5 (colored)

unsigned char fix; rahnds

Revision 1.5 / (download) - annotate - [select for diffs], Fri Jul 10 15:05:21 1998 UTC (25 years, 10 months ago) by mickey
Branch: MAIN
Changes since 1.4: +1 -3 lines
Diff to previous 1.4 (colored)

err/warn

Revision 1.4 / (download) - annotate - [select for diffs], Fri Jul 25 21:05:26 1997 UTC (26 years, 10 months ago) by mickey
Branch: MAIN
CVS Tags: OPENBSD_2_3_BASE, OPENBSD_2_3, OPENBSD_2_2_BASE, OPENBSD_2_2
Changes since 1.3: +2 -2 lines
Diff to previous 1.3 (colored)

#if __STDC__ --> #ifdef __STDC__

Revision 1.3 / (download) - annotate - [select for diffs], Sun Feb 9 23:58:23 1997 UTC (27 years, 3 months ago) by millert
Branch: MAIN
CVS Tags: OPENBSD_2_1_BASE, OPENBSD_2_1
Changes since 1.2: +28 -8 lines
Diff to previous 1.2 (colored)

Updates file(1) to version 3.22 by way to NetBSD.

Revision 1.2 / (download) - annotate - [select for diffs], Wed Jun 26 05:32:57 1996 UTC (27 years, 10 months ago) by deraadt
Branch: MAIN
CVS Tags: OPENBSD_2_0_BASE, OPENBSD_2_0
Changes since 1.1: +1 -1 lines
Diff to previous 1.1 (colored)

rcsid

Revision 1.1.1.1 / (download) - annotate - [select for diffs] (vendor branch), Wed Oct 18 08:45:09 1995 UTC (28 years, 7 months ago) by deraadt
CVS Tags: netbsd_1_1
Changes since 1.1: +0 -0 lines
Diff to previous 1.1 (colored)

initial import of NetBSD tree

Revision 1.1 / (download) - annotate - [select for diffs], Wed Oct 18 08:45:09 1995 UTC (28 years, 7 months ago) by deraadt
Branch: MAIN

Initial revision

This form allows you to request diff's between any two revisions of a file. You may select a symbolic revision name using the selection box or you may type in a numeric name using the type-in text box.