From owner-freebsd-threads@FreeBSD.ORG Mon Sep 19 12:41:20 2011 Return-Path: Delivered-To: freebsd-threads@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id E00AE1065675; Mon, 19 Sep 2011 12:41:20 +0000 (UTC) (envelope-from jhb@freebsd.org) Received: from cyrus.watson.org (cyrus.watson.org [65.122.17.42]) by mx1.freebsd.org (Postfix) with ESMTP id B52358FC18; Mon, 19 Sep 2011 12:41:20 +0000 (UTC) Received: from bigwig.baldwin.cx (66.111.2.69.static.nyinternet.net [66.111.2.69]) by cyrus.watson.org (Postfix) with ESMTPSA id 61E6D46B95; Mon, 19 Sep 2011 08:41:20 -0400 (EDT) Received: from jhbbsd.localnet (unknown [209.249.190.124]) by bigwig.baldwin.cx (Postfix) with ESMTPSA id E78638A03C; Mon, 19 Sep 2011 08:41:19 -0400 (EDT) From: John Baldwin To: freebsd-threads@freebsd.org Date: Mon, 19 Sep 2011 08:41:17 -0400 User-Agent: KMail/1.13.5 (FreeBSD/8.2-CBSD-20110617; KDE/4.5.5; amd64; ; ) References: <4E755D84.7080103@freebsd.org> In-Reply-To: MIME-Version: 1.0 Content-Type: Text/Plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit Message-Id: <201109190841.17780.jhb@freebsd.org> X-Greylist: Sender succeeded SMTP AUTH, not delayed by milter-greylist-4.2.6 (bigwig.baldwin.cx); Mon, 19 Sep 2011 08:41:20 -0400 (EDT) Cc: Robert Watson , Tijl Coosemans Subject: Re: thread impersonation X-BeenThere: freebsd-threads@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Threading on FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 19 Sep 2011 12:41:21 -0000 On Monday, September 19, 2011 7:50:04 am Gonzalo wrote: > What i'm trying to achieve is a program like NFS. Users will connect to this > program and navigate the virtual filesystem. Each connection is a thread, > and I need to impersonate them for the user associated to each connection, > if I use setuid, all thread in the process would be impersonated. In Linux I > achieved that using "setfsid" but that doesn't exists here in FreeBSD Yes, per-thread credentials don't exist yet. You can try asking zml@FreeBSD.org as he was planning to work on that, but I don't know if he has a patch available. rwatson@ is another good person to ask about this. -- John Baldwin