HardenedBSD/src 2d0c740contrib/bmake job.c, libexec/rtld-elf rtld.c

Merge remote-tracking branch 'origin/hardened/current/master' into hardened/current/cross-dso-cfi
DeltaFile
+86-165contrib/bmake/job.c
+236-0sys/arm64/rockchip/rk_grf_gpio.c
+52-52usr.bin/bmake/Makefile
+43-19sys/ufs/ffs/ffs_subr.c
+27-21libexec/rtld-elf/rtld.c
+44-0share/man/man4/man4.aarch64/rk_grf_gpio.4
+488-25748 files not shown
+828-39954 files

HardenedBSD/src e3d00ee. .git-blame-ignore-revs, libexec/rtld-elf rtld.c

Merge branch 'freebsd/current/main' into hardened/current/master
DeltaFile
+27-21libexec/rtld-elf/rtld.c
+1-0.git-blame-ignore-revs
+28-212 files

HardenedBSD/src 1c8cdd8libexec/rtld-elf rtld.c

rtld: fix several style(9) bugs

Sponsored by:   The FreeBSD Foundation
DeltaFile
+27-21libexec/rtld-elf/rtld.c
+27-211 files

HardenedBSD/src a39d4bblibexec/rtld-elf rtld.c, share/man/man4 tty.4

Merge branch 'freebsd/14-stable/main' into hardened/14-stable/master
DeltaFile
+2-2libexec/rtld-elf/rtld.c
+2-1sys/security/audit/audit.c
+1-1share/man/man4/tty.4
+5-43 files

HardenedBSD/src 068de5blibexec/rtld-elf rtld.c

rtld: clear any holes in the struct utrace_rtld passed to kernel logger

PR:     284563

(cherry picked from commit e917958c36670131ab42e8f2c849b708a3216e37)
DeltaFile
+2-2libexec/rtld-elf/rtld.c
+2-21 files

HardenedBSD/src 97a616esys/netlink netlink_domain.c netlink_generic.c, sys/riscv/vmm vmm_sbi.c vmm_aplic.c

Merge remote-tracking branch 'origin/hardened/current/master' into hardened/current/cross-dso-cfi
DeltaFile
+55-81sys/netlink/netlink_domain.c
+41-60sys/riscv/vmm/vmm_sbi.c
+49-49usr.bin/netstat/main.c
+74-13sys/riscv/vmm/vmm_aplic.c
+36-39usr.sbin/bhyve/riscv/vmexit.c
+41-31sys/netlink/netlink_generic.c
+296-27326 files not shown
+489-44032 files

HardenedBSD/src 7717833sys/netlink netlink_domain.c netlink_generic.c, sys/riscv/vmm vmm_sbi.c vmm_aplic.c

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

Conflicts:
        sys/kern/vfs_syscalls.c (unresolved)
DeltaFile
+55-81sys/netlink/netlink_domain.c
+41-60sys/riscv/vmm/vmm_sbi.c
+49-49usr.bin/netstat/main.c
+74-13sys/riscv/vmm/vmm_aplic.c
+36-39usr.sbin/bhyve/riscv/vmexit.c
+41-31sys/netlink/netlink_generic.c
+296-27326 files not shown
+492-43932 files

HardenedBSD/src e917958libexec/rtld-elf rtld.c

rtld: clear any holes in the struct utrace_rtld passed to kernel logger

This should avoid an (almost) false positive from Valgrind, by filling
the padding on LP64.

PR:     284563
Reported by:    Paul Floyd <pjfloyd at wanadoo.fr>
Reviewed by:    emaste
Sponsored by:   The FreeBSD Foundation
MFC after:      1 week
Differential revision:  https://reviews.freebsd.org/D48854
DeltaFile
+2-2libexec/rtld-elf/rtld.c
+2-21 files

HardenedBSD/src 136a242libexec/rtld-elf rtld.c, libexec/rtld-elf/amd64 reloc.c

Merge branch 'freebsd/14-stable/main' into hardened/14-stable/master
DeltaFile
+25-4sys/kern/kern_sysctl.c
+2-1sys/compat/freebsd32/freebsd32.h
+2-1sys/sys/stat.h
+1-1libexec/rtld-elf/rtld.c
+0-2libexec/rtld-elf/amd64/reloc.c
+0-2libexec/rtld-elf/i386/reloc.c
+30-117 files not shown
+39-1113 files

HardenedBSD/src 5782050libexec/rtld-elf rtld.c

rtld-elf/rtld.c: fix typo in comment

(cherry picked from commit dd1d72961b8d343b29480b74afcfe4292fd166af)
DeltaFile
+1-1libexec/rtld-elf/rtld.c
+1-11 files

HardenedBSD/src 9316bd0contrib/spleen spleen-32x64.bdf spleen-16x32.bdf, libexec/rtld-elf rtld.c

Merge remote-tracking branch 'origin/hardened/current/master' into hardened/current/cross-dso-cfi
DeltaFile
+5,487-2,363contrib/spleen/spleen-32x64.bdf
+2,899-2,834libexec/rtld-elf/rtld.c
+3,009-1,293contrib/spleen/spleen-16x32.bdf
+2,930-0sys/dev/usb/net/if_umb.c
+1,754-742contrib/spleen/spleen-8x16.bdf
+2,362-6contrib/spleen/spleen-12x24.bdf
+18,441-7,23861 files not shown
+24,037-8,25167 files

HardenedBSD/src 8450968libexec/rtld-elf rtld.c map_object.c

HBSD: Resolve merge conflicts

FreeBSD updated the style of the files contained in this commit. This
commit updates our changes to match that style. No functional change
intended.

Signed-off-by:  Shawn Webb <shawn.webb at hardenedbsd.org>
DeltaFile
+51-379libexec/rtld-elf/rtld.c
+2-23libexec/rtld-elf/map_object.c
+53-4022 files

HardenedBSD/src 01aa0e0contrib/spleen spleen-32x64.bdf spleen-16x32.bdf, libexec/rtld-elf rtld.c

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

Conflicts:
        libexec/rtld-elf/map_object.c (unresolved)
        libexec/rtld-elf/rtld.c (unresolved)
DeltaFile
+5,487-2,363contrib/spleen/spleen-32x64.bdf
+2,899-2,506libexec/rtld-elf/rtld.c
+3,009-1,293contrib/spleen/spleen-16x32.bdf
+2,930-0sys/dev/usb/net/if_umb.c
+1,754-742contrib/spleen/spleen-8x16.bdf
+2,362-6contrib/spleen/spleen-12x24.bdf
+18,441-6,91048 files not shown
+23,799-7,71754 files

HardenedBSD/src bf3fbf7libexec/rtld-elf rtld.c

rtld obj_remap_relro(): unindent the loop body

Discussed with: emaste, imp
Sponsored by:   The FreeBSD Foundation
Differential revision:  https://reviews.freebsd.org/D48509
DeltaFile
+10-12libexec/rtld-elf/rtld.c
+10-121 files

HardenedBSD/src 7e2f383libexec/rtld-elf rtld.c

rtld-elf/rtld.c: apply clang-format

Discussed with: emaste, imp
Sponsored by:   The FreeBSD Foundation
Differential revision:  https://reviews.freebsd.org/D48509
DeltaFile
+2,847-2,775libexec/rtld-elf/rtld.c
+2,847-2,7751 files

HardenedBSD/src dd1d729libexec/rtld-elf rtld.c

rtld-elf/rtld.c: fix typo in comment

Discussed with: emaste, imp
Sponsored by:   The FreeBSD Foundation
MFC after:      3 days
Differential revision:  https://reviews.freebsd.org/D48509
DeltaFile
+1-1libexec/rtld-elf/rtld.c
+1-11 files

HardenedBSD/src 576ab71contrib/mandoc roff.c, sys/dev/altera/atse if_atse.c

Merge remote-tracking branch 'origin/hardened/current/master' into hardened/current/cross-dso-cfi
DeltaFile
+0-1,592sys/dev/altera/atse/if_atse.c
+481-447contrib/mandoc/roff.c
+0-882sys/dev/altera/softdma/softdma.c
+0-648sys/dev/beri/virtio/network/if_vtbe.c
+0-637sys/dev/altera/msgdma/msgdma.c
+0-561sys/dev/altera/jtag_uart/altera_jtag_uart_tty.c
+481-4,767543 files not shown
+5,353-16,240549 files

HardenedBSD/src f99e005contrib/mandoc roff.c, sys/dev/altera/atse if_atse.c

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

Conflicts:
        sys/dev/beri/virtio/virtio.c (deleted)
DeltaFile
+0-1,592sys/dev/altera/atse/if_atse.c
+481-447contrib/mandoc/roff.c
+0-882sys/dev/altera/softdma/softdma.c
+0-648sys/dev/beri/virtio/network/if_vtbe.c
+0-637sys/dev/altera/msgdma/msgdma.c
+0-561sys/dev/altera/jtag_uart/altera_jtag_uart_tty.c
+481-4,767448 files not shown
+4,283-15,733454 files

HardenedBSD/src fda0403libexec/rtld-elf rtld.c map_object.c

rtld: Support multiple PT_GNU_RELRO program headers

Iterate over all the program headers in obj_remap_relro and remove the
relro fields from Obj_Entry.

Skip the call to obj_enforce_relro() in relocate_object() for the rtld
object as well as the main program object.  obj_enforce_relro() is
called later when it safe to reference globals such as page_size.

Reviewed by:    kib
Obtained from:  CheriBSD
Sponsored by:   AFRL, DARPA
Differential Revision:  https://reviews.freebsd.org/D47884
DeltaFile
+20-17libexec/rtld-elf/rtld.c
+0-12libexec/rtld-elf/map_object.c
+0-3libexec/rtld-elf/rtld.h
+20-323 files

HardenedBSD/src 44b40e6libexec/rtld-elf rtld.c

Merge branch 'freebsd/14-stable/main' into hardened/14-stable/master
DeltaFile
+0-7libexec/rtld-elf/rtld.c
+0-71 files

HardenedBSD/src 73cc716libexec/rtld-elf rtld.c

rtld: drop RTLD_INIT_PAGESIZES_EARLY

(cherry picked from commit 5bc24fd7a21ffd98fe978b4eb09a383c09edbe37)
DeltaFile
+0-7libexec/rtld-elf/rtld.c
+0-71 files

HardenedBSD/src f40958elib/libc/gen dlfcn.c, lib/libdl Symbol.map

Merge branch 'freebsd/14-stable/main' into hardened/14-stable/master
DeltaFile
+38-6sys/dev/e1000/if_em.c
+22-4lib/libc/gen/dlfcn.c
+24-0libexec/rtld-elf/rtld.c
+3-2sys/dev/e1000/e1000_phy.c
+4-0lib/libdl/Symbol.map
+1-0libexec/rtld-elf/Symbol.map
+92-121 files not shown
+93-127 files

HardenedBSD/src 708106flib/libc/gen dlfcn.c Symbol.map, libexec/rtld-elf rtld.c Symbol.map

rtld: implement _dl_iterate_phdr_locked

Some sanitizers need to be able to use dl_iterate_phdr() after stopping
the rest of the process, but it's very hard to do so reliably as a
non-participant in the main logic of the program.

Introduce _dl_iterate_phdr_locked to bypass the locking that's normally
required for dl_iterate_phdr() and slap some scary warning on it.  It
will remain undocumented and probably shouldn't be used for anything
else.

Reviewed by:    kib

(cherry picked from commit 1426fd6cff0603f0ee275b99f2ba35dc36f3d0c2)
DeltaFile
+20-4lib/libc/gen/dlfcn.c
+24-0libexec/rtld-elf/rtld.c
+1-0lib/libc/gen/Symbol.map
+1-0libexec/rtld-elf/Symbol.map
+46-44 files

HardenedBSD/src 6bb472econtrib/llvm-project/clang/include/clang/Basic BuiltinsLoongArchLASX.def BuiltinsLoongArchLSX.def, sys/dev/hwpmc hwpmc_logging.c

Merge remote-tracking branch 'origin/hardened/current/master' into hardened/current/cross-dso-cfi
DeltaFile
+101-100sys/netinet/tcp_hostcache.c
+131-20usr.sbin/daemon/daemon.c
+73-73contrib/llvm-project/clang/include/clang/Basic/BuiltinsLoongArchLASX.def
+66-66contrib/llvm-project/clang/include/clang/Basic/BuiltinsLoongArchLSX.def
+103-29sys/vm/vm_page.c
+65-61sys/dev/hwpmc/hwpmc_logging.c
+539-349134 files not shown
+2,051-971140 files

HardenedBSD/src 4e6b40econtrib/llvm-project/clang/include/clang/Basic BuiltinsLoongArchLASX.def BuiltinsLoongArchLSX.def, sys/dev/hwpmc hwpmc_logging.c

Merge branch 'freebsd/current/main' into hardened/current/master
DeltaFile
+101-100sys/netinet/tcp_hostcache.c
+131-20usr.sbin/daemon/daemon.c
+73-73contrib/llvm-project/clang/include/clang/Basic/BuiltinsLoongArchLASX.def
+103-29sys/vm/vm_page.c
+66-66contrib/llvm-project/clang/include/clang/Basic/BuiltinsLoongArchLSX.def
+65-61sys/dev/hwpmc/hwpmc_logging.c
+539-349134 files not shown
+2,051-971140 files

HardenedBSD/src 5bc24fdlibexec/rtld-elf rtld.c

rtld: drop RTLD_INIT_PAGESIZES_EARLY

No arch defines it after ia64 decomissioning.

Discussed with: jhb
Sponsored by:   The FreeBSD Foundation
MFC after:      1 week
DeltaFile
+0-7libexec/rtld-elf/rtld.c
+0-71 files

HardenedBSD/src 157f2bblib/libthr/tests atfork_test.c, share/man/man4 run.4

Merge remote-tracking branch 'internal/hardened/current/master' into hardened/current/cross-dso-cfi

Conflicts:
        targets/pseudo/bootstrap-tools/Makefile (unresolved)
DeltaFile
+1,062-0sys/dev/clk/allwinner/ccu_d1.c
+0-859sys/contrib/openzfs/module/unicode/uconv.c
+172-110sys/contrib/openzfs/tests/zfs-tests/tests/functional/vdev_disk/page_alignment.c
+280-0lib/libthr/tests/atfork_test.c
+217-0tools/tools/git/mfc-candidates.lua
+138-73share/man/man4/run.4
+1,869-1,042282 files not shown
+4,808-3,288288 files

HardenedBSD/src 028a031bin/ps ps.c, lib/libc/gen dlfcn.c _pthread_stubs.c

Merge branch 'freebsd/current/main' into hardened/current/master
DeltaFile
+280-0lib/libthr/tests/atfork_test.c
+22-4lib/libc/gen/dlfcn.c
+24-0libexec/rtld-elf/rtld.c
+12-8lib/libthr/thread/thr_fork.c
+11-0lib/libc/gen/_pthread_stubs.c
+1-5bin/ps/ps.c
+350-179 files not shown
+371-2215 files

HardenedBSD/src 1426fd6lib/libc/gen dlfcn.c Symbol.map, libexec/rtld-elf rtld.c Symbol.map

rtld: implement _dl_iterate_phdr_locked

Some sanitizers need to be able to use dl_iterate_phdr() after stopping
the rest of the process, but it's very hard to do so reliably as a
non-participant in the main logic of the program.

Introduce _dl_iterate_phdr_locked to bypass the locking that's normally
required for dl_iterate_phdr() and slap some scary warning on it.  It
will remain undocumented and probably shouldn't be used for anything
else.

Reviewed by:    kib
Differential Revision:  https://reviews.freebsd.org/D47558
DeltaFile
+24-0libexec/rtld-elf/rtld.c
+20-4lib/libc/gen/dlfcn.c
+1-0libexec/rtld-elf/Symbol.map
+1-0lib/libc/gen/Symbol.map
+46-44 files

HardenedBSD/src 1b14f91bin/ps ps.1, lib/libc/gen rtld_get_var.3 dlfcn.c

Merge branch 'freebsd/14-stable/main' into hardened/14-stable/master
DeltaFile
+106-0lib/libc/gen/rtld_get_var.3
+45-27bin/ps/ps.1
+60-11libexec/rtld-elf/rtld.c
+4-18sys/kern/vfs_subr.c
+17-0lib/libc/gen/dlfcn.c
+13-2share/man/man9/style.9
+245-587 files not shown
+276-6213 files