HomeFreeBSD

vfs: Permit unix sockets to be opened with O_PATH

Description

vfs: Permit unix sockets to be opened with O_PATH

As with FIFOs, a path descriptor for a unix socket cannot be used with
kevent().

In principle connectat(2) and bindat(2) could be modified to support an
AT_EMPTY_PATH-like mode which operates on the socket referenced by an
O_PATH fd referencing a unix socket. That would eliminate the path
length limit imposed by sockaddr_un.

Update O_PATH tests.

Reviewed by: kib
Sponsored by: The FreeBSD Foundation

(cherry picked from commit 2bd9826995ca6b23f8b088cfa035c0ad1c578ac3)

Details

Provenance
markjAuthored on Sep 17 2021, 4:34 PM
Parents
rG9b918d1761ce: ng_ppp(4): Fix a typo in a comment
Branches
Unknown
Tags
Unknown