From owner-freebsd-hackers@FreeBSD.ORG Fri Jun 17 16:47:54 2005 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 9571916A41C for ; Fri, 17 Jun 2005 16:47:54 +0000 (GMT) (envelope-from joseph.koshy@gmail.com) Received: from rproxy.gmail.com (rproxy.gmail.com [64.233.170.205]) by mx1.FreeBSD.org (Postfix) with ESMTP id 57EB643D1D for ; Fri, 17 Jun 2005 16:47:54 +0000 (GMT) (envelope-from joseph.koshy@gmail.com) Received: by rproxy.gmail.com with SMTP id i8so816247rne for ; Fri, 17 Jun 2005 09:47:53 -0700 (PDT) DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=beta; d=gmail.com; h=received:message-id:date:from:reply-to:to:subject:cc:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references; b=i/9yYxymenij+IdR3NTviNcH4pDpypNTci511ApCOm1CLwGUPXO+HJ46EgotRgrMy+GfOJjJ6r/Z98XLZrMdP0yS2C4kPbQSdsSvfTjsei9gNaQqKXjMONFF0p1Sd42BjN4wqwcaUePFKl5vVlbcfgUjGh/m2yEFINUf9N5cGn4= Received: by 10.38.88.14 with SMTP id l14mr1165097rnb; Fri, 17 Jun 2005 09:47:53 -0700 (PDT) Received: by 10.38.209.73 with HTTP; Fri, 17 Jun 2005 09:47:53 -0700 (PDT) Message-ID: <84dead72050617094731ff2b46@mail.gmail.com> Date: Fri, 17 Jun 2005 22:17:53 +0530 From: Joseph Koshy To: Aziz Kezzou In-Reply-To: <3727392705061709318b9346f@mail.gmail.com> Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Content-Disposition: inline References: <3727392705061709318b9346f@mail.gmail.com> Cc: freebsd-hackers@freebsd.org Subject: Re: How to check root powers on a struct proc ? X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: Joseph Koshy List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 17 Jun 2005 16:47:54 -0000 > I am trying to check that a process (struct proc) has root=20 > powers when it calls my KLD system call. Don't you get a 'struct thread *' as an argument to your system call entry point? The 'flag' argument to suser_cred(9) is documented in its manual page. --=20 FreeBSD Volunteer, http://people.freebsd.org/~jkoshy