]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/commit
Implement a LOCAL_PEERCRED socket option which returns a
authorDima Dorfman <dd@FreeBSD.org>
Fri, 17 Aug 2001 22:01:18 +0000 (22:01 +0000)
committerDima Dorfman <dd@FreeBSD.org>
Fri, 17 Aug 2001 22:01:18 +0000 (22:01 +0000)
commit0c1bb4fbf1a07495aa163806e00ea56872c97286
treea9fd833a0d5be8077a8bafc85a497fe0bae21cfa
parent3da705c074bc4670cbe8a16676d1c5c8fc041607
Implement a LOCAL_PEERCRED socket option which returns a
`struct xucred` with the credentials of the connected peer.
Obviously this only works (and makes sense) on SOCK_STREAM
sockets.  This works for both the connect(2) and listen(2)
callers.

There is precise documentation of the semantics in unix(4).

Reviewed by: dwmalone (eyeballed)
share/man/man4/unix.4
sys/kern/uipc_proto.c
sys/kern/uipc_usrreq.c
sys/sys/un.h
sys/sys/unpcb.h