From owner-freebsd-questions@FreeBSD.ORG Sat Feb 18 23:04:30 2006 Return-Path: X-Original-To: freebsd-questions@freebsd.org Delivered-To: freebsd-questions@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 6EF8416A420 for ; Sat, 18 Feb 2006 23:04:30 +0000 (GMT) (envelope-from divs_83@yahoo.com) Received: from web31009.mail.mud.yahoo.com (web31009.mail.mud.yahoo.com [68.142.200.172]) by mx1.FreeBSD.org (Postfix) with SMTP id ED91D43D45 for ; Sat, 18 Feb 2006 23:04:29 +0000 (GMT) (envelope-from divs_83@yahoo.com) Received: (qmail 153 invoked by uid 60001); 18 Feb 2006 23:04:29 -0000 DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=s1024; d=yahoo.com; h=Message-ID:Received:Date:From:Subject:To:MIME-Version:Content-Type:Content-Transfer-Encoding; b=XN7i7ueNM/8ikeT6PCJsnViwSKu9GcQ1zdhWTrM8WW/3Csfow9ssvYr00CRaEr2PLNIfUR6JwsjN4VG3t6igRZnyMwi87QG/4wYJ9ZoDglBQt5cwnAUxipydZ70OTDBWZrkh7YkTFNV5y1lzRv76qqLtCZeMIvDW/h0oQc7QLvw= ; Message-ID: <20060218230429.151.qmail@web31009.mail.mud.yahoo.com> Received: from [69.162.203.163] by web31009.mail.mud.yahoo.com via HTTP; Sat, 18 Feb 2006 15:04:29 PST Date: Sat, 18 Feb 2006 15:04:29 -0800 (PST) From: divyesh shah To: freebsd-questions@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: 8bit Subject: reg a process's ruid and euid X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 18 Feb 2006 23:04:30 -0000 I have a system call which should kill all processes for a given uid. Now, I am confused about which uid to use(real or effecctive) of the processes when killing them. Example scenario: userids A, B, C A is super-user(root) so using my system call he can kill processes of any other user. Also, user C is running a process with ruid C but euid B(giving him possibly higher privilege). Now if A calls my system call asking to kill all processes of uid B, should my system call also kill the process started by C but running as B. Thanks, Divyesh Shah. __________________________________________________ Do You Yahoo!? Tired of spam? Yahoo! Mail has the best spam protection around http://mail.yahoo.com