From owner-freebsd-arch@FreeBSD.ORG Wed Feb 13 23:20:11 2013 Return-Path: Delivered-To: freebsd-arch@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id EF4ED8F6; Wed, 13 Feb 2013 23:20:11 +0000 (UTC) (envelope-from kostikbel@gmail.com) Received: from kib.kiev.ua (kib.kiev.ua [IPv6:2001:470:d5e7:1::1]) by mx1.freebsd.org (Postfix) with ESMTP id 619B1736; Wed, 13 Feb 2013 23:20:11 +0000 (UTC) Received: from tom.home (kostik@localhost [127.0.0.1]) by kib.kiev.ua (8.14.6/8.14.6) with ESMTP id r1DNK4wn073237; Thu, 14 Feb 2013 01:20:04 +0200 (EET) (envelope-from kostikbel@gmail.com) DKIM-Filter: OpenDKIM Filter v2.7.4 kib.kiev.ua r1DNK4wn073237 Received: (from kostik@localhost) by tom.home (8.14.6/8.14.6/Submit) id r1DNK4L3073236; Thu, 14 Feb 2013 01:20:04 +0200 (EET) (envelope-from kostikbel@gmail.com) X-Authentication-Warning: tom.home: kostik set sender to kostikbel@gmail.com using -f Date: Thu, 14 Feb 2013 01:20:04 +0200 From: Konstantin Belousov To: Pawel Jakub Dawidek Subject: Re: bindat(2) and connectat(2) syscalls for review. Message-ID: <20130213232004.GA2522@kib.kiev.ua> References: <20130213230354.GC1375@garage.freebsd.pl> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="XVQUzBCFV/dfPXE3" Content-Disposition: inline In-Reply-To: <20130213230354.GC1375@garage.freebsd.pl> User-Agent: Mutt/1.5.21 (2010-09-15) X-Spam-Status: No, score=-2.0 required=5.0 tests=ALL_TRUSTED,BAYES_00, DKIM_ADSP_CUSTOM_MED,FREEMAIL_FROM,NML_ADSP_CUSTOM_MED autolearn=no version=3.3.2 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on tom.home Cc: freebsd-arch@FreeBSD.org X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 13 Feb 2013 23:20:12 -0000 --XVQUzBCFV/dfPXE3 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Thu, Feb 14, 2013 at 12:03:54AM +0100, Pawel Jakub Dawidek wrote: > Hi. >=20 > I'd like to commit the following patch: >=20 > http://people.freebsd.org/~pjd/patches/bindconnectat.patch >=20 > It implements bindat(2) and connectat(2) syscalls that will allow to > manage UNIX domain sockets from within capability mode sandbox. >=20 > They work just like any other *at(2) syscall and their prototypes look > like this: >=20 > int bindat(int fd, int s, const struct sockaddr *addr, socklen_t addrlen= ); > int connectat(int fd, int s, const struct sockaddr *addr, socklen_t addr= len); >=20 > Where 'fd' is directory descriptor. The only supported socket domain is > PF_LOCAL. >=20 > The audit subsystem was updated to audit the new syscalls properly. >=20 > Comments and reviews are welcome. Looking only at prototypes, I think it is useful to add at last the flags argument. The first application of it is for O_CLOEXEC-like flag. --XVQUzBCFV/dfPXE3 Content-Type: application/pgp-signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.19 (FreeBSD) iQIcBAEBAgAGBQJRHB+jAAoJEJDCuSvBvK1BcoAQAIIajsLWmMt+dD0kHPmLTvXe 8euo1+OlmQmcoIZL0INU8AShNJ4nVvMiWBithE0W3FRy+Ne/4vVaRwDaTJjev9wi upoZhZ9vAbDR1uddHcCRy4LWX2+FWUJyJsItFVds5Fnu25civc4sivag5S9GGkXe yTQ8bFCqq+UO2idjCQgrN++8xyqb8y/b/Sal7PD3hEgnCjb+GGBvUYsTTVfNaFUQ CZhluaKUGejxRrQ3Ng11EY7XREQo+hX7BBWSzr+b6elqs5UJznCi59n5gCd2Sx1g kEN+HxzofSUAxO37ZsH51pE8dB0B0hyNLj+UM4AYqJwAZ6FZfiUL36GUXAXkBi6D KtEnjg61qxczYuoElXqqTXPinnb+nVP/Ewo5aYyWBXI+WWiJTTFKsxjIuepriwtS 3dD46Gugp5c3Tw6z8XowGApYVGuJNcmM1kG6o77iXQ90xKzI4d4gYxx0lq+xskL/ hPdDwa9CGbrI6aB7VWqkNZOqtHrA4vIhgSknSUdaQbwwHU7dioabGolX4WaLgf2k QXucDs65LDD2VrFrZo1prtbIwKk0DV36KsAmgzRE3pI44M767WFDCSj4/Sli5+Y1 TtDhx43x5trcaITsT3n0UJiNMSbjgLPHT8x2kifoPPatJpwO7gz8XkiZFmW/369G YXnF987N8psOt18V5Xnj =HHhn -----END PGP SIGNATURE----- --XVQUzBCFV/dfPXE3--