pkg-serve: stat the opened descriptor instead of the path
Open first and fstat() that fd, so the file checked is the one served.
O_NONBLOCK avoids blocking on a FIFO.
pkg-serve: do not leak whether a path exists
Report "ko: file not found" for non-regular files as well, so a
client cannot tell an existing path from a missing one.
pkg-serve: bound the command line length
getline(3) grows its buffer without limit, so a client could make the
process consume unbounded memory. Read commands with a bounded
reader, drain and reject lines longer than MAXLINE with
"ko: command too long", and document the limit.
libfetch: Fix buffer overruns in FTP code
* When parsing the reply to a CWD, PWD, or CDUP command, if we ran out
of space in the destination buffer, we would correctly terminate the
loop, but then incorrectly see the remaining length as non-zero,
causing us to write a terminating NUL one past the end of the buffer
and report success instead of a protocol error. Additionally, the
code would fail to notice an improperly terminated pathname, and was
hard to follow, so rewrite the entire loop.
* When comparing the current working directory to the intended working
directory to calculate the minimal operation to get from one to the
other, if the current working directory was an empty string, we would
improperly read one byte below the start of the intended working
directory.
MFC after: 1 week
Reported by: Laam Alif at Ibteda Digital Library
Differential Revision: https://reviews.freebsd.org/D61502
ports-mgmt/pkg: update to 2.9.3
- upgrade: no longer aborts when the packages of a dependency cycle cannot be
scheduled as a group, the jobs are ordered instead
- printf: pkg_asprintf() clears the result pointer again when it fails, and
the buffer of the pkg_printf() family is no longer leaked on failure
- build: the major version pkg is built for is read from the target headers
instead of the compiler, which reports the host one with a cross compiler,
and no longer triggers a spurious major OS upgrade warning or a wrong
default INDEX file name
- install: the metalog lists every directory the package creates, from the
parents to the children, so that it is a valid mtree specification
devel/py-*: Change *_DEPENDS from py-graphql-core to py-graphql-core32
* Adjust ports that either directly or indirectly require py-graphene
(which is currently incompatible with py-graphql-core 3.3+) or have a
corresponding upper limit, from py-graphql-core to py-graphql-core32.
* Bump PORTREVISION due dependency change.
Reviewed by: sunpoet (via private mail)
devel/py-graphql-core32: New port
GraphQL-core is a port of graphql-js to Python.
Note: This port is limited to the 3.2.x release series because
devel/py-graphene is currently not compatible with newer versions
of py-graphql-core.
Reviewed by: sunpoet (via private mail)
net/rsync: update 3.5.1 -> 3.5.2
Changelog: https://download.samba.org/pub/rsync/NEWS#3.5.2
Major changes:
- Fix CVE-2026-119741 (previously commited in 3.5.1_1)
- Fixed interrupted --append and --inplace transfers writing the final 256 KiB buffer twice
- Fixed uploads through rrsync when the destination file already exists.
- Fixed poor matching performance on large sparse and repeated-block files when duplicate
checksum chains exhausted the search limit
- Prevented the --inplace matcher from advancing its aligned basis index beyond the available
checksum entries
- Recovered from failed hard-link creation without aborting or hanging the generator.
- Prevented an out-of-bounds write while invalidating a sender checksum after a file read error
when the negotiated checksum length is zero
- Prevented the --inplace matcher from advancing its aligned basis index beyond the available
checksum entries
- Recovered from failed hard-link creation without aborting or hanging the generator
- Prevented an out-of-bounds write while invalidating a sender checksum after a file read error
[17 lines not shown]
powerpc: save and restore VRSAVE with the vector state
VRSAVE was never saved or restored, although user code can write it
and the mcontext carries it, so every process saw the value the
previous process on that CPU had left there.
Two processes pinned to the same CPU and writing different values to
VRSAVE each read back the other's; each reads back its own now.
Reviewed by: jhibbits
MFC after: 1 week
Differential Revision: https://reviews.freebsd.org/D61544
powerpc: move get_pcpu() to machine/pcpu.h
Every other arch defines get_pcpu() in machine/pcpu.h, powerpc has it in
machine/cpufunc.h, which is entirely under _KERNEL. lsof includes
sys/systm.h without _KERNEL first on purpose, so on powerpc cpufunc.h
turns into an empty header and pcpup later expands to a call of an
undeclared get_pcpu(). Since sys/mount.h started pulling in sys/proc.h
this breaks the lsof build on powerpc64 and powerpc64le.
Reviewed by: jhibbits
MFC after: 1 week
Differential Revision: https://reviews.freebsd.org/D61305
devel/sdl3-imgui-filedialogs: New port
This project is based on ImFileDialog by dfranx, with many bugs/crashes
fixed and overall improvements. The 'Quick Access' sidebar actually
remembers what favorites were previously saved to it from previous runs
of your application now, by saving the settings to a text file in a
hidden configuration subfolder of your home folder. It allows for full
localization among many other useful things and customizable via
environment variables.
Approved by: arrowd (co-mentor)
snd_uaudio: Fix the MIDI TX round-robin
Nothing advances curr_cable, so umidi_bulk_write_callback() only
services cable 0, which is a problem on MIDI devices with more than one
jack.
Fixes: 039477d3e7e7 ("snd_uaudio: Simplify chan->curr_cable calculation in uaudio_bulk_write_callback()")
Sponsored by: The FreeBSD Foundation
MFC after: 1 day
usbdevs: Add HumanWare BrailleNote Apex IDs
Add the HumanWare vendor ID and the BrailleNote Apex
product ID to support the Apex 32 BT when configured
as a screen reader terminal in USB Client mode.
This device will also serve as the starting point for
developing the FreeBSD braille(4) subsystem.
Reviewed by: emaste
Sponsored by: The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D61624