From owner-freebsd-questions Fri May 28 16:21:36 1999 Delivered-To: freebsd-questions@freebsd.org Received: from resnet.uoregon.edu (resnet.uoregon.edu [128.223.144.32]) by hub.freebsd.org (Postfix) with ESMTP id EC71515211 for ; Fri, 28 May 1999 16:21:34 -0700 (PDT) (envelope-from dwhite@resnet.uoregon.edu) Received: from localhost (dwhite@localhost) by resnet.uoregon.edu (8.8.8/8.8.8) with ESMTP id QAA23626; Fri, 28 May 1999 16:21:24 -0700 (PDT) (envelope-from dwhite@resnet.uoregon.edu) Date: Fri, 28 May 1999 16:21:22 -0700 (PDT) From: Doug White To: Gustavo Lozano Ibarra Cc: freebsd-questions@FreeBSD.ORG Subject: Re: checking a password when I am not root In-Reply-To: <374EEF69.CE964CEC@academ02.maz.itesm.mx> Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: owner-freebsd-questions@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG On Fri, 28 May 1999, Gustavo Lozano Ibarra wrote: > I am doing a function in C to check if the password of a user is > correct.. I use a getpwnam and then compare if the returned crypted > password is the same as the one in the db... I make this program and > then use a chmod +s, so if any user run it, it will run as root.. but I > want to make this function a library for tcl.. but when I use the > library it not run as root, so I can't see the encrypted password in the > database... is there another way to check for the password?...... Make the tcl script suid root too? You can always drop privileges once you have your password check. Doug White Internet: dwhite@resnet.uoregon.edu | FreeBSD: The Power to Serve http://gladstone.uoregon.edu/~dwhite | www.freebsd.org To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message