nullfs: Allow VSOCK to be mounted on top of another VSOCK
In the world of containers, mounting a unix(4) socket is a common
practice to allow communication between processes within containers.
For example, both Podman and Docker can expose a unix(4) socket,
and that same unix(4) socket can be mounted as a file accessible
to a process inside a container, allowing that application to control
Podman or Docker. Another example is PHP-FPM with NGINX, where,
instead of using TCP/IP for communication between containers, a
unix(4) socket is sufficient.
However, nullfs(4) and all related components do not allow mounting
a VSOCK on top of another. The current workaround involves creating
the socket in a directory and mounting that directory. This is an
option, though it does not provide a good user experience compared
to directly mounting a VSOCK on top of another, since the application
that creates the socket may create other sockets in that directory,
and the user may not wish to share them, or, worse yet, applications
that create unix(4) sockets may not provide any authentication at
[9 lines not shown]
Mk/Scripts/checksum.sh: show expected/fetched checksum and size
Print expected and fetched checksums and file size on mismatch to help
debug builder-only failures.
PR: 294170
Differential Revision: https://reviews.freebsd.org/D58891
security/libgcrypt: Remove AVX512 support for FreeBSD 14 and 15
LLVM19 as shipped with FreeBSD 14 and 15 is incompete. Disable it by
default. Users who want AVX512 on FreeBSD < 16 must install LLVM20 or
newer and select the AVX512 option.
FreeBSD 16-CURRENT has LLVM21, with complete support for AVX512. Setting
the AVX512 option on 16-CURRENT is a NOP.
PR: 297987
pf: Send syncookies from the receiving thread
pf sends outbound packets by offloading them to a single per-vnet SWI handler
through the `V_pf_sendqueue` mbuf queue. A large DDoS attack may overwhelm
that per-vnet queue with syncookie packets and cause contention in the SWI
handler that negatively affects other pf operations.
Fix this by sending the initial syncookie challenge from the context
of the receiving thread. This avoids the syncookie-induced contention on
the `pf_intr` mbuf queue.
Sponsored by: Klara, Inc.
Sponsored by: Entersekt
MFC after: 3 weeks
Reviewed by: kp
Differential Revision: https://reviews.freebsd.org/D59068
misc/codex: Directly use install command instead of CARGO_INSTALL_PATH
Using the ports framework's install target (from cargo.mk) with
CARGO_INSTALL_PATH specified seems to run build again, which consumes
too much time, even when the build phase has successfully finished. To
avoid that, use custom do-install target with install command.
While here, remove extraneous binary (logs_client) from installation.
PR: 297995
Reported by: Robert Cina <transitive at gmail.com>
Co-authored-by: Robert Cina <transitive at gmail.com>
net/netpeek: Update 0.3.2 => 0.3.3
While here, update features list in pkg-descr and
remove unnecessary args from USES=python.
Changelog:
https://github.com/zingytomato/netpeek/releases/tag/v0.3.3
Reported by: portscout!
Approved by: osa, vvd (Mentors, implicit)
biology/py-pydeseq2: Update to 0.5.4
Drop support for python 3.10
Modernize build system
A few fixes and enhancements
Changes: https://github.com/scverse/PyDESeq2/releases
Reported by: portscout
sys/tests/kern/pdopenpid: pdopenpid(2) is allowed in cap mode
Adjust test to check for ECAPMODE using grandchild instead of child.
Childrens can be opened even in cap mode. Add test for the later.
Reviewed by: markj
Sponsored by: The FreeBSD Foundation
MFC after: 1 week
Differential revision: https://reviews.freebsd.org/D58989
pdptrace(2): allow debugging in capability mode
The pdopenpid(2) syscall is allowed in capability mode. Add the chicken
switch security.bsd.ptrace_in_cap_mode, which disables it without
reboot, if needed.
The descriptor passed to pdptrace(2) must have the CAP_PTRACE
capability enabled. This capability is not enabled by default by
pdfork()/pdopenpid(), and the calls do not return a procdesc suitable
for debugging. The opening code must prepare for debugging in advance by
passing the PD_PTRACE_CAP flag to pdfork()/pdopenpid().
For ptrace(2), allow PT_CLEARSTEP and PT_GET_CHILDREN for the current
thread and process in cap mode as well.
Reviewed by: markj
Sponsored by: The FreeBSD Foundation
MFC after: 1 week
Differential revision: https://reviews.freebsd.org/D58989
pdopenpid(2): allow in capability mode with restrictions
The pdopenpid() syscall is allowed to open processes which are either
direct children of the caller, or are debuggees already attached to the
calling process. This is reasonable because we could have controlled the
child on fork anyway.
The procdesc-less debuggee can legitimately appear due to ptrace
FOLLOW-FORK mode.
Reviewed by: markj
Sponsored by: The FreeBSD Foundation
MFC after: 1 week
Differential revision: https://reviews.freebsd.org/D58989
kern: add p_canopen()
The function defines the policy for allowing to open a pid.
Reviewed by: markj
Sponsored by: The FreeBSD Foundation
MFC after: 1 week
Differential revision: https://reviews.freebsd.org/D58989
tests/sys/kern/pdwait: adjust test for the addition of CAP_PTRACE
Reviewed by: markj
Sponsored by: The FreeBSD Foundation
MFC after: 1 week
Differential revision: https://reviews.freebsd.org/D58586
ptrace: split sys_ptrace()/freebsd32_ptrace()
The code to handle copyin and copyout of the structured parameters is
moved into the helpers.
Reviewed by: markj
Sponsored by: The FreeBSD Foundation
MFC after: 1 week
Differential revision: https://reviews.freebsd.org/D58586