Re: [PATCH] server: Add an API to get the socket fd for a client

2016-01-19 Thread Bryce Harrington
always correct. I would assume it does not suffer > > >from the same caveat as getsockopt(SO_PEERCRED), but I don't know that. > > Yes, as I also think, the security context must always be correct when I > > pass the exact client's fd. > > The library to get

Re: [PATCH] server: Add an API to get the socket fd for a client

2016-01-15 Thread Bryce Harrington
RED), but I don't know that. > Yes, as I also think, the security context must always be correct when I > pass the exact client's fd. > The library to get the security contexts from the file descriptor must > guarantee that > the returned contexts are credible. > > T

[PATCH] server: Add an API to get the socket fd for a client

2016-01-14 Thread Sung-Jin Park
The library to get the security contexts from the file descriptor must guarantee that the returned contexts are credible. Thanks and regards, Sung-Jin Park ------- Original Message ------- Sender : Pekka Paalanen Date : 2016-01-13 19:35 (GMT+09:00) Title : Re: [PATCH] server: Add an API to get the sock

Re: [PATCH] server: Add an API to get the socket fd for a client

2016-01-13 Thread 박성진
arantee that the returned contexts are credible. Thanks and regards, Sung-Jin Park --- Original Message ------- Sender : Pekka Paalanen Date : 2016-01-13 19:35 (GMT+09:00) Title : Re: [PATCH] server: Add an API to get the socket fd for a client On Wed, 13 Jan 2016 10:02:18 + (GMT) 박성진

Re: [PATCH] server: Add an API to get the socket fd for a client

2016-01-13 Thread Pekka Paalanen
On Wed, 13 Jan 2016 10:02:18 + (GMT) 박성진 wrote: > Samsung Enterprise Portal mySingle > > Pekka Paalanen, thank you for your review on this. :) > > > > >The fd may not always be from a socket file, it can also be from a call > >to socketpair(2). > > Yes, exactly. > > >Please refer to wl

Re: [PATCH] server: Add an API to get the socket fd for a client

2016-01-13 Thread 박성진
commit message.>It might even make sense to add the example use case to the doc.Agree with you. I'll enhance the doc and update it soon.   Thanks and regards, Sung-Jin Park--- Original Message -------Sender : Pekka Paalanen Date   : 2016-01-13 17:01 (GMT+09:00)Title  : Re: [PATC

Re: [PATCH] server: Add an API to get the socket fd for a client

2016-01-13 Thread Pekka Paalanen
On Wed, 13 Jan 2016 10:31:58 +0800 Jonas Ådahl wrote: > On Tue, Jan 12, 2016 at 10:58:16AM -0600, Derek Foreman wrote: > > On 11/01/16 04:30 PM, Sung-Jin Park wrote: > > > This adds an API to get the socket fd for a client. > > > The client socket fd can be used for a wayland compositor to vali

Re: [PATCH] server: Add an API to get the socket fd for a client

2016-01-12 Thread Sung-Jin Park
Jonas Ådahl, thanks for your review. wl_client_get_fd() looks better to me as well. Including API name, I'll correct comments as well. Thanks and regards, Sung-Jin Park 2016. 1. 13. 오전 11:32에 "Jonas Ådahl" 님이 작성: > On Tue, Jan 12, 2016 at 10:58:16AM -0600, Derek Foreman wrote: > > On 11/01/16 0

Re: [PATCH] server: Add an API to get the socket fd for a client

2016-01-12 Thread Jonas Ådahl
On Tue, Jan 12, 2016 at 10:58:16AM -0600, Derek Foreman wrote: > On 11/01/16 04:30 PM, Sung-Jin Park wrote: > > This adds an API to get the socket fd for a client. > > The client socket fd can be used for a wayland compositor to validate a > > request > > from a client. > > For instance, this will

Re: [PATCH] server: Add an API to get the socket fd for a client

2016-01-12 Thread Sung-Jin Park
Derek, thanks for your review. :) I'll correct the comment regarding fd and update this patch. >Should probably just be > * \return The fd to use for the connection Thanks and regards, Sung-Jin Park 2016. 1. 13. 오전 1:58에 "Derek Foreman" 님이 작성: > On 11/01/16 04:30 PM, Sung-Jin Park wrote: > > Thi

Re: [PATCH] server: Add an API to get the socket fd for a client

2016-01-12 Thread Derek Foreman
On 11/01/16 04:30 PM, Sung-Jin Park wrote: > This adds an API to get the socket fd for a client. > The client socket fd can be used for a wayland compositor to validate a > request > from a client. > For instance, this will be helpful in some linux distributions, in which > SELinux > or SMACK is

[PATCH] server: Add an API to get the socket fd for a client

2016-01-11 Thread Sung-Jin Park
This adds an API to get the socket fd for a client. The client socket fd can be used for a wayland compositor to validate a request from a client. For instance, this will be helpful in some linux distributions, in which SELinux or SMACK is enabled. In those environments, each file (including socket

[PATCH] server: Add an API to get the socket fd for a client

2016-01-11 Thread 박성진
>From 3bdb494aa2be26ed2b8ba9115994fd5f4939d5fa Mon Sep 17 00:00:00 2001 From: Sung-Jin Park Date: Mon, 11 Jan 2016 18:51:21 +0900 Subject: [PATCH] server: Add an API to get the socket fd for a client This adds an API to get the socket fd for a client. The client socket fd can be used