From owner-freebsd-hackers Tue May 8 7:53:26 2001 Delivered-To: freebsd-hackers@freebsd.org Received: from smtp10.atl.mindspring.net (smtp10.atl.mindspring.net [207.69.200.246]) by hub.freebsd.org (Postfix) with ESMTP id 266CB37B423 for ; Tue, 8 May 2001 07:53:21 -0700 (PDT) (envelope-from tlambert2@mindspring.com) Received: from mindspring.com (pool0302.cvx21-bradley.dialup.earthlink.net [209.179.193.47]) by smtp10.atl.mindspring.net (8.9.3/8.8.5) with ESMTP id KAA14934; Tue, 8 May 2001 10:53:16 -0400 (EDT) Message-ID: <3AF80870.39A8705B@mindspring.com> Date: Tue, 08 May 2001 07:53:36 -0700 From: Terry Lambert Reply-To: tlambert2@mindspring.com X-Mailer: Mozilla 4.7 [en]C-CCK-MCD {Sony} (Win98; U) X-Accept-Language: en MIME-Version: 1.0 To: Alfred Perlstein Cc: Dima Dorfman , hackers@FreeBSD.ORG Subject: Re: Getting peer credentials on a unix domain socket References: <20010504230540.00BEE3E0B@bazooka.unixfreak.org> <20010504170738.U18676@fw.wintelcom.net> Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG Alfred Perlstein wrote: > Someone had some patches for a getpeercreds() syscall, but I wasn't > happy with it considering we already have the sendmsg() stuff to pass > credentials along with the fact that the initial creator of a socket > may be long gone before it's used to connect to something. The credentials (ucred) persist; that's actually part of the problems I was having a while ago with 30,000+ open files (if they didn't, I'd have had 65,000+ open files before I saw any problems, and the reasons would have been much more obviously a bit count boundary problem, instead of a bug hunt). I think adding a new system call is _not_ the way to go; there are perfectly good fcntl() commands, which fail to work under FreeBSD, but work just fine under Solaris, SunOS, Linux, and most other UNIX systems (we are back to "struct fileops" being major suckage here). -- Terry To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message