306379 |
27-Sep-2016 |
emaste |
Merge from stable/11 bspatch, portsnap, and libarchive fixes:
=== bspatch ===
MFS r306213: bspatch Capsicumization, sanity checks, and other improvements
r304691: bspatch: apply style(9)
Make style changes (and trivial refactoring of open calls) now in order to reduce noise in diffs for future capsicum changes.
r304807 (allanjude): Capsicumize bspatch
Move all of the fopen() and open() calls to the top of main()
Restrict each FD to least privilege (read/seek only, write only, etc)
cap_enter(), and make all except the output FD read/seek only.
r304821: bspatch: remove output file in the case of error
r305486: bspatch: add sanity checks on sizes to avoid integer overflow
Note that this introduces an explicit 2GB limit, but this was already implicit in variable and function argument types.
This is based on the "non-cryptanalytic attacks against freebsd update components" anonymous gist. Further refinement is planned.
r305737: bspatch: remove superfluous newlines from errx strings
r305822: bspatch: use #define for header size instead of magic number
r306026: bspatch: Remove backwards-compatibility sys/capability.h support
bspatch previously included sys/capability.h or sys/capsicum.h based on __FreeBSD_version, as FreeBSD is the upstream for bsdiff and we may see this file incorporated into other third-party software.
The Capsicum header is now installed as sys/capsicum.h in stable/10 and FreeBSD 10.3, so we can just use sys/capsicum.h and simplify the logic.
With this change, bspatch is identical between head, stable/11 and releng/11.0.
=== portsnap ===
MFS r305648 (delphij): MFC r305469:
Ensure that we always open only files that is named by explicitly using shell redirections instead of having gzip(1) to decide what file to open.
Issue reported in the "non-cryptanalytic attacks against freebsd update components" anonymous gist.
=== libarchive ===
MFS r305754 (mm): MFC r305422:
Sync libarchive with vendor
Vendor issues fixed: PR #777: Multiple bugfixes for setup_acls()
This includes a bugfix for a bug that caused ACLs not to be read properly for files and directories inside subdirectories and as a result not being stored or being incorrectly stored in tar archives.
MFS r306321 (mm): MFC r305819:
Sync libarchive with vendor including important security fixes.
Issues fixed (FreeBSD): PR #778: ACL error handling Issue #745: Symlink check prefix optimization is too aggressive Issue #746: Hard links with data can evade sandboxing restrictions
This update fixes the vulnerability #3 and vulnerability #4 as reported in "non-cryptanalytic attacks against FreeBSD update components". https://gist.github.com/anonymous/e48209b03f1dd9625a992717e7b89c4f
Fix for vulnerability #2 has already been merged.
Approved by: re (gjb), so (glebius) |
303975 |
11-Aug-2016 |
gjb |
Copy stable/11@r303970 to releng/11.0 as part of the 11.0-RELEASE cycle.
Prune svn:mergeinfo from the new branch, and rename it to RC1.
Update __FreeBSD_version.
Use the quarterly branch for the default FreeBSD.conf pkg(8) repo and the dvd1.iso packages population.
Approved by: re (implicit) Sponsored by: The FreeBSD Foundation |
303300 |
25-Jul-2016 |
delphij |
Fix bspatch heap overflow vulnerability.
Obtained from: Chromium Reported by: Lu Tung-Pin Security: FreeBSD-SA-16:25.bspatch Approved by: re (so@ blanket)
|
302408 |
08-Jul-2016 |
gjb |
Copy head@r302406 to stable/11 as part of the 11.0-RELEASE cycle. Prune svn:mergeinfo from the new branch, as nothing has been merged here.
Additional commits post-branch will follow.
Approved by: re (implicit) Sponsored by: The FreeBSD Foundation
|
298089 |
15-Apr-2016 |
pfg |
Cleanup unnecessary semicolons from utilities we all love.
|
290336 |
03-Nov-2015 |
ache |
Check for (old|new)size + 1 overflows off_t.
PR: 204230 MFC after: 1 week
|
290329 |
03-Nov-2015 |
ache |
Use meaningful errno for ssize_t overflow in read(). Catch size_t overflow in malloc().
PR: 204230 MFC after: 1 week
|
284345 |
13-Jun-2015 |
sjg |
Add META_MODE support.
Off by default, build behaves normally. WITH_META_MODE we get auto objdir creation, the ability to start build from anywhere in the tree.
Still need to add real targets under targets/ to build packages.
Differential Revision: D2796 Reviewed by: brooks imp
|
275042 |
25-Nov-2014 |
bapt |
Convert to usr.bin/ to LIBADD Reduce overlinking
|
267773 |
23-Jun-2014 |
bapt |
use .Mt to mark up email addresses consistently (part3)
PR: 191174 Submitted by: Franco Fichtner <franco at lastsummer.de>
|
264823 |
23-Apr-2014 |
ed |
Make usage printing more consistent with other tools.
- Introduce a separate usage() function. - Don't use argv[0]. Directly name the application, as we do elsewhere. - Don't prepend the application name. - Don't print two newlines.
|
233648 |
29-Mar-2012 |
eadler |
Remove trailing whitespace per mdoc lint warning
Disussed with: gavin No objection from: doc Approved by: joel MFC after: 3 days
|
229910 |
10-Jan-2012 |
eadler |
Silence bogus warning when compiling with gcc46: error: 'pos' may be used uninitialized in this function
Reviewed by: cperciva Approved by: dim MFC after: 3 days
|
208027 |
13-May-2010 |
uqs |
mdoc: move CAVEATS, BUGS and SECURITY CONSIDERATIONS sections to the bottom of the manpages and order them consistently.
GNU groff doesn't care about the ordering, and doesn't even mention CAVEATS and SECURITY CONSIDERATIONS as common sections and where to put them.
Found by: mdocml lint run Reviewed by: ru
|
201386 |
02-Jan-2010 |
ed |
Build usr.bin/ with WARNS=6 by default.
Also add some missing $FreeBSD$ to keep svn happy.
|
198671 |
30-Oct-2009 |
cperciva |
Add notes pointing out that bsdiff does not store file hashes and bspatch thus does not verify file hashes, and that consequently it is recommended that users store hashes separately and verify files before and after running bspatch.
Requested by: BugMagnet MFC after: 1 week
|
164922 |
05-Dec-2006 |
cperciva |
Portability fix for non-POSIX operating systems: Open files in binary mode.
PR: bin/106358 Submitted by: techtonik at php dot net
|
152573 |
18-Nov-2005 |
ru |
Fix up markup.
|
148773 |
06-Aug-2005 |
cperciva |
Include ../Makefile.inc, since without it programs get installed in the wrong place.
Pointy hat to: cperciva
|
148771 |
06-Aug-2005 |
cperciva |
Add bsdiff and bspatch to the base system. These are tools for constructing and applying binary patches; in particular, they perform well (in the sense of constructing small patches) for executable code. Both portsnap (coming to the base system Real Soon Now) and FreeBSD Update (coming to the base system a bit later) use bspatch.
This is the same code as the bsdiff-4.2 which has been in the ports tree (misc/bsdiff) for the past year, with the following exceptions: 1. The license is now the traditional 2-clause BSD; 2. Instead of forking and execing bzip2, the code now uses libbz2; and 3. Some minor changes have been made to fit this code into the base system (adding $FreeBSD$ tags, putting bsdiff and bspatch into separate directories, etc.)
This code is rather ugly and has lots of style bugs (mostly because I wrote it before I had ever heard of style(9)). Some day I'll come back and clean it up.
Discussed on: freebsd-arch MFC before: 5.5-RELEASE Tested by: Several million users (earlier version).
|