bspatch: use C23 overflow checking math now that it is availableReviewed by: desSponsored by: The FreeBSD FoundationDifferential Revision: https://reviews.freebsd.org/D41771(cherry picked from
bspatch: use C23 overflow checking math now that it is availableReviewed by: desSponsored by: The FreeBSD FoundationDifferential Revision: https://reviews.freebsd.org/D41771(cherry picked from commit ee12faa062c04a49bf6fe4e6867bad8606e2413f)
show more ...
Remove $FreeBSD$: two-line nroff patternRemove /^\.\\"\n\.\\"\s*\$FreeBSD\$$\n/
Remove $FreeBSD$: one-line sh patternRemove /^\s*#[#!]?\s*\$FreeBSD\$.*$\n/
Remove $FreeBSD$: one-line .c patternRemove /^[\s*]*__FBSDID\("\$FreeBSD\$"\);?\s*\n/
Remove $FreeBSD$: two-line .h patternRemove /^\s*\*\n \*\s+\$FreeBSD\$$\n/
spdx: The BSD-2-Clause-FreeBSD identifier is obsolete, drop -FreeBSDThe SPDX folks have obsoleted the BSD-2-Clause-FreeBSD identifier. Catchup to that fact and revert to their recommended match of
spdx: The BSD-2-Clause-FreeBSD identifier is obsolete, drop -FreeBSDThe SPDX folks have obsoleted the BSD-2-Clause-FreeBSD identifier. Catchup to that fact and revert to their recommended match of BSD-2-Clause.Discussed with: pfgMFC After: 3 daysSponsored by: Netflix
Update/fix Makefile.depend for userland
bspatch.1: fix missing argumentFix typoMFC after: 3 daysReviewed by: gbeDifferential Revision: https://reviews.freebsd.org/D37727
bsdiff: fix off-by-one errorThe program reads oldsize bytes from oldfile, and proceeds to initializea suffix array of oldsize elements using divsufsort(). As per thefunction's API [1], array indi
bsdiff: fix off-by-one errorThe program reads oldsize bytes from oldfile, and proceeds to initializea suffix array of oldsize elements using divsufsort(). As per thefunction's API [1], array indices 0 through n-1 are initialized.Later, search() is called, but with index bounds [0, n]. Depending onthe contents of the malloc'd buffer, accessing this uninitialized indexat the end of can result in a segmentation fault. Fix this by passingoldsize-1 to search(), limiting the search bounds to [0, n-1].This bug is a result of r303285, which introduced divsufsort() as analternate suffix sorting function to the existing qsufsort(). It seemsthat qsufsort() did initialize the final empty element, meaning it couldbe safely accessed. This difference in the implementations was missed atthe time.[1] https://github.com/y-256/libdivsufsortDiscussed with: cpercivaMFC after: 1 weekSponsored by: The FreeBSD FoundationDifferential Revision: https://reviews.freebsd.org/D26911
bspatch: add integer overflow checksIntroduce a new add_off_t static function that exits with an errormessage if there's an overflow, otherwise returns their sum. Use thiswhen adding values obta
bspatch: add integer overflow checksIntroduce a new add_off_t static function that exits with an errormessage if there's an overflow, otherwise returns their sum. Use thiswhen adding values obtained from the input patch.Reviewed by: delphij, allanjude (earlier)MFC after: 1 weekSponsored by: The FreeBSD FoundationDifferential Revision: https://reviews.freebsd.org/D7897
errno.h is no longer needed as of r340239 so remove it.No MFC planned as that revision was not merged.
Remove support for FreeBSD 10.x.MFC after: 1 month
bspatch: simplify capsicumizationAssume that user wants to run with capsicum support if he builds the softwarewith HAVE_CAPSICUM. Treat running application without capsicum in the kernel asan err
bspatch: simplify capsicumizationAssume that user wants to run with capsicum support if he builds the softwarewith HAVE_CAPSICUM. Treat running application without capsicum in the kernel asan error.MFC after: 3 weeks
various: general adoption of SPDX licensing ID tags.Mainly focus on files that use BSD 2-Clause license, however the tool Iwas using misidentified many licenses so this was mostly a manual - error
various: general adoption of SPDX licensing ID tags.Mainly focus on files that use BSD 2-Clause license, however the tool Iwas using misidentified many licenses so this was mostly a manual - errorprone - task.The Software Package Data Exchange (SPDX) group provides a specificationto make it easier for automated tools to detect and summarize well knownopensource licenses. We are gradually adopting the specification, notingthat the tags are considered only advisory and do not, in any way,superceed or replace the license texts.No functional change intended.
DIRDEPS_BUILD: Update dependencies.Sponsored by: Dell EMC Isilon
Revert debugging that was accidently committed in r316314
fix top(1) ZFS compressed ARC supporttop(1) read the wrong amount of data from sysctl, uint64_t instead ofboolean_t, resulting in the stats not showing in many cases.X-MFC-With: r315435Sponsore
fix top(1) ZFS compressed ARC supporttop(1) read the wrong amount of data from sysctl, uint64_t instead ofboolean_t, resulting in the stats not showing in many cases.X-MFC-With: r315435Sponsored by: ScaleEngine Inc.
Adopt SRCTOP in usr.binPrefer ${SRCTOP}/foo over ${.CURDIR}/../../foo and ${SRCTOP}/usr.bin/fooover ${.CURDIR}/../foo for paths in Makefiles.Differential Revision: https://reviews.freebsd.org/D9
Adopt SRCTOP in usr.binPrefer ${SRCTOP}/foo over ${.CURDIR}/../../foo and ${SRCTOP}/usr.bin/fooover ${.CURDIR}/../foo for paths in Makefiles.Differential Revision: https://reviews.freebsd.org/D9932Sponsored by: NetflixSilence on: arch@ (twice)
bspatch: Remove backwards-compatibility sys/capability.h supportbspatch previously included sys/capability.h or sys/capsicum.h basedon __FreeBSD_version, as FreeBSD is the upstream for bsdiff and
bspatch: Remove backwards-compatibility sys/capability.h supportbspatch previously included sys/capability.h or sys/capsicum.h basedon __FreeBSD_version, as FreeBSD is the upstream for bsdiff and we maysee this file incorporated into other third-party software.The Capsicum header is now installed as sys/capsicum.h in stable/10 andFreeBSD 10.3, so we can just use sys/capsicum.h and simplify the logic.Reviewed by: allanjudeDifferential Revision: https://reviews.freebsd.org/D7954
bspatch: use #define for header size instead of magic numberReviewed by: allanjude, kibSponsored by: The FreeBSD FoundationDifferential Revision: https://reviews.freebsd.org/D7861
bspatch: remove superfluous newlines from errx strings
bspatch: add sanity checks on sizes to avoid integer overflowNote that this introduces an explicit 2GB limit, but this was alreadyimplicit in variable and function argument types.This is based o
bspatch: add sanity checks on sizes to avoid integer overflowNote that this introduces an explicit 2GB limit, but this was alreadyimplicit in variable and function argument types.This is based on the "non-cryptanalytic attacks against freebsdupdate components" anonymous gist. Further refinement is planned.Reviewed by: allanjude, cem, kibObtained from: anonymous gistMFC after: 3 daysSponsored by: The FreeBSD FoundationDifferential Revision: https://reviews.freebsd.org/D7619
bspatch: remove output file in the case of errorReviewed by: oshogboSponsored by: The FreeBSD FoundationDifferential Revision: https://reviews.freebsd.org/D7644
Capsicumize bspatchMove 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
Capsicumize bspatchMove 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.Reviewed by: emaste, ed, oshogbo, delphijApproved by: soMFC after: 3 daysRelnotes: yesSponsored by: ScaleEngine Inc.Differential Revision: https://reviews.freebsd.org/D7358
bspatch: apply style(9)Make style changes (and trivial refactoring of open calls) now in orderto reduce noise in diffs for future capsicum changes.Reviewed by: oshogboNo objection: cpercivaSpo
bspatch: apply style(9)Make style changes (and trivial refactoring of open calls) now in orderto reduce noise in diffs for future capsicum changes.Reviewed by: oshogboNo objection: cpercivaSponsored by: The FreeBSD FoundationDifferential Revision: https://reviews.freebsd.org/D7610
12