]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/commit
Fix LOCAL_PEERCRED with socketpair(2)
authorasomers <asomers@FreeBSD.org>
Fri, 3 Aug 2018 01:37:00 +0000 (01:37 +0000)
committerasomers <asomers@FreeBSD.org>
Fri, 3 Aug 2018 01:37:00 +0000 (01:37 +0000)
commitfabe732b5ec4e932da13d93418b44b2967135d8f
treed7b711e7888b14493c33c8816d17b6b975cb0859
parentd1a9e67be4a08c2631c6e35b7e04f5ef44a9c399
Fix LOCAL_PEERCRED with socketpair(2)

Enable the LOCAL_PEERCRED socket option for unix domain stream sockets
created with socketpair(2). Previously, it only worked with unix domain
stream sockets created with socket(2)/listen(2)/connect(2)/accept(2).

PR: 176419
Reported by: Nicholas Wilson <nicholas@nicholaswilson.me.uk>
MFC after: 2 weeks
Differential Revision: https://reviews.freebsd.org/D16350
sys/kern/uipc_syscalls.c
sys/kern/uipc_usrreq.c
sys/sys/unpcb.h
tests/sys/kern/Makefile
tests/sys/kern/unix_socketpair_test.c [new file with mode: 0644]