From owner-cvs-all@FreeBSD.ORG Sun Aug 24 15:45:31 2008 Return-Path: Delivered-To: cvs-all@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 669031065673; Sun, 24 Aug 2008 15:45:31 +0000 (UTC) (envelope-from rwatson@FreeBSD.org) Received: from cyrus.watson.org (cyrus.watson.org [209.31.154.42]) by mx1.freebsd.org (Postfix) with ESMTP id 298C88FC0A; Sun, 24 Aug 2008 15:45:30 +0000 (UTC) (envelope-from rwatson@FreeBSD.org) Received: from fledge.watson.org (fledge.watson.org [209.31.154.41]) by cyrus.watson.org (Postfix) with ESMTP id 42EEF46B2E; Sun, 24 Aug 2008 11:45:30 -0400 (EDT) Date: Sun, 24 Aug 2008 16:45:30 +0100 (BST) From: Robert Watson X-X-Sender: robert@fledge.watson.org To: Ed Schouten In-Reply-To: <200808241006.m7OA6IbU072333@repoman.freebsd.org> Message-ID: References: <200808241006.m7OA6IbU072333@repoman.freebsd.org> User-Agent: Alpine 1.10 (BSF 962 2008-03-14) MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII; format=flowed Cc: cvs-src@FreeBSD.org, src-committers@FreeBSD.org, cvs-all@FreeBSD.org Subject: Re: cvs commit: src ObsoleteFiles.inc src/libexec Makefile src/libexec/pt_chown Makefile pt_chown.c X-BeenThere: cvs-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: CVS commit messages for the entire tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 24 Aug 2008 15:45:31 -0000 On Sun, 24 Aug 2008, Ed Schouten wrote: > Remove the now unneeded pt_chown utility. > > Before we had a posix_openpt() that allocated PTY's with proper > permissions in place, we used this set-uid utility to change the > ownership of PTY slave devices to the real user ID of the process. This > utility was used to implement grantpt(). > > In my first designs of the MPSAFE TTY layer, I replaced this by adding > an ioctl() called TIOCGRANTPT, which was used to change the ownership. > I left the pt_chown utility, because older C libraries needed it to work > properly. > > After some discussions back in June I changed the PTY code to set > permissions properly upon creation. Fortunately the previous grantpt() > implementation changed permissions by hand when pt_chown is not > installed, which always succeeds. This means grantpt() still works > properly, even though the set-uid utility is missing. > > I've done tests with FreeBSD 5.2.1, FreeBSD 6.3 and FreeBSD 7.0 jails. > All of them still work if I remove pt_chown. I know, another e-mail from me about compatibility -- run away! Do you plan to provide updated compat libs for 4.x, 5.x, 6.x, 7.x, to replace libc/libutil code that expects to be able to execute the pt_chown binary? What happens if that code can't find the pt_chown binary it expects? Robert N M Watson Computer Laboratory University of Cambridge