Re: unveil ospfd's parent proc

2018-10-28 Thread Remi Locherer
On Sun, Oct 28, 2018 at 03:58:53PM +0100, Florian Obser wrote: > Sorry, I'm on a phone. The diff context looks like the control FD is already > open at this point. Does ospfd later re-open it? > No it does not. It deletes the control socket during shutdown. > On October 27, 2018 11:25:58 PM

Re: unveil ospfd's parent proc

2018-10-28 Thread Remi Locherer
On Sun, Oct 28, 2018 at 07:24:23PM +0100, Sebastian Benoit wrote: > Ricardo Mestre(ser...@helheim.mooo.com) on 2018.10.28 17:26:24 +: > > Correct, and I'd go even further by not unveiling the socket at all. A few > > weeks ago I removed the logic of unlinking the socket when the program > >

Re: unveil ospfd's parent proc

2018-10-28 Thread Ricardo Mestre
Not all daemons have the same behaviour, so if this is still used then Remi's diff of course makes more sense. On 19:24 Sun 28 Oct , Sebastian Benoit wrote: > Ricardo Mestre(ser...@helheim.mooo.com) on 2018.10.28 17:26:24 +: > in ospfd, ospf6d (and hopefully soon bgpd) we make sure the

Re: unveil ospfd's parent proc

2018-10-28 Thread Remi Locherer
On Sun, Oct 28, 2018 at 05:26:24PM +, Ricardo Mestre wrote: > Correct, and I'd go even further by not unveiling the socket at all. A few > weeks ago I removed the logic of unlinking the socket when the program stops, > for a few daemons, but left untouched the ones that don't have the main >

Re: unveil ospfd's parent proc

2018-10-28 Thread Sebastian Benoit
Ricardo Mestre(ser...@helheim.mooo.com) on 2018.10.28 17:26:24 +: > Correct, and I'd go even further by not unveiling the socket at all. A few > weeks ago I removed the logic of unlinking the socket when the program stops, > for a few daemons, but left untouched the ones that don't have the

Re: unveil ospfd's parent proc

2018-10-28 Thread Ricardo Mestre
Correct, and I'd go even further by not unveiling the socket at all. A few weeks ago I removed the logic of unlinking the socket when the program stops, for a few daemons, but left untouched the ones that don't have the main process pledged since it wouldn't make much difference. If we want to go

Re: unveil ospfd's parent proc

2018-10-28 Thread Florian Obser
Sorry, I'm on a phone. The diff context looks like the control FD is already open at this point. Does ospfd later re-open it? On October 27, 2018 11:25:58 PM GMT+02:00, Remi Locherer wrote: >On Fri, Oct 26, 2018 at 10:19:01AM -0600, Theo de Raadt wrote: >> Remi Locherer wrote: >> >> > On

Re: unveil ospfd's parent proc

2018-10-28 Thread Theo de Raadt
Sebastian Benoit wrote: > Remi Locherer(remi.loche...@relo.ch) on 2018.10.27 23:25:58 +0200: > > On Fri, Oct 26, 2018 at 10:19:01AM -0600, Theo de Raadt wrote: > > > Remi Locherer wrote: > > > > > > > On Fri, Oct 26, 2018 at 06:01:40PM +0200, Florian Obser wrote: > > > > > This breaks usage of

Re: unveil ospfd's parent proc

2018-10-28 Thread Sebastian Benoit
Remi Locherer(remi.loche...@relo.ch) on 2018.10.27 23:25:58 +0200: > On Fri, Oct 26, 2018 at 10:19:01AM -0600, Theo de Raadt wrote: > > Remi Locherer wrote: > > > > > On Fri, Oct 26, 2018 at 06:01:40PM +0200, Florian Obser wrote: > > > > This breaks usage of the "include" keyword. Something that

Re: unveil ospfd's parent proc

2018-10-27 Thread Theo de Raadt
Remi Locherer wrote: > On Fri, Oct 26, 2018 at 10:19:01AM -0600, Theo de Raadt wrote: > > Remi Locherer wrote: > > > > > On Fri, Oct 26, 2018 at 06:01:40PM +0200, Florian Obser wrote: > > > > This breaks usage of the "include" keyword. Something that all the > > > > parse.y daemons support. >

Re: unveil ospfd's parent proc

2018-10-27 Thread Remi Locherer
On Fri, Oct 26, 2018 at 10:19:01AM -0600, Theo de Raadt wrote: > Remi Locherer wrote: > > > On Fri, Oct 26, 2018 at 06:01:40PM +0200, Florian Obser wrote: > > > This breaks usage of the "include" keyword. Something that all the > > > parse.y daemons support. > > > > > > > Oh, of course! > >

Re: unveil ospfd's parent proc

2018-10-26 Thread Stuart Henderson
On 2018/10/26 18:15, Remi Locherer wrote: > On Fri, Oct 26, 2018 at 06:01:40PM +0200, Florian Obser wrote: > > This breaks usage of the "include" keyword. Something that all the parse.y > > daemons support. > > > > Oh, of course! > > I guess this is similar to unveil files based on a list of

Re: unveil ospfd's parent proc

2018-10-26 Thread Theo de Raadt
Remi Locherer wrote: > On Fri, Oct 26, 2018 at 06:01:40PM +0200, Florian Obser wrote: > > This breaks usage of the "include" keyword. Something that all the parse.y > > daemons support. > > > > Oh, of course! > > I guess this is similar to unveil files based on a list of command line args.

Re: unveil ospfd's parent proc

2018-10-26 Thread Remi Locherer
On Fri, Oct 26, 2018 at 06:01:40PM +0200, Florian Obser wrote: > This breaks usage of the "include" keyword. Something that all the parse.y > daemons support. > Oh, of course! I guess this is similar to unveil files based on a list of command line args. > On October 26, 2018 5:26:06 PM

Re: unveil ospfd's parent proc

2018-10-26 Thread Florian Obser
This breaks usage of the "include" keyword. Something that all the parse.y daemons support. On October 26, 2018 5:26:06 PM GMT+02:00, Remi Locherer wrote: >Hi, > >this restricts ospfd's parent process to only read it's config file >(reload) >and unlink the control socket on exit. I added

unveil ospfd's parent proc

2018-10-26 Thread Remi Locherer
Hi, this restricts ospfd's parent process to only read it's config file (reload) and unlink the control socket on exit. I added unveil after the setup of the control socket is done since chmod is used in control_init. OK? Remi Index: ospfd.c