Re: [PATCH v3 1/3] qio: add support for SO_PEERCRED for socket channel

2024-01-29 Thread Daniel P . Berrangé
On Mon, Jan 29, 2024 at 08:25:29PM +0100, Paolo Bonzini wrote: > On Thu, Jan 25, 2024 at 5:38 PM Daniel P. Berrangé > wrote: > > > +static void > > > +qio_channel_socket_get_peerpid(QIOChannel *ioc, > > > + unsigned int *pid, > > > + Err

Re: [PATCH v3 1/3] qio: add support for SO_PEERCRED for socket channel

2024-01-29 Thread Paolo Bonzini
On Thu, Jan 25, 2024 at 5:38 PM Daniel P. Berrangé wrote: > > +static void > > +qio_channel_socket_get_peerpid(QIOChannel *ioc, > > + unsigned int *pid, > > + Error **errp) > > +{ > > +#ifdef CONFIG_LINUX > > +QIOChannelSocket *sioc =

Re: [PATCH v3 1/3] qio: add support for SO_PEERCRED for socket channel

2024-01-25 Thread Daniel P . Berrangé
On Thu, Jan 25, 2024 at 08:22:12AM +0100, Anthony Harivel wrote: > The function qio_channel_get_peercred() returns a pointer to the > credentials of the peer process connected to this socket. > > This credentials structure is defined in as follows: > > struct ucred { > pid_t pid;/* Pro

[PATCH v3 1/3] qio: add support for SO_PEERCRED for socket channel

2024-01-24 Thread Anthony Harivel
The function qio_channel_get_peercred() returns a pointer to the credentials of the peer process connected to this socket. This credentials structure is defined in as follows: struct ucred { pid_t pid;/* Process ID of the sending process */ uid_t uid;/* User ID of the sen