HardenedBSD/src 70d9efbsys/contrib/openzfs/config ax_python_devel.m4, sys/contrib/openzfs/lib/libspl assert.c

Merge branch 'freebsd/current/main' into hardened/current/master
DeltaFile
+229-112sys/contrib/openzfs/config/ax_python_devel.m4
+328-8sys/contrib/openzfs/module/zfs/zap.c
+140-51sys/contrib/openzfs/module/zfs/spa.c
+92-60tests/sys/kern/sendfile_helper.c
+97-0sys/contrib/openzfs/tests/zfs-tests/tests/functional/mmp/mmp_write_slow_disk.ksh
+91-2sys/contrib/openzfs/lib/libspl/assert.c
+977-23357 files not shown
+1,536-37063 files

HardenedBSD/src b95e960contrib/libdiff/lib diff_output.c

libdiff: More type issues.

Sponsored by:   Klara, Inc.
Reviewed by:    allanjude
Differential Revision:  https://reviews.freebsd.org/D45080
DeltaFile
+12-12contrib/libdiff/lib/diff_output.c
+12-121 files

HardenedBSD/src b985c9csys/contrib/openzfs/config ax_python_devel.m4, sys/contrib/openzfs/lib/libspl assert.c

zfs: merge openzfs/zfs at 8f1b7a6fa

Notable upstream pull request merges:
 #15839 c3f2f1aa2 vdev probe to slow disk can stall mmp write checker
 #15888 5044c4e3f Fast Dedup: ZAP Shrinking
 #15996 db499e68f Overflowing refreservation is bad
 #16118 67d13998b Make more taskq parameters writable
 #16128 21bc066ec Fix updating the zvol_htable when renaming a zvol
 #16130 645b83307 Improve write issue taskqs utilization
 #16131 8fd3a5d02 Slightly improve dnode hash
 #16134 a6edc0adb zio: try to execute TYPE_NULL ZIOs on the current task
 #16141 b28461b7c Fix arcstats for FreeBSD after zfetch support

Obtained from:  OpenZFS
OpenZFS commit: 8f1b7a6fa6762ea4c89198ceb11c521f80b92ddc
DeltaFile
+229-112sys/contrib/openzfs/config/ax_python_devel.m4
+328-8sys/contrib/openzfs/module/zfs/zap.c
+140-51sys/contrib/openzfs/module/zfs/spa.c
+97-0sys/contrib/openzfs/tests/zfs-tests/tests/functional/mmp/mmp_write_slow_disk.ksh
+91-2sys/contrib/openzfs/lib/libspl/assert.c
+81-0sys/contrib/openzfs/tests/zfs-tests/tests/functional/zap_shrink/zap_shrink_001_pos.ksh
+966-17343 files not shown
+1,332-27149 files

HardenedBSD/src 04ea5e9sys/amd64/conf MINIMAL, sys/i386/conf MINIMAL

MINIMAL: Grow minimal to support ata, scsi and nvme

Until the boot loader automatically loads these things (including the
CAM dependency), we need to have them in the minimal kernel since they
are needed to boot. These aren't strictly required to be in the kernel,
since modules work, but are high enough demand items that until we sort
out boot loader automation, I'm adding them here. These devices are also
common in vm environments. The delta is relatively small in size. Once
the boot loader automation arrives, these and a lot of other things can
be trimmed. It's less than ideal, but is a good middle ground for the
moment.

Sponsored by:           Netflix
Reviewed by:            kevans, emaste
Differential Revision:  https://reviews.freebsd.org/D45012
DeltaFile
+12-0sys/amd64/conf/MINIMAL
+12-0sys/i386/conf/MINIMAL
+24-02 files

HardenedBSD/src eea5f8dusr.bin/diff diffreg_new.c diff.c

diff: Sort headers.

MFC after:      1 week
Sponsored by:   Klara, Inc.
Reviewed by:    markj
Differential Revision:  https://reviews.freebsd.org/D45078
DeltaFile
+9-5usr.bin/diff/diffreg_new.c
+2-2usr.bin/diff/diff.c
+1-1usr.bin/diff/diffdir.c
+12-83 files

HardenedBSD/src 0549218contrib/libdiff/lib diff_main.c

libdiff: Fix type issues.

MFC after:      1 week
Sponsored by:   Klara, Inc.
Reviewed by:    allanjude, markj
Differential Revision:  https://reviews.freebsd.org/D45077
DeltaFile
+3-2contrib/libdiff/lib/diff_main.c
+3-21 files

HardenedBSD/src ea2d874sys/geom/stripe g_stripe.c g_stripe.h

geom_stripe: Cascade cantrim just like we do for gmirror

If any of the disks can support trim, cascade that up the
stack. Otherwise, trims won't pass through striped raid setups.

PR: 277673
Reviewed by: imp (minor style tweaks from bug report)
DeltaFile
+20-1sys/geom/stripe/g_stripe.c
+3-0sys/geom/stripe/g_stripe.h
+23-12 files

HardenedBSD/src 12117d0sys/cam/scsi scsi_da.c

da: Update trim stats for WRITE SAME and ATA TRIM

The scsi UNMAP path updated trim stats in the da sysctl, but the ATA
TRIM passthru and WRITE SAME paths did not. Add code so they do.

PR: 277637
Reviewed by: imp (tweaked WS path to update ranges)
DeltaFile
+6-0sys/cam/scsi/scsi_da.c
+6-01 files

HardenedBSD/src 0c0146ctests/sys/kern sendfile_helper.c sendfile_test.sh

tests/sendfile: test operation on unix/stream socket

Although there are already multiple tests in the tests collection
that utilize sendfile(2) support over unix/stream socket, they all
don't exercise the asynchronous part of the operation.  This test
framework, however, uses a trick to toggle true async operation and
guarantee that pr_ready method of unix/stream is also tested.

Reviewed by:            chs
Differential Revision:  https://reviews.freebsd.org/D45055
DeltaFile
+30-9tests/sys/kern/sendfile_helper.c
+24-0tests/sys/kern/sendfile_test.sh
+54-92 files

HardenedBSD/src c368d3ftests/sys/kern sendfile_helper.c

tests/sendfile: factor out tcp_socketpair()

It creates a pair of connected TCP sockets for later testing.  No
functional change.

Reviewed by:            chs
Differential Revision:  https://reviews.freebsd.org/D45054
DeltaFile
+65-54tests/sys/kern/sendfile_helper.c
+65-541 files

HardenedBSD/src a25e0balib/libarchive Makefile.inc

libarchive: fix thread autodetermination for zstd compression format

The libarchive code uses sysconf(3) to determine the number of threads
when 0 has been given as the number of thread to use

MFC after:      3 days
DeltaFile
+2-1lib/libarchive/Makefile.inc
+2-11 files

HardenedBSD/src 7206f7csys/compat/linuxkpi/common/include/asm set_memory.h

linuxkpi: Fix set_memory_*

set_memory_* is currently implemented using PHYS_TO_DMAP but not all
architectures have a DMAP.  Looking at how this function is used the
given address isn't physical but virtual so the PHYS_TO_DMAP call can
simply be removed.

Also cast numpages before shifting it to avoid overflow.

Reviewed by:    kib, markj
MFC after:      3 days
Differential Revision:  https://reviews.freebsd.org/D45057
DeltaFile
+6-15sys/compat/linuxkpi/common/include/asm/set_memory.h
+6-151 files

HardenedBSD/src 31eb5a2usr.bin/split split.c, usr.sbin/periodic periodic.conf

Merge branch 'freebsd/current/main' into hardened/current/master
DeltaFile
+0-22usr.sbin/periodic/periodic.conf
+0-4usr.sbin/periodic/etc/security/200.chkmounts
+4-0usr.bin/split/split.c
+0-3usr.sbin/periodic/etc/security/800.loginfail
+0-3usr.sbin/periodic/etc/security/900.tcpwrap
+0-3usr.sbin/periodic/etc/security/security.functions
+4-3512 files not shown
+5-5818 files

HardenedBSD/src 2e96a07sys/conf newvers.sh, sys/sys param.h

Merge branch 'freebsd/14-stable/main' into hardened/14-stable/master
DeltaFile
+1-1sys/conf/newvers.sh
+1-1sys/sys/param.h
+2-22 files

HardenedBSD/src 95032b5usr.bin/split split.c

Tighten boundary check in split(1) to prevent a potential buffer overflow.

Before increasing sufflen, make sure the current name plus two (including
the terminating NUL character and the to-be-added character) does not
exceed the fixed buffer length, and stop immediately if this would occur.

In worst case scenario the code would write an nul character beyond the
boundary, however it would be caught by open(2) and based on the memory
layout, we do not believe this would constitute a security vulnerability.

MFC after:      3 days
DeltaFile
+4-0usr.bin/split/split.c
+4-01 files

HardenedBSD/src bf89881tests/sys/netpfil/pf nat66.py

pf tests: fix REQUIRED_MODULES typo

This ensures we don't try to run the nat66 tests if pf is not loaded.

Sponsored by:   Rubicon Communications, LLC ("Netgate")
DeltaFile
+1-1tests/sys/netpfil/pf/nat66.py
+1-11 files

HardenedBSD/src aa48259usr.sbin/periodic periodic.conf, usr.sbin/periodic/etc/security 200.chkmounts 800.loginfail

periodic.conf: remove long deprecated security_daily_compat_var()

This function is documented to be gone in after 11. Time to remove this
compat shim.

PR:             275296
Reviewed by:    jrm (mentor)
MFC after:      1 month
Differential Revision:  https://reviews.freebsd.org/D44796
DeltaFile
+0-22usr.sbin/periodic/periodic.conf
+0-4usr.sbin/periodic/etc/security/200.chkmounts
+0-3usr.sbin/periodic/etc/security/800.loginfail
+0-3usr.sbin/periodic/etc/security/900.tcpwrap
+0-3usr.sbin/periodic/etc/security/security.functions
+0-2usr.sbin/periodic/etc/security/510.ipfdenied
+0-3710 files not shown
+0-5716 files

HardenedBSD/src 7b082bdsys/conf newvers.sh, sys/sys param.h

Post-14.1-branch updates

Rename stable/14 to -STABLE

Bump __FreeBSD_version

Approved by:    re (implicit)
Sponsored by:   https://www.patreon.com/cperciva
DeltaFile
+1-1sys/conf/newvers.sh
+1-1sys/sys/param.h
+2-22 files

HardenedBSD/src 4965372lib/libnvmf nvmf_tcp.c, sys/cam/ctl ctl.c

Merge branch 'freebsd/current/main' into hardened/current/master
DeltaFile
+1,867-0sys/dev/nvmf/nvmf_tcp.c
+1,474-0lib/libnvmf/nvmf_tcp.c
+1,171-72sys/cam/ctl/ctl.c
+1,130-0sys/dev/nvmf/controller/nvmft_controller.c
+1,123-0sys/dev/nvmf/controller/ctl_frontend_nvmf.c
+939-0sys/dev/nvmf/host/nvmf.c
+7,704-7288 files not shown
+21,286-23894 files

HardenedBSD/src 2cd1918contrib/libarchive/libarchive archive_string.c archive_match.c, contrib/libarchive/unzip/test test_I.c

Merge branch 'freebsd/14-stable/main' into hardened/14-stable/master
DeltaFile
+42-54contrib/libarchive/libarchive/archive_string.c
+9-9contrib/libarchive/libarchive/archive_match.c
+8-0contrib/libarchive/unzip/test/test_I.c
+6-1sys/kern/sys_generic.c
+3-4libexec/rtld-elf/rtld_printf.c
+2-0contrib/libarchive/libarchive/archive_read_support_format_lha.c
+70-686 files

HardenedBSD/src 46ae162libexec/rtld-elf rtld_printf.c, sys/kern sys_generic.c

Merge branch 'freebsd/13-stable/main' into hardened/13-stable/master
DeltaFile
+3-4libexec/rtld-elf/rtld_printf.c
+6-1sys/kern/sys_generic.c
+9-52 files

HardenedBSD/src c4d0e1fcontrib/libarchive/libarchive archive_string.c archive_match.c, contrib/libarchive/unzip/test test_I.c

libarchive: merge bugfixes from vendor branch

 #2147 archive_string: clean up strncat_from_utf8_to_utf8 (36047967a)
 #2153 archive_match: check archive_read_support_format_raw()
       return value (0ce1b4c38)
 #2154 archive_match: turn counter into flag (287e05d53)
 #2155 lha: Do not allow negative file sizes (93b11caed)
 #2156 tests: setenv LANG to en_US.UTF-8 in bsdunzip test_I.c (83e8b0ea8)

(cherry picked from commit c0b58e65deca1e5e2c434ede7e64f03af6044be8)
DeltaFile
+42-54contrib/libarchive/libarchive/archive_string.c
+9-9contrib/libarchive/libarchive/archive_match.c
+8-0contrib/libarchive/unzip/test/test_I.c
+2-0contrib/libarchive/libarchive/archive_read_support_format_lha.c
+61-634 files

HardenedBSD/src d9ec850libexec/rtld-elf rtld_printf.c

rtld snprintf: do not erronously skip a char at the buffer boundary

(cherry picked from commit 56ee5fc43c40479e2651b21862e299bcf73017ae)
DeltaFile
+3-4libexec/rtld-elf/rtld_printf.c
+3-41 files

HardenedBSD/src cf2750bsys/kern sys_generic.c

kcmp_pget(): do not accept TIDs

(cherry picked from commit 5b3e5c6ce3e552dae3e84d6bc781bc9f53c22d71)
DeltaFile
+2-1sys/kern/sys_generic.c
+2-11 files

HardenedBSD/src 6b667b4sys/kern sys_generic.c

kcmp_pget(): add an assert that we did not hold the current process

(cherry picked from commit 1e01650a787028fd558e8cb709c232e335fc2cd9)
DeltaFile
+5-1sys/kern/sys_generic.c
+5-11 files

HardenedBSD/src 33cac29sys/kern sys_generic.c

kcmp_pget(): do not accept TIDs

(cherry picked from commit 5b3e5c6ce3e552dae3e84d6bc781bc9f53c22d71)
DeltaFile
+2-1sys/kern/sys_generic.c
+2-11 files

HardenedBSD/src 66e0bf7sys/kern sys_generic.c

kcmp_pget(): add an assert that we did not hold the current process

(cherry picked from commit 1e01650a787028fd558e8cb709c232e335fc2cd9)
DeltaFile
+5-1sys/kern/sys_generic.c
+5-11 files

HardenedBSD/src 44debeelibexec/rtld-elf rtld_printf.c

rtld snprintf: do not erronously skip a char at the buffer boundary

(cherry picked from commit 56ee5fc43c40479e2651b21862e299bcf73017ae)
DeltaFile
+3-4libexec/rtld-elf/rtld_printf.c
+3-41 files

HardenedBSD/src 6ec2c13share/man/man5 src.conf.5

HBSD: Resolve merge conflict

Regen src.conf.5.

Signed-off-by:  Shawn Webb <shawn.webb at hardenedbsd.org>
DeltaFile
+1-5share/man/man5/src.conf.5
+1-51 files

HardenedBSD/src 9f8ca09. RELNOTES, sbin/nvmecontrol nvmecontrol.c nvmecontrol.8

Merge remote-tracking branch 'internal/freebsd/current/main' into hardened/current/master

Conflicts:
        share/man/man5/src.conf.5 (unresolved)
DeltaFile
+7-5share/man/man5/src.conf.5
+6-1sys/cam/cam_iosched.c
+5-2sbin/nvmecontrol/nvmecontrol.c
+2-4sys/kern/kern_sysctl.c
+6-0RELNOTES
+2-2sbin/nvmecontrol/nvmecontrol.8
+28-145 files not shown
+35-2311 files