routing: Fix buffer size in merge_nhgrps()
merge_nhgrps() sized its temporary nexthop array as twice the existing group instead of the sum of both groups. Fixes: dd945c6ba4ff ("routing: Implement merge of nhgrp in new multipath route")
Posts from every feed QUEST has found across the web — blogs, news, podcasts, channels and more.
merge_nhgrps() sized its temporary nexthop array as twice the existing group instead of the sum of both groups. Fixes: dd945c6ba4ff ("routing: Implement merge of nhgrp in new multipath route")
esp_input() and esp_output() allocated a cryptop from the crypto layer, then malloc'ed the xform_data the callback needs, and with ESN a third buffer for the separate AAD. The callback freed all three. That is two or three allocation pairs for every packet. Put the three in one structure, allocated once per packet from a dedicated UMA zone. The crypto layer provides crypto_initreq() and crypto_destroyreq() for an embedded cryptop, as wg(4) and ktls use. The AAD buffer is sized for the ESP…
CAP.TO is a 8b field and saturate at 127.5 seconds; a controller that needs longer reports the real worst case in CRTO.CRWMT. Waiting only CAP.TO can reset a controller that is still within its declared recovery time after e.g. an abrupt shutdown. Taking the larger of CRTO.CRWMT and CAP.TO when CAP.CRWMS show CRTO support. Reviewed by: adrian Differential Revision: https://reviews.freebsd.org/D59631
Allow the command to be preceded by an exclamation point, which changes the default expected result to a clean exit with a non-zero exit code. MFC after: 1 week Sponsored by: Klara, Inc. Reviewed by: ngie Differential Revision: https://reviews.freebsd.org/D58099
When parsing options, keep track of the length of the unparsed portion and pass that to get_field() instead of the length of the entire header. While here, switch both make_options() and parse_options() to using size_t for sizes and lengths. MFC after: 1 week Reviewed by: markj Differential Revision: https://reviews.freebsd.org/D61048
When parsing a header, keep track of the length of the unparsed portion and pass that to get_field() instead of the length of the entire header. Reported by: n0ps1ed MFC after: 1 week Reviewed by: markj Differential Revision: https://reviews.freebsd.org/D60902
Due to a logic error, get_field() would behave as if the passed-in size was one greater than it actually is. Fix it so it always fails if no terminating NUL is found within the buffer, instead of succeeding if the first byte past the end is a NUL. MFC after: 1 week Reviewed by: markj Differential Revision: https://reviews.freebsd.org/D61032
carp_nl_get() tested ifp->if_carp for NULL before taking carp_sx and walked the softc list afterwards. When the last vhid on the interface is removed in between, carp_free_if() clears if_carp and the walk dereferences a NULL pointer. A reader that passes the check while the removal holds carp_sx always hits this. The check was done with the lock held until the ioctl(2) API was retired. Do it under the lock again. Reported by: Marcos Mendoza Fixes: 72472e52e310 ("carp: retire ioctl(2) API")…
The `:witness` "test" has been failing reliably in CI for over 2 months now. Mark the test XFAIL so the overall CI run is more green. PR: 300697 MFC after: 1 week
When spitting an RSM containing the SYN and data, honor the sequence number used by the SYN flag when computing the offset in the socket buffer. PR: 297006 Reviewed by: rrs, Peter Lei MFC after: 3 days MFC to: stable/15 Sponsored by: Netflix, Inc. Differential Revision: https://reviews.freebsd.org/D61149
Effort: CHERI upstreaming Sponsored by: Innovate UK Pull Request: https://github.com/freebsd/freebsd-src/pull/2284
Effort: CHERI upstreaming Sponsored by: Innovate UK Pull Request: https://github.com/freebsd/freebsd-src/pull/2284
Effort: CHERI upstreaming Sponsored by: Innovate UK Pull Request: https://github.com/freebsd/freebsd-src/pull/2284
Where the kern_ interfaces map trivially to the syscall interface, follow the syscall name even if awkward (e.g., sys___mac* -> kern___mac*). Otherwise use shorter names. Effort: CHERI upstreaming Sponsored by: DARPA, AFRL Pull Request: https://github.com/freebsd/freebsd-src/pull/2284
Effort: CHERI upstreaming Sponsored by: Innovate UK Pull Request: https://github.com/freebsd/freebsd-src/pull/2284
The Enhanced SuperSpeed meaning of the slot context parent hub slot ID and port number fields was introduced in xHCI 1.2. Controllers built to an earlier revision define them only for a Low- or Full-speed device behind a High-speed hub. A SuperSpeed device behind a USB 3.2 hub on an Intel Alpine Ridge controller, an xHCI 1.1 part, stops responding to Address Device and loops in uhub_reattach_port until the port is disabled. Fixes: 20b19982545e ("usb: support SSP and SSPx2 xHCI") Reviewed by:…
Nothing tells the SMC that a power off or restart was user requested, so the T2 keeps rebooting the machine thinking the system is wedged. Approved-by: ngie (co-mentor) Reviewed by: ngie, adrian Differential Revision: https://reviews.freebsd.org/D61260
If a lookup fails for a R_PPC_JMP_SLOT (PLT relocation) ignoring errors results in an address of 0 gets written into the jump slot, leading to a NULL pointer jump when attempting to call the function it points to. Fix this with proper error checking so that a module will fail to load instead of crashing later on.
mqfs_readdir() never reported end of directory. Since 77b273d8f5f4 VOP_READDIR_APV() asserts that a readdir which returns no entries also sets *a_eofflag, so with INVARIANTS the final zero-length getdirentries(2) that ls(1) issues on a mounted mqueuefs panics: panic: VOP_READDIR: eofflag not set Report end of directory when the child list was walked to its end; leave the flag clear when the walk stopped because the buffer was full. MFC after: 1 week
The module Makefile named its only source file in both the SRCS= line and the SRCS+= line that follows. bsd.kmod.mk tolerates the duplicate in a normal build, but when the kernel is built with -flto=thin the linker sees the same bitcode object twice and refuses to link the module ("Expected at most one ThinLTO module per bitcode file"). Fixes: 54e231b373ef MFC after: 1 week
Update expat_config.h and the libbsdxml(3) manpage to reflect the most recent import. MFC after: 3 days MFC with: 765f30b9f3af
Processing an incoming ICMPv6 we need to find just the matching inpcb and call udp_notify() on it. The call to in6_pcbnotify() at the first glance seems like a notifying sweep across the entire database, but it is not. It finds just the matching inpcb, but does that in the most inefficient way! The added test case proves that ICMPv6 processing stays the same before and after the change. This weird use of in6_pcbnotify() can be tracked down all the way to the initial KAME code. Reviewed by:…
This reverts commit ada1f577cc291336cbb69782075dbbf9fe746872.
Bhyve treats an empty cpu set as an error which triggers MPASS panic in the guest. As per the SBI spec, empty masks should return SBI_SUCCESS, and a base of -1UL specifies a broadcast to all harts. Fix both in vmm_sbi.c, clear a1 on return, and skip the SBI ecall in sbi_ipi_pic_ipi_send() if the mask is empty. Also add a NULL check in riscv_send_ipi(). Signed-off-by: Doongar Singh Reviewed by: br Differential Revision: https://reviews.freebsd.org/D61126
Changes: https://github.com/libexpat/libexpat/blob/R_2_10_0/expat/Changes Security: CVE-2026-115506 Security: CVE-2026-117610 Security: CVE-2026-118370 MFC after: 3 days
The driver advertised VLAN offload unconditionally, even when the PF did not grant it, as observed with an E835 VF under Hyper-V. This tells the stack to rely on hardware tag insertion and sends the PF unsupported VLAN filter requests. Advertise hardware VLAN tagging and filtering only when GET_VF_RESOURCES grants the legacy VLAN capability. Do not allocate filter shadow entries or send ADD_VLAN/DEL_VLAN requests without that capability. Retain VLAN MTU and checksum/TSO support for…
Track desired and acknowledged VLAN membership separately. Retain pending deletions and uncertain state after failed requests instead of losing the work when a message is submitted. Make repeated registration idempotent. Adapt DPDK's synchronous, single-VID virtchnl request shape and the bounded desired-state reconciliation used by igbv and ixv. Serialize VLAN requests under the existing virtchnl mutex, with filter-list changes under the iflib context lock. Preserve an unresolved transaction so…
fdcopy() skips plain kqueues and close-on-fork descriptors when it copies the table into the child. Check that dup(2) in the child still returns the lowest unused descriptor, both when the skipped descriptor is the lowest free slot and when it sits above an existing hole. Test cases: kqueue_no_hole a plain kqueue is the lowest descriptor; the child's dup() reuses its slot kqueue_two two adjacent plain kqueues; the child's dup() returns the lower one kqueue_above_hole a plain kqueue sits above a…
Fix wrong usage of .Fn macro in paragraph for `memset_explicit' that caused too many commas improperly emitted into rendered manual page. Approved by: des MFC after: 1 week
Sponsored by: The FreeBSD Foundation MFC after: 1 week