Date: 20 Feb 2001 00:40:48 -0000 From: peter@dataloss.net To: FreeBSD-gnats-submit@freebsd.org Subject: misc/25217: user with login 'connected' shows bogus ftpd ps output Message-ID: <20010220004048.896.qmail@massive.dataloss.net>
next in thread | raw e-mail | index | archive | help
>Number: 25217 >Category: misc >Synopsis: user with login 'connected' shows bogus ftpd ps output >Confidential: no >Severity: non-critical >Priority: low >Responsible: freebsd-bugs >State: open >Quarter: >Keywords: >Date-Required: >Class: sw-bug >Submitter-Id: current-users >Arrival-Date: Mon Feb 19 16:50:01 PST 2001 >Closed-Date: >Last-Modified: >Originator: Peter van Dijk >Release: FreeBSD 4.2-STABLE i386 >Organization: Vuurwerk Internet >Environment: FreeBSD 4.2-STABLE. >Description: If a user's loginname is 'connected', the setproctitle code in ftpd will show his login as "remote.host.name: connected". This same text is used for still-unauthenticated logins. This creates ambiguity. I ran into this problem while contemplating writing an ftpwho-like tool for FreeBSD, btw. >How-To-Repeat: - proctitle before login ftpd: minor.dataloss.net: connected (ftpd) - proctitle after user 'peter' logs in ftpd: minor.dataloss.net: peter (ftpd) - proctitle before login ftpd: minor.dataloss.net: connected (ftpd) - proctitle after user 'connected' logs in ftpd: minor.dataloss.net: connected (ftpd) >Fix: A possible fix would be changing snprintf(proctitle, sizeof(proctitle), "%s: %s", remotehost, pw->pw_name); to snprintf(proctitle, sizeof(proctitle), "%s: user[%s]", remotehost, pw->pw_name); or something similar. >Release-Note: >Audit-Trail: >Unformatted: To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-bugs" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20010220004048.896.qmail>