From owner-freebsd-hackers@freebsd.org Tue Oct 16 18:29:57 2018 Return-Path: Delivered-To: freebsd-hackers@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 731A110DD085 for ; Tue, 16 Oct 2018 18:29:57 +0000 (UTC) (envelope-from bzeeb-lists@lists.zabbadoz.net) Received: from mx1.sbone.de (mx1.sbone.de [IPv6:2a01:4f8:13b:39f::9f:25]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "mx1.sbone.de", Issuer "SBone.DE" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 0F2547947A; Tue, 16 Oct 2018 18:29:56 +0000 (UTC) (envelope-from bzeeb-lists@lists.zabbadoz.net) Received: from mail.sbone.de (mail.sbone.de [IPv6:fde9:577b:c1a9:31::2013:587]) (using TLSv1 with cipher ADH-CAMELLIA256-SHA (256/256 bits)) (No client certificate requested) by mx1.sbone.de (Postfix) with ESMTPS id 351C58D4A12D; Tue, 16 Oct 2018 18:29:54 +0000 (UTC) Received: from content-filter.sbone.de (content-filter.sbone.de [IPv6:fde9:577b:c1a9:31::2013:2742]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by mail.sbone.de (Postfix) with ESMTPS id E0B76D1F83F; Tue, 16 Oct 2018 18:29:53 +0000 (UTC) X-Virus-Scanned: amavisd-new at sbone.de Received: from mail.sbone.de ([IPv6:fde9:577b:c1a9:31::2013:587]) by content-filter.sbone.de (content-filter.sbone.de [fde9:577b:c1a9:31::2013:2742]) (amavisd-new, port 10024) with ESMTP id WH_VTR52GXzt; Tue, 16 Oct 2018 18:29:51 +0000 (UTC) Received: from [10.248.106.11] (fresh-ayiya.sbone.de [IPv6:fde9:577b:c1a9:f001::2]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (No client certificate requested) by mail.sbone.de (Postfix) with ESMTPSA id 26900D1F835; Tue, 16 Oct 2018 18:29:50 +0000 (UTC) From: "Bjoern A. Zeeb" To: "Mark Johnston" Cc: freebsd-hackers@freebsd.org Subject: Re: [CFT] capsicum patches for rtsol(8) and rtsold(8) Date: Tue, 16 Oct 2018 18:29:49 +0000 X-Mailer: MailMate (2.0BETAr6123) Message-ID: <86D87437-BD34-489A-87B7-33F1089080EE@lists.zabbadoz.net> In-Reply-To: <20181016165308.GB5066@raichu> References: <20181015194212.GA2751@spy> <20181016165308.GB5066@raichu> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 8bit X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.27 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 16 Oct 2018 18:29:57 -0000 On 16 Oct 2018, at 16:53, Mark Johnston wrote: > On Tue, Oct 16, 2018 at 04:06:43PM +0000, Bjoern A. Zeeb wrote: >> On 15 Oct 2018, at 19:42, Mark Johnston wrote: >> >>> https://people.freebsd.org/~markj/patches/rtsold_capsicum.diff >> >> (0) the git rename doesn’t really work when applying the diff with >> FreeBSD’s patch so the mv has to be done manually >> >> (1) the rtsol Makefile also needs cap_syslog and util to link to >> otherwise rtsold.c has unresolved symbols >> >> (2) rtsol seem to have worked when manually invoked; >> /etc/resolv.conf >> was created (I had rm’ed it) and the 3 nameserver lines >> re-appeared; >> sorry can’t test the search string here >> >> (3) rtsold crashes: > > Thanks. I made some last-minute changes and forgot to retest, of > course. :( > > I uploaded a new patch which should fix all of these issues - could > you > give it a try? With the old and new patch: root@i386-a3-carp:/usr/src/sbin/rtsol # rtsol vtnet0 failed to run script: Invalid argument Hadn’t noticed that before. Also on a running system: root@i386-a3-carp:/ # rm /etc/resolv.conf root@i386-a3-carp:/ # cat /etc/resolv.conf cat: /etc/resolv.conf: No such file or directory root@i386-a3-carp:/ # sh /etc/rc.d/rtsold restart Stopping rtsold. Waiting for PIDS: 1047. Starting rtsold. root@i386-a3-carp:/ # cat /etc/resolv.conf cat: /etc/resolv.conf: No such file or directory After a reboot: root@i386-a3-carp:~ # ps ax | grep rts 372 - SCs 0:00.01 /usr/sbin/rtsold -a 375 - Ss 0:00.01 rtsold: system.syslog (rtsold) 376 - S 0:00.00 rtsold: rtsold.script (rtsold) 693 u0 R+ 0:00.01 grep rts root@i386-a3-carp:~ # cat /etc/resolv.conf # Generated by resolvconf nameserver .. root@i386-a3-carp:~ # rtsol vtnet0 failed to run script: Invalid argument root@i386-a3-carp:~ # sh /etc/rc.d/rtsold restart Stopping rtsold. Waiting for PIDS: 372. Starting rtsold. Oct 16 18:28:33 i386-a3-carp rtsold[734]: failed to run script: Invalid argument /bz