From owner-freebsd-ports@FreeBSD.ORG Mon Apr 28 16:32:45 2008 Return-Path: Delivered-To: freebsd-ports@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id A461E1065673 for ; Mon, 28 Apr 2008 16:32:45 +0000 (UTC) (envelope-from brooks@lor.one-eyed-alien.net) Received: from lor.one-eyed-alien.net (cl-162.ewr-01.us.sixxs.net [IPv6:2001:4830:1200:a1::2]) by mx1.freebsd.org (Postfix) with ESMTP id 27C688FC13 for ; Mon, 28 Apr 2008 16:32:45 +0000 (UTC) (envelope-from brooks@lor.one-eyed-alien.net) Received: from lor.one-eyed-alien.net (localhost [127.0.0.1]) by lor.one-eyed-alien.net (8.14.2/8.14.2) with ESMTP id m3SGWutX041571; Mon, 28 Apr 2008 11:32:56 -0500 (CDT) (envelope-from brooks@lor.one-eyed-alien.net) Received: (from brooks@localhost) by lor.one-eyed-alien.net (8.14.2/8.14.2/Submit) id m3SGWtUB041570; Mon, 28 Apr 2008 11:32:55 -0500 (CDT) (envelope-from brooks) Date: Mon, 28 Apr 2008 11:32:55 -0500 From: Brooks Davis To: Walter Venable Message-ID: <20080428163255.GC40940@lor.one-eyed-alien.net> References: <48132E31.8080204@gmail.com> <4814346A.5040207@infracaninophile.co.uk> <4815FB00.1010702@gmail.com> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="5G06lTa6Jq83wMTw" Content-Disposition: inline In-Reply-To: <4815FB00.1010702@gmail.com> User-Agent: Mutt/1.5.17 (2007-11-01) X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-3.0 (lor.one-eyed-alien.net [127.0.0.1]); Mon, 28 Apr 2008 11:32:56 -0500 (CDT) Cc: freebsd-ports@freebsd.org Subject: Re: Building new port, don't want to run as root X-BeenThere: freebsd-ports@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Porting software to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 28 Apr 2008 16:32:45 -0000 --5G06lTa6Jq83wMTw Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Mon, Apr 28, 2008 at 07:27:44PM +0300, Walter Venable wrote: > Matthew Seaman wrote: >> I take it you're talking about a daemon process and you want to have the >> rc.subr scripts start it as another user than root? That's fairly simpl= e. >>=20 >> To make rc.subr start a process using a different UserID, all you need to >> do is define variables >>=20 >> name =3D foo <-- standard rc script thing to >> setup the namespace >> foo_user =3D someone >> foo_group =3D somegroup > Ok, silly question, but I looked around again and hit another brick wall = --=20 > how do I make the port add a user that doesn't already exist? http://www.freebsd.org/doc/en_US.ISO8859-1/books/porters-handbook/dads-uid-= and-gids.html -- Brooks --5G06lTa6Jq83wMTw Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.8 (FreeBSD) iD8DBQFIFfw2XY6L6fI4GtQRAvGyAJ0YBgqj7VKUcMnc3RrVFvr62Ns8YQCeMUM3 +8wVfeURN+ijcxGYdhFeVQU= =PaVD -----END PGP SIGNATURE----- --5G06lTa6Jq83wMTw--