Support LOCAL_PEEREID (NetBSD) and getpeereid() (FreeBSD)
* configure.ac: check for LOCAL_PEEREID and getpeereid(). * src/assuan-socket-server.c (accept_connection_bottom): make use of LOCAL_PEEREID and getpeereid().
For use with assuan_get_peercred(). Note that getpeereid() does not
set the PID member. LOCAL_PEEREID is checked before getpeereid()
since NetBSD has both of these. SO_PEERCRED is still checked first.
[Second revision]
This revision adds support for LOCAL_PEEREID which NetBSD uses. Its
tested against NetBSD 6.0 and may work without problems with earlier
versions. FreeBSD uses getpeereid() which does not have PID support.
Recent OpenBSD versions do support SO_PEERCRED and old versions have
getpeereid() but also may have LOCAL_PEEREID (not sure).