Re: ping6: out of boundary access with invalid packets

2015-09-09 Thread Florian Obser
On Tue, Sep 08, 2015 at 09:45:06PM +0200, Tobias Stoeckmann wrote: > The function pr_pack does not properly check boundaries before > accessing packet data. This could happen on short network reads or > when we receive packets that are addressed for another running ping6 > instance (see pr_pack com

pflow(4): reshuffle socreate(9)

2015-09-12 Thread Florian Obser
Call socreate(9) only when we have a destination ip and port. Call sobind(9) only when we have a source ip. With this we can treat sc->so != NULL as a flag if the interface is in state IFF_RUNNING. OK? diff --git if_pflow.c if_pflow.c index c70ad81..829ec72 100644 --- if_pflow.c +++ if_pflow.c @@

IPv6 transport for pflow(4)

2015-09-13 Thread Florian Obser
I don't really like to store struct sockaddr_storage since it's so big. I played around with a union like pf does, but looked complicated. Thoughts? Also with this you can specify a source port. Since I was touching all those lines anyway I renamed sender to flowsrc and receiver to flowdst like th

Re: IPv6 transport for pflow(4)

2015-09-13 Thread Florian Obser
On Sun, Sep 13, 2015 at 03:25:16PM +, Florian Obser wrote: > I don't really like to store struct sockaddr_storage since it's so > big. I played around with a union like pf does, but looked > complicated. > Thoughts? > > Also with this you can specify a source port

Re: The router doesn't know the size of the internet...

2015-10-24 Thread Florian Obser
On Sat, Oct 24, 2015 at 06:15:48PM +0200, Sebastian Benoit wrote: > Alexander Bluhm(alexander.bl...@gmx.net) on 2015.10.24 17:21:27 +0200: > > On Sat, Oct 24, 2015 at 04:02:59PM +0200, Martin Pieuchot wrote: > > > ...at least better than OpenBSD's source code. > > > > > > This diff gets rid of the

Re: mg: fgetln -> getline

2017-10-11 Thread Florian Obser
On Sun, Sep 17, 2017 at 02:56:32AM +, Scott Cheloha wrote: > Hi, > > This will make mg(1) ever so slightly more portable: downstream > will appreciate it. And fgetln(3) was recently deprecated. > > Misc. comments: > > The comments about NUL and "the last line problem" aren't per se > applic

Re: mg: fgetln -> getline

2017-10-12 Thread Florian Obser
OK florian@ or if someone gives me an OK I'll commit it. On Thu, Oct 12, 2017 at 04:17:10AM +, Scott Cheloha wrote: > > On Oct 11, 2017, at 2:36 AM, Florian Obser wrote: > > > > On Sun, Sep 17, 2017 at 02:56:32AM +, Scott Cheloha wrote: > >> >

Re: mg: fgetln -> getline

2017-10-12 Thread Florian Obser
commited, thanks! On Thu, Oct 12, 2017 at 04:17:10AM +, Scott Cheloha wrote: > > On Oct 11, 2017, at 2:36 AM, Florian Obser wrote: > > > > On Sun, Sep 17, 2017 at 02:56:32AM +, Scott Cheloha wrote: > >> > >> > >>if (buf[len - 1

Re: KAME ioctl leftovers

2017-10-18 Thread Florian Obser
On Wed, Oct 18, 2017 at 11:34:27AM +, Martin Pieuchot wrote: > Kill ioctl(2) added with original KAME import that have never been used. > FreeBSD also stopped supporting them in 2013. usr.sbin/bind is looking at SIOCGLIFADDR, but it looks like it's properly guarded by #ifdef. debian codesearch

Re: fix memory handling in acme-client config parser

2017-10-18 Thread Florian Obser
OK florian@ On Thu, Oct 19, 2017 at 05:33:35AM +, Jonathan Gray wrote: > Use after free and a memory leak. > > Index: parse.y > === > RCS file: /cvs/src/usr.sbin/acme-client/parse.y,v > retrieving revision 1.17 > diff -u -p -U4 -

Re: Kill deprecated IPv6 ioctl(2)s

2017-10-25 Thread Florian Obser
On Wed, Oct 25, 2017 at 10:56:40AM +, Martin Pieuchot wrote: > On 25/10/17(Wed) 21:53, Jonathan Gray wrote: > > On Wed, Oct 25, 2017 at 12:20:45PM +0200, Martin Pieuchot wrote: > > > Diff below remove some more deprecated ioctl(2). The first group below > > > correspond to features now depreca

Re: Kill deprecated IPv6 ioctl(2)s

2017-10-25 Thread Florian Obser
OK florian@ On Wed, Oct 25, 2017 at 10:20:45AM +, Martin Pieuchot wrote: > Diff below remove some more deprecated ioctl(2). The first group below > correspond to features now deprecated by slaacd(8): > > SIOCSIFINFO_FLAGS, SIOCSNDFLUSH_IN6, SIOCSPFXFLUSH_IN6, SIOCSRTRFLUSH_IN6 > > Removin

move NET_LOCK into pr_{slow,fast}timo() functions

2017-10-29 Thread Florian Obser
intentionally (mostly) mechanical OK? diff --git kern/uipc_domain.c kern/uipc_domain.c index 4cfbe5de4ff..0f4d05f7492 100644 --- kern/uipc_domain.c +++ kern/uipc_domain.c @@ -238,13 +238,11 @@ pfslowtimo(void *arg) struct protosw *pr; int i; - NET_LOCK(); for (i =

remove NET_LOCK from ip_slowtimo()

2017-10-29 Thread Florian Obser
on top of previous... OK? diff --git netinet/ip_input.c netinet/ip_input.c index dc1bb9d8ec1..95c9194efcb 100644 --- netinet/ip_input.c +++ netinet/ip_input.c @@ -1028,7 +1028,6 @@ ip_slowtimo(void) { struct ipq *fp, *nfp; - NET_LOCK(); mtx_enter(&ipq_mutex); LIST

unbound(8): make ip-transparent option work on OpenBSD

2017-11-01 Thread Florian Obser
This is useful on systems where IP addresses are dynamically configured (dhclient(8), slaacd(8)) and are not yet up when unbound starts. To quote the man page: ip-transparent: If yes, then use IP_TRANSPARENT socket option on sockets where unbound is listening f

nsd(8): make ip-transparent option work on OpenBSD

2017-11-01 Thread Florian Obser
OK? diff --git server.c server.c index c0835ce8c11..fe74f9a1b56 100644 --- server.c +++ server.c @@ -567,7 +567,7 @@ server_init_ifs(struct nsd *nsd, size_t from, size_t to, int* reuseport_works) { struct addrinfo* addr; size_t i; -#if defined(SO_REUSEPORT) || defined(SO_REUSEADD

move PRU_DETACH out of pr_usrreq

2017-11-02 Thread Florian Obser
this moves PRU_DETACH out of pr_usrreq into per proto pr_detach functions, like what claudio did to pr_attach. Intentionally mostly mechanical. There might be some cleanup here and there in the functions themselves. OK? diff --git kern/uipc_proto.c kern/uipc_proto.c index 1e86120f374..8797f0d632

tedu raw_disconnect()

2017-11-02 Thread Florian Obser
There is no way SS_NOFDREF is set on a raw socket in raw_usrreq for PRU_DISCONNECT or PRU_ABORT. So raw_disconnect() and sofree() return immediately so remove the dead code. Also the following call to soisdisconnected() would be a use after free. This removes the last calls to raw_disconnect() so

tedu raw_cb.c

2017-11-02 Thread Florian Obser
This inlines all the trivial functions in the various places. OK? diff --git sys/conf/files sys/conf/files index 03b4a0e24cc..2771b6f4446 100644 --- sys/conf/files +++ sys/conf/files @@ -788,7 +788,6 @@ file net/switchctl.cswitch file net/switchofp.c swit

merge nd6_rs_input() and nd6_ra_input()

2017-11-02 Thread Florian Obser
We are processing Router Solicitation / Advertisement messages only for the Source Link-layer Address Options. Merge nd6_rs_input() and nd6_ra_input() into one generic function. OK? diff --git netinet6/icmp6.c netinet6/icmp6.c index 421280690c9..b5e12169584 100644 --- netinet6/icmp6.c +++ netinet

slaacd(8) install default routes with mpath flag

2017-11-03 Thread Florian Obser
It is possible to have multiple routers sending router advertisements, so mark the default route mpath. Comments, OKs? diff --git slaacd.c slaacd.c index 5e00cdb123c..06c11b241d5 100644 --- slaacd.c +++ slaacd.c @@ -737,7 +737,7 @@ configure_gateway(struct imsg_configure_dfr *dfr, uint8_t rtm_ty

Re: if_ioctl & netinet{,6}

2017-11-03 Thread Florian Obser
On Wed, Nov 01, 2017 at 06:03:26PM +, Martin Pieuchot wrote: > ifioctl() contains two fallthrough paths that end up in ifp->if_ioctl(). > The diff below merges them. > > But instead of calling ifp->if_ioctl() from inside in{,6}_ioctl(), I > changed the logic to return EOPNOTSUPP. The idea is

Re: if_ioctl & netinet{,6}

2017-11-03 Thread Florian Obser
On Fri, Nov 03, 2017 at 12:31:42PM +, Martin Pieuchot wrote: > On 03/11/17(Fri) 13:23, Florian Obser wrote: > > On Wed, Nov 01, 2017 at 06:03:26PM +, Martin Pieuchot wrote: > > > ifioctl() contains two fallthrough paths that end up in ifp->if_ioctl(). > > &

free sizes for pfkeyv2 and rtsock

2017-11-03 Thread Florian Obser
After inlining of raw_detach we know the sizes for free; pointed out by mpi. OK? diff --git pfkeyv2.c pfkeyv2.c index d0ae384aaa2..dcb66c06fe5 100644 --- pfkeyv2.c +++ pfkeyv2.c @@ -284,7 +284,7 @@ pfkeyv2_detach(struct socket *so) so->so_pcb = NULL; sofree(so); - free(&kp

Re: merge nd6_rs_input() and nd6_ra_input()

2017-11-03 Thread Florian Obser
On Fri, Nov 03, 2017 at 01:37:40PM +, Martin Pieuchot wrote: > On 02/11/17(Thu) 23:25, Florian Obser wrote: > > We are processing Router Solicitation / Advertisement messages only > > for the Source Link-layer Address Options. > > Merge nd6_rs_input() and nd6_ra_inp

convert frag6 to mutex

2017-11-04 Thread Florian Obser
replace hand rolled LOCK/UNLOCK macros with a mutex like in the v4 case. While here remove the NET_LOCK. OK? diff --git frag6.c frag6.c index a5b8ae261be..390115106c5 100644 --- frag6.c +++ frag6.c @@ -34,6 +34,7 @@ #include #include #include +#include #include #include #include @@ -

finish off pr_drain functions

2017-11-04 Thread Florian Obser
... they haven't been used since 2006. OK? (This is on top of "convert frag6 to mutex", but the order doesn't matter, the conflict is trivial) diff --git netinet/in_proto.c netinet/in_proto.c index 6efbac7da5c..2667bba6124 100644 --- netinet/in_proto.c +++ netinet/in_proto.c @@ -179,7 +179,6 @@

Re: convert frag6 to mutex

2017-11-05 Thread Florian Obser
please ignore this one, mpi points out that visa has a more comprehensive diff for this that I missed. -- I'm not entirely sure you are real.

Re: [PATCH] amd64/bsd.rd: add growfs(8)

2017-11-08 Thread Florian Obser
On Tue, Nov 07, 2017 at 06:15:09PM +, Job Snijders wrote: > On Mon, Nov 06, 2017 at 04:14:48PM -0700, Theo de Raadt wrote: > > I agree on that. So please put it into the correct lists files for > > all the unlimited ramdisks. > > > > Job, the situation is a little nit-picky but try to do it f

slaacd(8): Move privileged initialization from frontend to main process.

2017-11-29 Thread Florian Obser
Move privileged initialization from frontend to main process. Needed for future work where we will spin up children via fork - privdrop - exec. OK? diff --git control.c control.c index 76b0f3b15ea..96a6206c874 100644 --- control.c +++ control.c @@ -85,9 +85,7 @@ control_init(char *path)

Re: mg: have Insert key toggle overwrite mode by default

2017-12-17 Thread Florian Obser
OK On Sat, Dec 16, 2017 at 10:06:59PM +, Lari Rasku wrote: > There's a fairly strong convention among text editors that the Insert > key should toggle overwrite mode. This is admittedly far more common > among GUI editors, but could mg adopt it as a default anyway? > > diff --git usr.bin/mg/

nsd 4.1.19

2018-01-12 Thread Florian Obser
so, here is 4.1.19. I haven't gotten around to reading the diff yet. But I tossed it in production. When trying to re-gen config.h.in autheader bombs out: [florian@openbsd-build:/usr/src/usr.sbin/nsd]$ autoheader-2.69 autoheader-2.69: warning: missing template: HAVE_B64_NTOP autoheader-2.69: Use

Re: nsd 4.1.19

2018-01-12 Thread Florian Obser
Oh and yes, that packed BS is completely retarded. Seeing how many commits it took to have it not constantly spass out on different compilers, it's amazing that someone didn't take the hint and gave up on it. No idea what the usecase is suppsed to be. -- I'm not entirely sure you are real.

Re: nsd 4.1.19

2018-01-13 Thread Florian Obser
On Fri, Jan 12, 2018 at 11:28:48AM -0700, Todd C. Miller wrote: > On Fri, 12 Jan 2018 18:20:58 +0100, Florian Obser wrote: > > > so, here is 4.1.19. I haven't gotten around to reading the diff yet. > > But I tossed it in production. > > > > When trying to re-

Re: inteldrm(4) tests needed

2018-01-15 Thread Florian Obser
On Mon, Jan 15, 2018 at 01:02:58AM +0100, Mark Kettenis wrote: > The diff below adopts more of the Linux code to manage i2c > transactions on hardware supported by inteldrm(4). The i2c stuff is > reponsible for detecting panels and monitors, so it is somewhat > important that this works right. An

Re: nsd 4.1.19

2018-01-26 Thread Florian Obser
anyone else? Got around to read the diff, not too much insanity in there, going to commit soon. rebased on top of millert@'s autohell fix: diff --git Makefile.in Makefile.in index 495160c0826..3468101c19d 100644 --- Makefile.in +++ Makefile.in @@ -286,9 +286,6 @@ qtest.o:$(srcdir)/tpkg/cutest

Re: nsd 4.1.19

2018-01-26 Thread Florian Obser
On Fri, Jan 26, 2018 at 05:38:46PM +, Stuart Henderson wrote: > On 2018/01/26 18:12, Florian Obser wrote: > > anyone else? > > Got around to read the diff, not too much insanity in there, going to > > commit soon. > > ok with me. > > > diff --g

#include cleanup for ping6

2015-11-04 Thread Florian Obser
I think this is correct... OK? diff --git ping6.c ping6.c index 2c786f9..8e42ade 100644 --- ping6.c +++ ping6.c @@ -81,35 +81,29 @@ */ #include -#include #include - -#include -#include +#include #include #include #include #include #include -#include #include #include

pledge for nsd

2015-11-20 Thread Florian Obser
Tested with and without zone transfers, forced writing of zones to disk and adding and removing zones at run time. Is the order of pledges in main() correct? OK? diff --git nsd.c nsd.c index 2420a65..d2084b7 100644 --- nsd.c +++ nsd.c @@ -,6 +,11 @@ main(int argc, char *argv[])

ping(8) / ping6(8) source address

2015-11-29 Thread Florian Obser
Inspired by the traceroute / traceroute6 merge. At least reduces the diff in the option parser :) OK? diff --git ping/ping.c ping/ping.c index f5ccaca..4944f77 100644 --- ping/ping.c +++ ping/ping.c @@ -110,7 +110,7 @@ int options; #defineF_SO_DEBUG 0x0040 /* 0x0

use ping6(8)'s engine in ping(8)

2015-11-29 Thread Florian Obser
This shoves a round peg into a square hole with considerable force... I was only concerned with moving the functionality over from ping6, further cleanup will happen on top of this. OK? diff --git ping.c ping.c index 4944f77..a3a6fe3 100644 --- ping.c +++ ping.c @@ -147,8 +147,7 @@ unsigned long

Re: rtadvd: remove router renumbering support

2015-11-30 Thread Florian Obser
yes please. while in there you should deleted the commented .Fl m from the man page, too. OK florian@ On Mon, Nov 30, 2015 at 08:12:32PM +0100, Jeremie Courreges-Anglas wrote: > > ie. https://tools.ietf.org/html/rfc2894 > > This code has been rotting since a long time, only activated during two

Re: rtadvd: useless argument/checks in if.c:get_next_msg()

2015-11-30 Thread Florian Obser
OK florian@ On Mon, Nov 30, 2015 at 01:58:16PM +0100, Jeremie Courreges-Anglas wrote: > > Hi, > > get_next_msg() takes an "ifindex" argument, and contains code to check > whether the interface affected by a routing message is "the correct > one". Those tests have always been meaningless since i

Re: using -Werror-implicit-function-declaration

2014-07-10 Thread Florian Obser
/sbin: diff --git sbin/Makefile.inc sbin/Makefile.inc index 1b14860..92ca312 100644 --- sbin/Makefile.inc +++ sbin/Makefile.inc @@ -2,3 +2,4 @@ BINDIR?= /sbin LDSTATIC= ${STATIC} +CFLAGS+= -Werror-implicit-function-declaration diff --git sbin/disklabel/editor.c sbin/disklabel/

Re: using -Werror-implicit-function-declaration

2014-07-11 Thread Florian Obser
usr.sbin, missing prototypes: diff --git usr.sbin/mrouted/defs.h usr.sbin/mrouted/defs.h index 4c9224a..45b060f 100644 --- usr.sbin/mrouted/defs.h +++ usr.sbin/mrouted/defs.h @@ -209,6 +209,7 @@ extern void accept_leave_message(u_int32_t src, u_int32_t dst, u_i

Re: using -Werror-implicit-function-declaration

2014-07-11 Thread Florian Obser
usr.sbin, fix bind configure: Carefully checked that config.h and generated Makefiles don't change. diff --git usr.sbin/bind/configure usr.sbin/bind/configure index 6e280ad..db02979 100644 --- usr.sbin/bind/configure +++ usr.sbin/bind/configure @@ -4596,6 +4596,8 @@ cat confdefs.h >>conftest.$ac_e

Re: using -Werror-implicit-function-declaration

2014-07-11 Thread Florian Obser
usr.sbin, fix nsd/unbound configure carefully checked that config.h and generated Makefiles don't change. need for _XOPEN_VERSION pointed out by guenther@ diff --git usr.sbin/nsd/configure usr.sbin/nsd/configure index d2d28c1..c2a40e8 100644 --- usr.sbin/nsd/configure +++ usr.sbin/nsd/configure @

Re: using -Werror-implicit-function-declaration

2014-07-11 Thread Florian Obser
usr.sbin, make sure subdirs of subdirs see usr.sbin/Makefile.inc: Does the same thing as lpr/pac and pppd/pppstats. I have no idea if this is the right way, but it seems to work. Cluebats welcome. diff --git usr.sbin/lpr/filters/Makefile usr.sbin/lpr/filters/Makefile index be83507..7308625 100644

Re: using -Werror-implicit-function-declaration

2014-07-11 Thread Florian Obser
usr.sbin; enable -Werror-implicit-function-declaration: This has currently no effect on subdirs using Makefile.bsd-wrapper (bind, nginx, nsd, unbound). This is beeing worked on. With a workaround they have been tested and with the previous diffs are clean. diff --git usr.sbin/Makefile.inc usr.sbi

Re: recent ipv6 changes: how to pick up rtadv without an autoconf address?

2014-07-25 Thread Florian Obser
On Fri, Jul 25, 2014 at 02:28:15PM +0100, Stuart Henderson wrote: > Following the recent IPv6 changes, what method should now be used > to have a statically configured ipv6 address but accept router > advertisements to pick up a default route? > as discussed on icb: --8<--8<-

Move sending of router solicitation packages to the kernel

2014-08-09 Thread Florian Obser
This moves sending of router solicitation packages to the kernel. With it rtsol{,d}(8) is no longer needed. Add inet6 autoconf to /etc/hostname.IF or run ifconfig IF inet6 autoconf and the kernel will start sending rtsol packages. An the following events a timer will be (re) started with a timeout

Re: Bug in gethostbyaddr and patch to solve

2014-08-26 Thread Florian Obser
On Mon, Aug 25, 2014 at 10:39:59PM -0500, Vladimir Támara Patiño wrote: > Using tcpdump in a firewall with 5.5 (also happens with 5.4 and I guess with > current) and certain addres of the LAN I got always a segfault. Nope, already fixed in the upcomming 5.6 release and -current. http://cvsweb.ope

Re: getent(1) hosts enumeration defunc

2014-10-19 Thread Florian Obser
Hi Ingo, On Sun, Oct 19, 2014 at 02:24:27AM +0200, Ingo Schwarze wrote: > Hi Philip, > > Philip Guenther wrote on Sat, Oct 18, 2014 at 04:38:09PM -0700: > > > Maybe we just fix getent(1) to return an error like it does for ethers? > > Whatever we do with gethostent(3) - maybe it's really expend

Re: mg: exit code cleanup

2014-11-13 Thread Florian Obser
Commited, thanks! On Sun, Nov 09, 2014 at 08:40:03PM +0100, Martin Natano wrote: > mg(1) calls 'exit(1)' on failure, but 'exit(GOOD)' on success. In my > opinion it would be more readable to just use 'exit(0)' for a normal > exit. (If there really is the need for a define, EXIT_SUCCESS would be a

relayd errata Nov 17

2014-11-17 Thread Florian Obser
This patch fixes a relayd crash for the 5.6 release. untrusted comment: signature from openbsd 5.6 base private key RWR0EANmo9nqhgFKMGabOlUXoxAuey9xQyKcm0OULFMOSkyd3ReQHQjwA1psSBbqu1ex9j28D/nyEh6U8uj8f2oFZtXoHA7njAg= OpenBSD 5.6 errata 6, Nov 17, 2014: Fix for relayd crash Apply patch using:

Re: httpd: don't send error body with HEAD method

2014-11-24 Thread Florian Obser
On Sun, Nov 23, 2014 at 08:15:47PM -0500, Bertrand Janin wrote: > Hi, > > This patch updates server_abort_http() to only send the body of default http > error if the method is not HEAD. I first noticed that with curl -v -I which > complains about the excess data: > > * Excess found in a non p

Re: rtadvd on OpenBSD 5.6 with Comcast cable connection

2015-01-01 Thread Florian Obser
(moved to tech@) On Thu, Jan 01, 2015 at 11:51:32AM -0600, Aaron Riekenberg wrote: > I found some other reports of the same problem with rtadvd logging > excessive messages about router advertisements on the external > non-advertising interface. > > From OpenBSD 5.2: > http://openbsd.7691.n7.nabb

Re: 5.6, IPv6: is autoconf set by default?

2015-01-10 Thread Florian Obser
On Sat, Jan 10, 2015 at 02:07:49PM +, Stuart Henderson wrote: > [moved from misc@] > > On 2015-01-08, Josh Grosse wrote: > > On Thu, Jan 08, 2015 at 03:20:46PM +, Florian Obser wrote: > > > >> [...] > >> > >> eui64 Fill the in

allow stateless address auto configuration when v6 forwarding is enabled

2015-03-23 Thread Florian Obser
[ this originated on misc@: https://marc.info/?t=14170362181&r=1&w=2 ] so there are setups out there where a router gets a default route (and maybe a prefix) via SLAAC (think dsl / cable line). Currently the kernel does not accept a default route via SLAAC when forwarding is enabled. Since we

Re: allow stateless address auto configuration when v6 forwarding is enabled

2015-03-23 Thread Florian Obser
On Mon, Mar 23, 2015 at 08:22:46PM +0100, Stefan Sperling wrote: > On Mon, Mar 23, 2015 at 06:21:40PM +0000, Florian Obser wrote: > > [ this originated on misc@: > > https://marc.info/?t=14170362181&r=1&w=2 ] > > > > so there are setups out there where a r

Re: mg(1) segfaults on scroll-down

2015-03-24 Thread Florian Obser
Hi, On Wed, Mar 18, 2015 at 01:35:08PM +0200, Kaspars Bankovskis wrote: > Hi, > > to reproduce the issue: > > (1) start mg and press Enter, until you fill up the screen and it goes > on to the next screen. > (2) type in at least one character > (3) press M-v (or execute command scroll-down) > (4

Re: httpd fastcgi diff

2015-03-25 Thread Florian Obser
On Wed, Mar 25, 2015 at 10:20:53PM +0100, Tim van der Molen wrote: > I'm using the hgweb.cgi Python script to serve Mercurial repositories > over HTTP. When served by httpd, hgweb.cgi does not work well with the > hg command-line utility. For example, this doesn't work: > > $ hg clone http://examp

Re: Small ifconfig output tweak for inet6?

2015-03-26 Thread Florian Obser
On Thu, Mar 26, 2015 at 05:46:12PM +0100, Henning Brauer wrote: > * Mike Belopuhov [2015-03-26 14:36]: > > however I agree that if we do this for ipv6 we should do it for ipv4 as well > > but then do we care about tons of stuff out there parsing ifconfig output? > > that's the prime question. I w

Re: Small ifconfig output tweak for inet6?

2015-03-26 Thread Florian Obser
On Thu, Mar 26, 2015 at 01:48:03PM +0100, Martin Pieuchot wrote: > How do people feel about printing the prefixlen in CIDR notation? I'm > annoyed about outputs not fitting in 80 chars when using autoconf magic: > > -inet6 fd00::f2de:f1ff:fe6a:15d1 prefixlen 64 autoconf pltime 3594 vltime 7194 >

Re: Small ifconfig output tweak for inet6?

2015-03-26 Thread Florian Obser
On Thu, Mar 26, 2015 at 06:50:37PM +0100, Martin Pieuchot wrote: > On 26/03/15(Thu) 17:39, Florian Obser wrote: > > On Thu, Mar 26, 2015 at 01:48:03PM +0100, Martin Pieuchot wrote: > > > How do people feel about printing the prefixlen in CIDR notation? I'm > > > a

Re: mg(1) segfault

2015-04-04 Thread Florian Obser
On Sat, Apr 04, 2015 at 10:48:15AM -0300, Gleydson Soares wrote: > > mg(1) segfault. > it is triggered as follows: > > 1- echo "(start-kbd-macro)" >> $HOME/.mg > 2- open mg and type twice C-x ( > > find below the backtrace and a patch to fix. > OK? > > Program received signal SIGBUS, Bus error.

Re: mg(1) segfault

2015-04-04 Thread Florian Obser
On Sat, Apr 04, 2015 at 03:23:45PM -0300, Gleydson Soares wrote: > > return (macrodef = FALSE); > > but we shouldn't change macrodef here. > I hate the startup file. Look, this is a use after free, but I can't find it... #0 0x1b9de0b1b77f in definemacro (f=0, n=1) at /u

Re: copy'n'paste like typo in pf.c

2015-04-05 Thread Florian Obser
On Sun, Apr 05, 2015 at 11:48:21AM +0200, Alexandr Nedvedicky wrote: > Hello, > > when we ran PF sources through coverity we got an error > as follows: > > 8310 if (ri->r->dst.addr.type == PF_ADDR_TABLE) > 8311 pfr_update_stats(ri->r->dst.addr.p.tbl, > 8312

Re: Byte range implementation for httpd(8)

2015-05-02 Thread Florian Obser
Sorry for the very late reply, I'm currently very busy :/ On Fri, Apr 17, 2015 at 05:04:01AM +0200, Sunil Nimmagadda wrote: > Range requests as defined in RFC7233 is required for resuming > interrupted http(s) downloads for example: > ftp -C http://foo.bar/install57.iso > > With this diff, httpd

Re: Byte range implementation for httpd(8)

2015-05-03 Thread Florian Obser
On Sun, May 03, 2015 at 01:46:56PM +0200, Sunil Nimmagadda wrote: > On Sat, May 02, 2015 at 02:49:30PM +0000, Florian Obser wrote: > > Sorry for the very late reply, I'm currently very busy :/ > > Thank you for taking time to review it. A new patch with style nits > fixe

Re: [PATCH] Support If-Modified-Since header on requests in httpd

2015-05-03 Thread Florian Obser
On Sat, Apr 18, 2015 at 12:19:46PM -0500, jmp wrote: > I found 'timeoff' to be useful for converting to a time_t that is in > GMT; however, did not find documentation on this in the man pages. It > seems to be a function dating back to at least the NetBSD fork. If > there is a better time function

Re: [PATCH] Support If-Modified-Since header on requests in httpd

2015-05-03 Thread Florian Obser
On Sun, May 03, 2015 at 11:14:48AM -0500, Kyle Thompson wrote: > On Sun, May 03, 2015 at 03:00:40PM +0000, Florian Obser wrote: > > On Sat, Apr 18, 2015 at 12:19:46PM -0500, jmp wrote: > > RFC 7232 > > > >A recipient MUST ignore the If-Modified-Since header field i

Re: Byte range implementation for httpd(8)

2015-05-03 Thread Florian Obser
On Sun, May 03, 2015 at 08:14:25PM +0200, Sebastian Benoit wrote: > one question though: whats the reasoning behind MAX_RANGES 4? nginx seems to > have a default of "unlimited" (which i think questionable), but what is Wasn't there a cve about this last year or so? You can try to burn cpu and io o

Re: [Patch] httpd - don't leak fcgi file descriptors

2015-06-09 Thread Florian Obser
On Mon, Jun 08, 2015 at 09:17:41PM +0200, Claudio Jeker wrote: > On Mon, Jun 08, 2015 at 09:12:32PM +0200, Joerg Jung wrote: > > On Tue, Jun 02, 2015 at 05:47:47PM +0200, Claudio Jeker wrote: > > > On Tue, Jun 02, 2015 at 01:50:35PM +0200, Joerg Jung wrote: > > > > > > > > > Am 01.06.2015 um 01:25

traceroute(8): make progress on timeout

2017-01-13 Thread Florian Obser
traceroute(8) never sees a timeout when poll(2) returns when it receives a packet not intended for us. E.g. a ping(8) is running in parallel. In this case we need to account for the time we already waited. Pointed out by Gabriel Nieto on bugs@, thanks! OK? diff --git traceroute.c traceroute.

Re: src/usr.sbin/slowcgi: possible bug

2017-01-13 Thread Florian Obser
On Mon, Jan 02, 2017 at 04:29:21PM +0330, temp+...@frad.ir wrote: > Hi tech@, > > I recently checked the slowcgi(8) and found that it might have an issue > when buf_pos is at the end of buffer and buf_len is zero. > > Am I right? we can simplify this even more. There is no need to remember the b

nsd 4.1.14

2017-01-14 Thread Florian Obser
tests, OKs? diff --git configlexer.lex configlexer.lex index e6b26f947e1..42dbd152f16 100644 --- configlexer.lex +++ configlexer.lex @@ -66,15 +66,6 @@ static void config_start_include(const char* filename) c_error_msg("include %s: malloc failure", filename); return

pflow(4): allow changing receiver ip

2017-01-14 Thread Florian Obser
... without changing the address family at the same time Easier to see with diff -b OK? diff --git if_pflow.c if_pflow.c index 8e95aaf753f..80758b60bd5 100644 --- if_pflow.c +++ if_pflow.c @@ -335,32 +335,35 @@ pflow_set(struct pflow_softc *sc, struct pflowreq *pflowr) }

pflow(4): allow changing sender ip

2017-01-14 Thread Florian Obser
... without changing the address family at the same time Easier to read with diff -b. This + previous fixes the ``ifconfig'' pflow regress test. OK? diff --git if_pflow.c if_pflow.c index 80758b60bd5..2933df9b444 100644 --- if_pflow.c +++ if_pflow.c @@ -372,46 +372,37 @@ pflow_set(struct pflow_

Re: pfctl: Kill states within a rdomain

2017-01-25 Thread Florian Obser
On Wed, Jan 25, 2017 at 10:45:55AM -0500, Bertrand Provost wrote: > Hi, > > On 2017-01-24 07:26 PM, Sebastian Benoit wrote: > > but your diff does not seem to be against -current, you started from 6.0 > > > > But even with 6.0 i get rejects, maybe you mail client messes this up. > My patch is base

Re: pfctl: Kill states within a rdomain

2017-01-25 Thread Florian Obser
OK florian@ On Wed, Jan 25, 2017 at 07:12:14PM -0500, Bertrand Provost wrote: > Hi, > > Based on feedback from jmc and florian here a new version of the patch > - Add -V in usage() && __dead usage() > - Change man > > (I hope this time my mail client is well configure) > > Regards, > > -- >

Re: unbound 1.6.1rc1

2017-02-17 Thread Florian Obser
On Tue, Feb 14, 2017 at 10:45:08PM +, Stuart Henderson wrote: > On 2017/02/09 15:59, Stuart Henderson wrote: > > Here's an update to the release candidate for 1.6.1. Tests/feedback welcome. > > Diff is 600K so it's at https://junkpile.org/unbound-1.6.1rc1.diff rather > > than inline. > > Updat

Re: nsd 4.1.15

2017-02-17 Thread Florian Obser
... and in case you want to see what's actually going on, this is without the _t conversion churn: commit 4cfab5a8d90abb380ae6a64da825883a2f360dc1 Author: Florian Obser Date: Fri Feb 17 15:04:08 2017 +0100 log at verbosity 3. diff --git nsec3.c nsec3.c index f24377d4259..960e72

Re: pflow(4) percpu counters

2017-02-20 Thread Florian Obser
On Sat, Feb 18, 2017 at 06:06:01PM +0100, Jeremie Courreges-Anglas wrote: > > This one is a bit weird, the driver doesn't just increment the stats but > also uses them at runtime, hence the additional helper functions. I'm wondering if we should just drop the reading. We have two cases, the init

mg(1): keep current buffer if switch-to-buffer is aborted

2017-03-11 Thread Florian Obser
For some reason I find myself quite often in the situation that I want to C-x b to a different buffer but on entering the buffer name I decide against it and C-g abort it. mg(1) then switches me to *scratch*. IMO that is the least useful thing mg(1) can do. This brings it in line with what emacs d

Re: httpd: expand HTTP Host

2017-03-13 Thread Florian Obser
On Sat, Mar 11, 2017 at 06:11:53PM +, Rivo Nurges wrote: > Hi! > > Following will add possibility to expand $HTTP_HOST to the HTTP > Host header in "block return". > > In my setup I have relayd on port 443 and httpd on 80. This patch > allows me to redirect http(httpd) to https(relayd) withou

Re: httpd: expand HTTP Host

2017-03-13 Thread Florian Obser
cter is '^]'. > GET / HTTP/1.0\r\n\r\n > > HTTP/1.0 301 Moved Permanently > Date: Mon, 13 Mar 2017 18:20:48 GMT > Server: OpenBSD httpd > Connection: close > Content-Type: text/html > Content-Length: 443 > Location: https://10.XXX/ > > Rivo > > On

Re: httpd: expand HTTP Host

2017-03-15 Thread Florian Obser
This is OK florian@ or I can commit it if someone else OKs it. On Wed, Mar 15, 2017 at 05:55:35PM +, Rivo Nurges wrote: > Hi! > > New simplified version of the patch. > > Test results: > HTTP 1.1 with Host: > HTTP/1.0 301 Moved Permanently > Location: https://testhttp.int/ > > HTTP 1.0 with

Re: log.c warn severity

2017-03-21 Thread Florian Obser
OK florian@ looks like the "dlg"-style logging in identd, slowcgi, tftp-proxy and tftpd needs some love, too :/ On Mon, Mar 20, 2017 at 10:59:29PM +0100, Alexander Bluhm wrote: > Hi, > > From a syslog perspective it does not make sense to log fatal and > warn with the same severity. I would lik

acme-client(1): move root check up

2017-03-23 Thread Florian Obser
... the parser will bomb out anyway OK? diff --git main.c main.c index dde8e8b638e..4f977451bbc 100644 --- main.c +++ main.c @@ -85,6 +85,9 @@ main(int argc, char *argv[]) goto usage; } + if (getuid() != 0) + errx(EXIT_FAILURE, "must b

acme-client(1): remove useless owner check

2017-03-23 Thread Florian Obser
Prosody starts up as _prosody so key and cert are owned by that user, which is perfectly valid. Also "current user" will always be root anyway. OK? diff --git parse.y parse.y index 1595b52a752..6ee026c2427 100644 --- parse.y +++ parse.y @@ -1034,10 +1034,6 @@ conf_check_file(char *s, int dontsta

show correct vltime/pltime when setting with ifconfig(8)

2017-04-08 Thread Florian Obser
We need to update the ia6_updatetime when changing the vltime/pltime vio ioctl(2). Otherwise ifconfig shows the wrong times since vltime/pltime are calculated from this value on export. The handling of router advertisements does the right thing. OK? p.s. I don't think this worked ever, but

Re: httpd.conf(5): sync default media types

2017-04-09 Thread Florian Obser
commited, thanks! On Sun, Apr 09, 2017 at 10:10:28AM +0200, Anton Lindqvist wrote: > Hi, > SVG was added as a default media type in revision 1.10 of http.h. > > Index: httpd.conf.5 > === > RCS file: /cvs/src/usr.sbin/httpd/httpd.conf

nsd 4.1.16

2017-04-14 Thread Florian Obser
rc1 is out, running fine here with minimal-responses: yes for some time tests/OKs? diff --git configlexer.lex configlexer.lex index 42dbd152f16..547e7db3e02 100644 --- configlexer.lex +++ configlexer.lex @@ -271,6 +271,7 @@ zonefiles-check{COLON} { LEXOUT(("v(%s) ", yytext)); return VAR_ZON

nsd(8): enable minimal-responses per default

2017-04-15 Thread Florian Obser
nsd 4.1.6 gives us minimal-responses config option and I think we should enable it in nsd.conf. >From the man page: minimal-responses: Enable minimal responses for smaller answers. This makes packets smaller. Extra data is only added for referrals, when

Re: show correct vltime/pltime when setting with ifconfig(8)

2017-04-16 Thread Florian Obser
anyone? On Sat, Apr 08, 2017 at 04:55:23PM +, Florian Obser wrote: > > We need to update the ia6_updatetime when changing the vltime/pltime > vio ioctl(2). Otherwise ifconfig shows the wrong times since > vltime/pltime are calculated from this value on export. > > The

Re: nsd 4.1.16

2017-04-24 Thread Florian Obser
On Fri, Apr 14, 2017 at 07:52:32AM +, Florian Obser wrote: > rc1 is out, running fine here with minimal-responses: yes for some time FYI: Wouter tagged 4.1.16 release this morning. No changes to RC1, so what we have in tree is 4.1.16. -- I'm not entirely sure you are real.

Re: acme-client: parsing X509V3_EXT_print output is offensive

2022-12-16 Thread Florian Obser
On 2022-12-15 20:08 +01, Theo Buehler wrote: > I would appreciate some testing by people who actually use acme-client > with multiple SANs. The diff works for me and should not change any > important behavior. > > When I learned about CVE-2021-44532 in node, I was horrified, but oh, > well, it was

units(1): support personal library

2022-12-24 Thread Florian Obser
This is at least supported by FreeBSD's units(1) as well as by systemd/Linux. With a personal library like this: $ cat ~/units.lib assload 8 stone butt2 hogshead buttload6 seams solarmass 1.98847e30 kg I can convert my mass into more convenient units: $ units -f

Re: vmctl: use a space rather than tab in usage

2022-12-30 Thread Florian Obser
That seems reasonable. This might be the full list, do you want to do all? usr.bin/htpasswd/htpasswd.c:fprintf(stderr, "usage:\t%s [file] login\n", __progname); usr.sbin/installboot/installboot.c: fprintf(stderr, "usage:\t%1$s [-nv] [-r root] disk [stage1%2$s]\n" usr.sbin/ldomctl/ldomctl

<    3   4   5   6   7   8   9   >