From owner-freebsd-security Thu Oct 4 3:23:29 2001 Delivered-To: freebsd-security@freebsd.org Received: from whale.sunbay.crimea.ua (whale.sunbay.crimea.ua [212.110.138.65]) by hub.freebsd.org (Postfix) with ESMTP id 6344437B403 for ; Thu, 4 Oct 2001 03:23:20 -0700 (PDT) Received: (from ru@localhost) by whale.sunbay.crimea.ua (8.11.6/8.11.2) id f94AMjh53219; Thu, 4 Oct 2001 13:22:45 +0300 (EEST) (envelope-from ru) Date: Thu, 4 Oct 2001 13:22:45 +0300 From: Ruslan Ermilov To: Bill.Melvin@esc.edu Cc: freebsd-security@FreeBSD.ORG Subject: Re: odd sockstat output Message-ID: <20011004132245.B48758@sunbay.com> References: Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.2.5i In-Reply-To: ; from Bill.Melvin@esc.edu on Wed, Oct 03, 2001 at 05:04:40PM -0400 Sender: owner-freebsd-security@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.org On Wed, Oct 03, 2001 at 05:04:40PM -0400, Bill.Melvin@esc.edu wrote: > > Why would sockstat show me something like this: > > USER COMMAND PID FD PROTO LOCAL ADDRESS FOREIGN ADDRESS > root sshd 4580 5 tcp4 192.168.120.1:22 192.168.120.2:38 > root sshd 155 4 tcp4 *:22 *:* > root syslogd 129 5 udp4 *:514 *:* > root syslogd 129 18 ? ? ? > > Line with the ?s. > Same PID but different FD. I did another sockstat > right away but it was gone. > sockstat(1) is not atomical. It calls netstat(1) first, then fstat(1). Most probably, syslogd(8) closed the FD in between. Cheers, -- Ruslan Ermilov Oracle Developer/DBA, ru@sunbay.com Sunbay Software AG, ru@FreeBSD.org FreeBSD committer, +380.652.512.251 Simferopol, Ukraine http://www.FreeBSD.org The Power To Serve http://www.oracle.com Enabling The Information Age To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-security" in the body of the message