diff options
Diffstat (limited to 'man7/unix.7')
| -rw-r--r-- | man7/unix.7 | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/man7/unix.7 b/man7/unix.7 index 2eb56e1994..742b6bac18 100644 --- a/man7/unix.7 +++ b/man7/unix.7 @@ -302,6 +302,27 @@ in Linux 4.2. .BR SO_PEEK_OFF See .BR socket (7). +.TP +.B SO_PEERCRED +Return the credentials of the foreign process connected to this socket. +This is possible only for connected +.B AF_UNIX +stream sockets and +.B AF_UNIX +stream and datagram socket pairs created using +.BR socketpair (2). +The returned credentials are those that were in effect at the time +of the call to +.BR connect (2) +or +.BR socketpair (2). +The argument is a +.I ucred +structure; define the +.B _GNU_SOURCE +feature test macro to obtain the definition of that structure from +.IR <sys/socket.h> . +This socket option is read-only. .\" .SS Autobind feature If a |
