Re: socketpair(2) and getpeereid(3)

2018-04-09 Thread Alexander Bluhm
On Sun, Apr 08, 2018 at 07:10:27AM +0200, Sebastien Marie wrote: > I think it is the more simple way to achieve it. Moving the related code > from unp_connect() to unp_connect2() should be possible (only few direct > callers of {so,unp_}connect2() ), but unp_connid will not be copied on > the two

Re: socketpair(2) and getpeereid(3)

2018-04-07 Thread Sebastien Marie
On Sat, Apr 07, 2018 at 09:29:30PM -0600, Theo de Raadt wrote: > Philip Guenther <pguent...@proofpoint.com> wrote: > > > On Sat, 7 Apr 2018, Sebastien Marie wrote: > > > While running testsuite on third-party program, I found some weird > > > behavio

Re: socketpair(2) and getpeereid(3)

2018-04-07 Thread Theo de Raadt
Philip Guenther <pguent...@proofpoint.com> wrote: > On Sat, 7 Apr 2018, Sebastien Marie wrote: > > While running testsuite on third-party program, I found some weird > > behaviour on us side regarding socketpair(2) and getpeereid(3). > > > > I ported the unit

Re: socketpair(2) and getpeereid(3)

2018-04-07 Thread Philip Guenther
On Sat, 7 Apr 2018, Sebastien Marie wrote: > While running testsuite on third-party program, I found some weird > behaviour on us side regarding socketpair(2) and getpeereid(3). > > I ported the unit test to C (it was Rust) to check more easily. > > It just creates an UNIX d

socketpair(2) and getpeereid(3)

2018-04-07 Thread Sebastien Marie
Hi, While running testsuite on third-party program, I found some weird behaviour on us side regarding socketpair(2) and getpeereid(3). I ported the unit test to C (it was Rust) to check more easily. It just creates an UNIX domain socket using socketpair(2), and next check the euid/egid