untrusted comment: verify with openbsd-77-base.pub
RWSbCCUoGpcxVZaYiDDARC5MxQF54RDCxgocQmHx0SRFhMxUxM5z9uHO/elho+Sbcu4c6PNMzUvf0dtfrYSlAxLbzgEwGXr4UAk=

OpenBSD 7.7 errata 025, March 4, 2026:

unveil(2) traversals could misbehave crossing mountpoints.

Apply by doing:
    signify -Vep /etc/signify/openbsd-77-base.pub -x 025_unveil_mount.patch.sig \
        -m - | (cd /usr/src && patch -p0)

And then rebuild and install a new kernel:
    KK=`sysctl -n kern.osversion | cut -d# -f1`
    cd /usr/src/sys/arch/`machine`/compile/$KK
    make obj
    make config
    make
    make install

Index: sys/kern/vfs_lookup.c
===================================================================
RCS file: /cvs/src/sys/kern/vfs_lookup.c,v
diff -u -p -u -r1.88 vfs_lookup.c
--- sys/kern/vfs_lookup.c	6 Jan 2023 19:08:36 -0000	1.88
+++ sys/kern/vfs_lookup.c	23 Feb 2026 18:26:57 -0000
@@ -536,6 +536,7 @@ dirloop:
 	 */
 	if (cnp->cn_flags & ISDOTDOT) {
 		for (;;) {
+			unveil_check_component(curproc, ndp, dp);
 			if (dp == ndp->ni_rootdir || dp == rootvnode) {
 				ndp->ni_dvp = dp;
 				ndp->ni_vp = dp;
