HardenedBSD/src 2c3c3b6. Makefile.inc1, release/packages create-sets.sh generate-ucl.sh

Merge remote-tracking branch 'origin/hardened/current/master' into hardened/current/cross-dso-cfi
DeltaFile
+87-61usr.bin/netstat/if.c
+19-20Makefile.inc1
+7-15usr.bin/netstat/netstat.1
+0-2usr.bin/netstat/main.c
+1-1release/packages/create-sets.sh
+1-1release/packages/generate-ucl.sh
+115-1001 files not shown
+116-1007 files

HardenedBSD/src 52916eb. Makefile.inc1, release/packages create-sets.sh generate-ucl.sh

Merge branch 'freebsd/current/main' into hardened/current/master
DeltaFile
+87-61usr.bin/netstat/if.c
+19-20Makefile.inc1
+7-15usr.bin/netstat/netstat.1
+1-1release/packages/create-sets.sh
+1-1release/packages/generate-ucl.sh
+0-2usr.bin/netstat/main.c
+115-1001 files not shown
+116-1007 files

HardenedBSD/src 7537b58. UPDATING, lib/libpam/pam.d Makefile

Merge branch 'freebsd/15-stable/main' into hardened/15-stable/main
DeltaFile
+35-0release/packages/ucl/pam-all.ucl
+30-0release/packages/ucl/zstd-all.ucl
+0-28release/packages/ucl/libsdp-all.ucl
+7-13lib/libpam/pam.d/Makefile
+18-0UPDATING
+5-2release/packages/ucl/rc.ucl
+95-4317 files not shown
+109-6823 files

HardenedBSD/src a09d06blib/libc/gen Makefile.inc

libc: Add missing MLINK for stravis(3)

MFC after:      1 week
Fixes:          8dfeba04eb36 ("Update to a June 8th snapshot of (un)vis form NetBSD.")
Reviewed by:    ziaee
Differential Revision:  https://reviews.freebsd.org/D56260
DeltaFile
+1-0lib/libc/gen/Makefile.inc
+1-01 files

HardenedBSD/src 95cc7f5. UPDATING, lib/libpam/modules/pam_securetty Makefile

libpam: Move to a new "pam" package

OpenPAM is a discrete, largely self-contained system component.
Users may not need PAM for many use-cases (e.g. jails, containers),
so move it to its own package.

Use LIB_PACKAGE to create a separate pam-lib package for libpam,
so that applications that support PAM don't need to bring in all
the PAM modules if PAM isn't actually in use.

Add pam to the minimal sets, since this is a core system component that
people expect to be installed.  This means all supported installation
methods will install the PAM modules by default, so don't add explicit
dependencies on the PAM modules from things that use PAM (e.g. runtime),
allowing custom/embedded systems to omit these easily.

This change adds a new package to the system so, until we have a proper
policy on how to handle this in release/stable branches, it should not
be MFC'd.

    [9 lines not shown]
DeltaFile
+35-0release/packages/ucl/pam-all.ucl
+7-13lib/libpam/pam.d/Makefile
+12-0UPDATING
+0-2lib/libpam/modules/pam_self/Makefile
+0-2lib/libpam/modules/pam_unix/Makefile
+0-2lib/libpam/modules/pam_securetty/Makefile
+54-195 files not shown
+57-2611 files

HardenedBSD/src 8c61751. UPDATING, lib/libzstd Makefile

zstd: Move to a new zstd package

Zstd is a discrete, self-contained system component.  To match how we
package zlib, bzip2 and xz, move it to its own package, with a separate
lib package.

Add the new package to the minimal set, since this is a core component
that users expect to be installed.

This change adds a new package to the system so, until we have a proper
policy on how to handle this in release/stable branches, it should not
be MFC'd.

[stable/15: MFC under the re@ pkgbase policy for 15.1]

MFC after:      never
Reviewed by:    bapt
Sponsored by:   https://www.patreon.com/bsdivy
Differential Revision:  https://reviews.freebsd.org/D53603

    [2 lines not shown]
DeltaFile
+30-0release/packages/ucl/zstd-all.ucl
+6-0UPDATING
+3-1lib/libzstd/Makefile
+2-0usr.bin/zstd/Makefile
+41-14 files

HardenedBSD/src 976b2ebrelease/packages generate-set-ucl.lua generate-ucl.lua

packages: Fix build with libucl 0.9.3

In libucl 0.9.3, macros and includes are disabled by default when
creating a new UCL parser.  This breaks the package build, which
relies on includes.  Fix this by explicitly passing zero flags
to ucl.parser().

MFC after:      3 days
Fixes:          abda442d92fd ("contrib/libucl:  Import libucl 0.9.3")
Reviewed by:    kevans, bapt
Reported by:    freebsd at walstatt-de.de
Sponsored by:   https://www.patreon.com/bsdivy
Differential Revision:  https://reviews.freebsd.org/D56266

(cherry picked from commit 63d0e3e3aa2483420f828686336d6615616363d5)
DeltaFile
+1-1release/packages/generate-set-ucl.lua
+1-1release/packages/generate-ucl.lua
+2-22 files

HardenedBSD/src c4f66edlib Makefile

libsamplerate: Only build when virtual_oss is built

Gate libsamplerate behind MK_CUSE and MK_SOUND, like virtual_oss.
Nothing else uses this library, so there's no point building it
if we aren't building virtual_oss.

This avoids building a useless FreeBSD-sound package containing
only this library when WITHOUT_SOUND is set.

MFC after:      1 week
Reviewed by:    christos, emaste
Differential Revision:  https://reviews.freebsd.org/D56164
Sponsored by:           https://www.patreon.com/bsdivy

(cherry picked from commit baa7a870d65db324d4dd781702e7ccefde20a3ee)
DeltaFile
+1-2lib/Makefile
+1-21 files

HardenedBSD/src 72b848arelease/packages/ucl caroot.ucl

packages: Fix caroot deinstall command

The correct syntax is 'post-deinstall', not 'post-uninstall'.

MFC after:      3 days (stable/15 only)
Reviewed by:    jlduran, des
Differential Revision:  https://reviews.freebsd.org/D56109
Sponsored by:           https://www.patreon.com/bsdivy

(cherry picked from commit 63ecedb3c2ce75a44d55b9424d74d94e294de313)
DeltaFile
+1-1release/packages/ucl/caroot.ucl
+1-11 files

HardenedBSD/src 2cb1b47release/packages/ucl rc.ucl

packages: Add dependency from rc to mtree

/etc/rc.d/var_run uses mtree, which is in the devel set and isn't
installed as part of either minimal or optional, so add a manual
dependency.

Reviewed by:    des, bapt, emaste
Differential Revision:  https://reviews.freebsd.org/D54540
Sponsored by:           https://www.patreon.com/bsdivy

(cherry picked from commit 833087185a6e9a2bd26707c57c83a71a541a825a)
DeltaFile
+5-2release/packages/ucl/rc.ucl
+5-21 files

HardenedBSD/src a5eb120release/packages/ucl xz-all.ucl

packages: Move xz to the minimal set

pkg(8), via its daily periodic script, requires xz.  We don't have
a way to encode dependencies from ports on base packages right now,
so instead move xz to the minimal set so it's always installed.

This isn't an ideal solution, but it's justified in this case since
pkg(8) is always installed, so having its dependencies always
installed is acceptable.

(Following discusson on the diff, new versions of pkg have now been
changed to use zstd instead of xz, but we still think xz is useful
enough to keep in minimal.)

MFC after:      1 week (stable/15 only)
Reviewed by:    des, bapt, emaste
Differential Revision:  https://reviews.freebsd.org/D55630
Sponsored by:           https://www.patreon.com/bsdivy

(cherry picked from commit 43773002fa63262d531ce3ee5cf5d3fe872a3388)
DeltaFile
+1-1release/packages/ucl/xz-all.ucl
+1-11 files

HardenedBSD/src ef10d46etc/mtree BSD.include.dist

etc/mtree: Restore removed package tags

Following commit 436618a427b4 which added package tags to mtree,
some of the tags were later removed due to an issue with empty
packages being created.  That problem has been fixed by commit
7965c93e4d41, so we can now restore the tags that were removed.

This reverts commit 00352ef6d2a013650f0ab2a4c9b016c22552ed25.
This reverts commit 1fbdb149aa486961c5d9d6403065e90123b3f5fe.
This reverts commit ef2d586d7efb908bf39e7d5eb5d4305193d0ca6e.
This reverts commit 2a8a6179eb6cef8ba1a417a4c8a1f7063c704533.

MFC after:      2 weeks (stable/15 only)
Reviewed by:    des, bapt, emaste
Differential Revision:  https://reviews.freebsd.org/D55645
Sponsored by:           https://www.patreon.com/bsdivy

(cherry picked from commit 8ba3ada41dda46b41100fa913473058856816e0c)
DeltaFile
+1-1etc/mtree/BSD.include.dist
+1-11 files

HardenedBSD/src 2d57126release/packages/ucl libsdp-all.ucl

packages: Remove stale libsdp-all.ucl

This package no longer exists since it was merged into bluetooth.

Fixes:  41ee4321cc52 ("libsdp: Move to bluetooth-lib package")
MFC after:      3 days
Reviewed by:    emaste
Differential Revision:  https://reviews.freebsd.org/D55822
Sponsored by:           https://www.patreon.com/bsdivy

(cherry picked from commit 6900d8b5c3874814be4fed7ef2f6d124ebc9a920)
DeltaFile
+0-28release/packages/ucl/libsdp-all.ucl
+0-281 files

HardenedBSD/src bace6cdrelease/packages/ucl ftpd-all.ucl

packages: Remove stale ftpd-all.ucl

This file was missed when ftpd(8) was removed.

Fixes:  614c8750ce11 ("Remove ftpd(8)")
MFC after:      3 days
Reviewed by:    emaste
Differential Revision:  https://reviews.freebsd.org/D55820
Sponsored by:           https://www.patreon.com/bsdivy

(cherry picked from commit ea25f494b315180c4b48fcdc4d2b2a111c84912c)
DeltaFile
+0-4release/packages/ucl/ftpd-all.ucl
+0-41 files

HardenedBSD/src 359d6e3. Makefile.inc1, release/packages create-sets.sh generate-ucl.sh

packages: Always use the bootstrap flua

To avoid breaking the build due to incompatible changes in flua or lua
libraries on the host, use the bootstrap flua for the package build.

MFC after:      2 weeks
Reviewed by:    kevans, emaste
Sponsored by:   https://www.patreon.com/bsdivy
Differential Revision:  https://reviews.freebsd.org/D56271
DeltaFile
+11-10Makefile.inc1
+1-1release/packages/create-sets.sh
+1-1release/packages/generate-ucl.sh
+13-123 files

HardenedBSD/src 50de0bf. Makefile.inc1

flua: Always build as a bootstrap tool

We want to use flua from the source tree (not the host) during package
build, firstly to protect us from breaking changes in lua or libucl,
and secondly to allow (in future) cross-building of packages from
Linux or macOS.

Since we don't know if the user will be building packages during the
bootstrap phase, and because flua is fairly small and generally useful,
build it as a bootstrap tool unconditionally.

MFC after:      2 weeks
Reviewed by:    kevans, emaste
Sponsored by:   https://www.patreon.com/bsdivy
Differential Revision:  https://reviews.freebsd.org/D56270
DeltaFile
+8-10Makefile.inc1
+8-101 files

HardenedBSD/src 3174985usr.bin/netstat if.c netstat.1

netstat(1): '-w': Banners to appear before a new statistics line, not after

Recurring banners except the first are printed just after the latest
interval's statistics line, giving the false impression that the latter
are omitted.  It is also better to print a new banner only if it is
going to be followed by a new line of statistics, in case netstat(1) is
interrupted or we have reached the number of iterations specified by
'-q'.

Fix this by pushing printing these banners inside the loop producing
statistics lines, after having waited for the next interval.

The first banner is printed before the loop, as we want it to be printed
immediately at launch, even if at this point we do not have statistics
to display (we have to wait for an interval to compute these, as they
are based on a difference).

While here, remove the 'goto' spaghetti by putting banner printing into
its own private function and using a proper infinite loop in

    [19 lines not shown]
DeltaFile
+87-61usr.bin/netstat/if.c
+7-15usr.bin/netstat/netstat.1
+0-2usr.bin/netstat/main.c
+94-783 files

HardenedBSD/src 50964d7sys/net if.c

Merge remote-tracking branch 'origin/hardened/current/master' into hardened/current/cross-dso-cfi
DeltaFile
+19-10sys/net/if.c
+19-101 files

HardenedBSD/src b177954sys/net if.c

Merge branch 'freebsd/current/main' into hardened/current/master
DeltaFile
+19-10sys/net/if.c
+19-101 files

HardenedBSD/src 00d96dasys/net if.c

ifnet: Add some sanity checks

To be more robust since the checking is now performed where the
interface is referenced.

While here, remove a redundant check from if_vmove_loan().

Reviewed by:    kp, glebius, pouria
MFC after:      2 weeks
Differential Revision:  https://reviews.freebsd.org/D55875
DeltaFile
+19-10sys/net/if.c
+19-101 files

HardenedBSD/src 16799f5contrib/bmake bmake.1 make.1, contrib/bmake/unit-tests moderrs.exp

Merge remote-tracking branch 'origin/hardened/current/master' into hardened/current/cross-dso-cfi
DeltaFile
+46-59contrib/bmake/bmake.1
+46-59contrib/bmake/make.1
+82-0contrib/bmake/ChangeLog
+40-40contrib/bmake/unit-tests/moderrs.exp
+22-55contrib/bmake/meta.c
+40-30contrib/bmake/var.c
+276-24387 files not shown
+1,284-62093 files

HardenedBSD/src be5d869contrib/bmake bmake.1 make.1, contrib/bmake/unit-tests moderrs.exp

Merge branch 'freebsd/current/main' into hardened/current/master
DeltaFile
+46-59contrib/bmake/bmake.1
+46-59contrib/bmake/make.1
+82-0contrib/bmake/ChangeLog
+40-40contrib/bmake/unit-tests/moderrs.exp
+22-55contrib/bmake/meta.c
+40-30contrib/bmake/var.c
+276-24387 files not shown
+1,284-62093 files

HardenedBSD/src 9c572bfcontrib/libpcap configure pcap-linux.c, contrib/tcpdump tcpdump.c

Merge branch 'freebsd/15-stable/main' into hardened/15-stable/main
DeltaFile
+361-360contrib/libpcap/configure
+566-102contrib/libpcap/pcap-linux.c
+0-508contrib/tcpdump/missing/snprintf.c
+404-50contrib/libpcap/nametoaddr.c
+311-47contrib/tcpdump/tcpdump.c
+225-123contrib/libpcap/pcap-dlpi.c
+1,867-1,190137 files not shown
+5,157-3,166143 files

HardenedBSD/src 6af32a9contrib/tcpdump tcpdump.c print-icmp6.c, contrib/tcpdump/missing snprintf.c

tcpdump: Update to 4.99.6

Changes:        https://github.com/the-tcpdump-group/tcpdump/blob/tcpdump-4.99/CHANGES
Obtained from:  https://www.tcpdump.org/release/tcpdump-4.99.6.tar.xz
Sponsored by:   The FreeBSD Foundation
Differential Revision:  https://reviews.freebsd.org/D55578
Differential Revision:  https://reviews.freebsd.org/D55871

(cherry picked from commit e6083790f217ba7f89cd2957922bd45e35466359)
DeltaFile
+0-508contrib/tcpdump/missing/snprintf.c
+311-47contrib/tcpdump/tcpdump.c
+84-103contrib/tcpdump/print-icmp6.c
+79-105contrib/tcpdump/print-egp.c
+110-56contrib/tcpdump/CMakeLists.txt
+54-84contrib/tcpdump/print-mobility.c
+638-90363 files not shown
+1,581-1,65869 files

HardenedBSD/src cd87e82usr.sbin/ipfwpcap ipfwpcap.c

ipfwpcap: Fix build after libpcap 1.10.6 update

pcap-int.h now references SIZEOF_TIME_T from libpcap's config.h, which
is not available to consumers of the internal header outside of the
libpcap build.  Switch to the public <pcap.h> header and replace the
direct FILE* casts and ferror()/fflush() calls with pcap_dump_flush(3),
which is the correct public API for flushing a pcap dump file.

Sponsored by:   The FreeBSD Foundation

(cherry picked from commit a0b3ef1952603ebf0307ca723b03e5a71598dd5a)
DeltaFile
+2-7usr.sbin/ipfwpcap/ipfwpcap.c
+2-71 files

HardenedBSD/src e0ae00fcontrib/libpcap configure pcap-linux.c, lib/libpcap config.h

libpcap: Update to 1.10.6

Changes:        https://raw.githubusercontent.com/the-tcpdump-group/libpcap/89e982c37c36ad0bf9f10b7ded421cb42422effa/CHANGES
Reviewed by:    bms, emaste
Obtained from:  https://www.tcpdump.org/release/libpcap-1.10.6.tar.gz
Sponsored by:   The FreeBSD Foundation
Differential Revision:  https://reviews.freebsd.org/D55545
Differential Revision:  https://reviews.freebsd.org/D55858

(cherry picked from commit 16cef5f7a65588def71db4fdfa961f959847e3b6)
DeltaFile
+361-360contrib/libpcap/configure
+566-102contrib/libpcap/pcap-linux.c
+404-50contrib/libpcap/nametoaddr.c
+225-123contrib/libpcap/pcap-dlpi.c
+245-101contrib/libpcap/gencode.c
+209-54lib/libpcap/config.h
+2,010-79067 files not shown
+3,574-1,50173 files

HardenedBSD/src 36fe65csys/sys param.h

Bump __FreeBSD_version to 1600015 after linuxkpi changes for DRM 6.11

As of this commit, all changes to linuxkpi required by the DRM drivers
from Linux 6.11 were committed.

Sponsored by:   The FreeBSD Foundation
DeltaFile
+1-1sys/sys/param.h
+1-11 files

HardenedBSD/src 0eaa576sys/compat/linuxkpi/common/include/linux ascii85.h

linuxkpi: Add <linux/ascii85.h>

This is used by the i915 DRM driver for some time to log more details
about a GPU error, but the code was commented out.

Reviewed by:    emaste
Sponsored by:   The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D56282
DeltaFile
+46-0sys/compat/linuxkpi/common/include/linux/ascii85.h
+46-01 files

HardenedBSD/src ece26dbsys/compat/linuxkpi/common/include/linux minmax.h

linuxkpi: Define `MIN_T()` and `MAX_T()`

There are the same as `MIN()` and `MAX()` except that they take a type
to cast both arguments to compare.

The DRM generic code started to use it in Linux 6.11.

Reviewed by:    bz, emaste
Sponsored by:   The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D55739
DeltaFile
+3-0sys/compat/linuxkpi/common/include/linux/minmax.h
+3-01 files

HardenedBSD/src 5ee604bsys/compat/linuxkpi/common/include/linux sizes.h

linuxkpi: Define missing `SZ_*` below 1 kib

The amdgpu DRM driver started to use it in Linux 6.11.

Reviewed by:    bz, emaste
Sponsored by:   The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D55740
DeltaFile
+11-0sys/compat/linuxkpi/common/include/linux/sizes.h
+11-01 files