Re: OpenSMTPD and mask-source flag.

2016-02-12 Thread Gilles Chehade
On Thu, Feb 11, 2016 at 05:28:50PM -0500, Peter Bisroev wrote: > Hi Gilles, > > Please find my diff inline to enable "listen on socket" feature that we have > discussed. I have tested the diff with currently two supported listen options > for this listener, mask-sender and filter. Everything

[patch] Fix carp(4) with balancing ip / ip-stealth

2016-02-12 Thread Florian Riehm
Hi Tech, I have noticed that CARP IP-Balancing is broken, so I am testing and fixing it. The first problem came in with this commit: http://cvsweb.openbsd.org/cgi-bin/cvsweb/src/sys/net/if_ethersubr.c.diff?r1=1.176=1.177 It enforces that outgoing packets use the src mac of the carp interface

Re: Allow top(1) to search arguments

2016-02-12 Thread Edd Barrett
Hey, Thanks all for the comments. On Wed, Feb 10, 2016 at 04:27:38PM -0800, patrick keshishian wrote: > NULL pointer dereference is possible here. > > Also, unclear why you need both arg and args variables. ^ Fix these and make cmd_matches() static. Updated diff: Index: machine.c

Fix overflow check in sys/netinet6/in6.c

2016-02-12 Thread Michael McConville
time_second is a time_t, which we define as int64_t. The other operands used are of type uint32_t. Therefore, these checks get promoted to int64_t and the overflow being tested is undefined because it uses signed arithmetic. I think that the below diff fixes the overflow check. However, I'm

pax name_split() error

2016-02-12 Thread Peter Bisroev
Dear Developers, I believe there is an issue with pax when it tries to archive path names that are exactly 101 bytes long and start with a slash. For example (sorry for long lines) $ pax -x ustar -w -f ./test.tar

Re: pax name_split() error

2016-02-12 Thread Otto Moerbeek
On Fri, Feb 12, 2016 at 11:48:11PM -0500, Peter Bisroev wrote: > Dear Developers, > > I believe there is an issue with pax when it tries to archive path names that > are exactly 101 bytes long and start with a slash. For example (sorry for > long lines) > > $ pax -x ustar -w -f ./test.tar >

Re: OpenSMTPD and mask-source flag.

2016-02-12 Thread Peter Bisroev
> Just in case the previous diff is OK, I am attaching the patch to the > smtpd.conf man page. Hi Gilles, I apologize, my previous manpage diff did not include the information regarding the fact that connections through local socket will always be tagged 'local'. Please find the corrected

Re: OpenSMTPD and mask-source flag.

2016-02-12 Thread Peter Bisroev
Hi Gilles, While looking over smtp_enqueue(), I have noticed that setting of hostname is a noop. It looks like a leftover code from a bugfix in here (http://cvsweb.openbsd.org/cgi-bin/cvsweb/src/usr.sbin/smtpd/smtp.c.diff?r2=1.141=1.140=u) I am including a diff to smtp.c below that includes the

Re: Integer overflow in syslogd

2016-02-12 Thread Michael McConville
Michael Savage wrote: > Here's a patch with less fragile parsing code. Comments inline. > Index: syslogd.c > === > RCS file: /cvs/src/usr.sbin/syslogd/syslogd.c,v > retrieving revision 1.177 > diff -u -p -r1.177 syslogd.c > ---

[patch] -- Re: Kernel and PF disagree on TCP RST handling

2016-02-12 Thread Tor Perkins
Please refer to my previous message for a detailed explanation. What follows is a brief rationale and a patch... The kernel should handle TCP RST packets using the same criteria as PF. PF accepts the exact SEQ and the SEQ +1/-1 case, as seen here: vi /usr/src/sys/net/pf.c +/'match on resets'

Re: Integer overflow in syslogd

2016-02-12 Thread Michael Savage
Here's a patch with less fragile parsing code. Mike Index: syslogd.c === RCS file: /cvs/src/usr.sbin/syslogd/syslogd.c,v retrieving revision 1.177 diff -u -p -r1.177 syslogd.c --- syslogd.c 20 Jul 2015 19:49:33 - 1.177

Re: OpenSMTPD and mask-source flag.

2016-02-12 Thread Peter Bisroev
> I only skimmed through your diff, I need to apply it and read in > context but I like it a lot. > > I'll test today and come back with comments once I've spent more > time reading it ;-) > > Thanks Awesome, thank you Gilles! Just in case the previous diff is OK, I am attaching the patch to

Re: Integer overflow in syslogd

2016-02-12 Thread Michael Savage
I've added a comment and replaced memcpy with strlcpy as suggested. > Nitpick, but I'd probably slightly prefer parse_priority. Me too, but it gets called by printline/printsys so I copied that. If anyone has stronger feelings about it I'll change it to whatever. > Looking at the old code