libvirt/src/rpc
Ryota Ozaki 8079b0e0f4 virnetsocket: fix getsockopt on FreeBSD
aa0f099 introduced a strict error checking for getsockopt and it
revealed that getting a peer credential of a socket on FreeBSD
didn't work. Libvirtd hits the error:
  error : virNetSocketGetUNIXIdentity:1198 : Failed to get valid
  client socket identity groups

SOL_SOCKET (0xffff) was used as a level of getsockopt for
LOCAL_PEERCRED, however, it was wrong. 0 is correct as well as
Mac OS X.

So for LOCAL_PEERCRED our options are SOL_LOCAL (if defined) or
0 on Mac OS X and FreeBSD. According to the fact, the patch
simplifies the code by removing ifdef __APPLE__.

I tested the patch on FreeBSD 8.4, 9.2 and 10.0-BETA1.

Signed-off-by: Ryota Ozaki <ozaki.ryota@gmail.com>
2013-11-03 17:08:55 -06:00
..
gendispatch.pl
genprotocol.pl genprotocol.pl: Fix code on FreeBSD too 2013-09-27 18:32:42 +02:00
gensystemtap.pl
virkeepalive.c
virkeepalive.h
virkeepaliveprotocol.x
virnetclient.c
virnetclient.h
virnetclientprogram.c
virnetclientprogram.h
virnetclientstream.c
virnetclientstream.h maint: fix up copyright notice inconsistencies 2012-09-20 16:30:55 -06:00
virnetmessage.c MacOS: Handle changes to xdrproc_t definition 2013-11-03 09:34:10 -06:00
virnetmessage.h
virnetprotocol.x Adjust legacy max payload size to account for header information 2013-10-07 13:28:44 +02:00
virnetsaslcontext.c
virnetsaslcontext.h
virnetserver.c Get rid of shadowed booleans 2013-10-22 15:50:47 +01:00
virnetserver.h
virnetserverclient.c Fix typo in identity code which is pre-requisite for CVE-2013-4311 2013-09-23 14:07:55 -06:00
virnetserverclient.h
virnetservermdns.c
virnetservermdns.h
virnetserverprogram.c
virnetserverprogram.h
virnetserverservice.c
virnetserverservice.h
virnetsocket.c virnetsocket: fix getsockopt on FreeBSD 2013-11-03 17:08:55 -06:00
virnetsocket.h Add a virNetSocketNewConnectSockFD method 2013-09-24 09:37:26 +01:00
virnetsshsession.c
virnetsshsession.h
virnettlscontext.c Remove all direct use of getenv 2013-10-21 14:03:52 +01:00
virnettlscontext.h