From owner-freebsd-questions@FreeBSD.ORG Sun Oct 30 04:57:17 2005 Return-Path: X-Original-To: freebsd-questions@freebsd.org Delivered-To: freebsd-questions@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 02ACF16A41F for ; Sun, 30 Oct 2005 04:57:17 +0000 (GMT) (envelope-from paulh@bdug.org.au) Received: from mail.bdug.org.au (mail.bdug.org.au [202.72.170.31]) by mx1.FreeBSD.org (Postfix) with ESMTP id C449443D48 for ; Sun, 30 Oct 2005 04:57:15 +0000 (GMT) (envelope-from paulh@bdug.org.au) Received: from localhost (localhost.bdug.org.au [127.0.0.1]) by mail.bdug.org.au (Postfix) with ESMTP id 054C54D for ; Sun, 30 Oct 2005 12:57:13 +0800 (WST) Received: from mail.bdug.org.au ([127.0.0.1]) by localhost (ant.bdug.org.au [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 24055-10 for ; Sun, 30 Oct 2005 12:57:09 +0800 (WST) Received: from w2k2 (unknown [192.168.0.102]) by mail.bdug.org.au (Postfix) with ESMTP id 87EB122 for ; Sun, 30 Oct 2005 12:57:09 +0800 (WST) From: "Paul Hamilton" To: Date: Sun, 30 Oct 2005 12:57:34 +0800 Message-ID: <027a01c5dd0e$70cfbbb0$6600a8c0@w2k2> MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable X-Priority: 3 (Normal) X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook, Build 10.0.6626 Importance: Normal X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1506 X-Virus-Scanned: amavisd-new at bdug.org.au Subject: RE: Enumerating a Windows based PC from a FreeBSD based server - Resolved X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 30 Oct 2005 04:57:17 -0000 Hi, OK, after a lot more searching of the ports system - nothing found so = far. Something joggled a neuron to have a look at what samba utils could tell = me. By running: "nmblookup -A " it quickly returns a = nice list of info. All I need to do then is grep for '<03>' and exclude the = PC name to have a list of users logged into that PC or Server. I have only done hand testing. I will whip up a script, and test it out during a work day to see how it goes ;-) Cool. Cheers, Paul Hamilton > -----Original Message----- > From: owner-freebsd-questions@freebsd.org > [mailto:owner-freebsd-questions@freebsd.org] On Behalf Of=20 > Paul Hamilton > Sent: Sunday, 30 October 2005 9:28 AM > To: freebsd-questions@freebsd.org > Subject: Enumerating a Windows based PC from a FreeBSD based server >=20 >=20 > Hi, >=20 > I am trying to document which managed switch port (HP 4000m), > a users PC is plugged into. I had thought to use a login=20 > script to dump some info into a MySQL DB, but I am now=20 > leaning on scanning the switch, and build up the data=20 > backwards from there. The info will all end up on a PHP=20 > searchable web page. I should then be able to track admin=20 > logins (does anyone know the passwd?), have some users given=20 > their username and passwd to someone else to use? Etc. >=20 > I have found the SNMP OID's of the IP and MAC addresses and > the switch port number the computer is plugged into. From a=20 > DNS lookup, I can find the PC name, but how do I find out the=20 > current logged in user name on the PC, remotely from a FreeBSD server? >=20 > The GFI LanGuard network scanner is a very informative tool: > http://www.gfi.com/lannetscan/ so having something similar=20 > to this on a FreeBSD server would be great. The utility must=20 > of course be scriptable. >=20 >=20 > Cheers, >=20 > Paul >=20 > _______________________________________________ > freebsd-questions@freebsd.org mailing list > http://lists.freebsd.org/mailman/listinfo/freebsd-questions > To unsubscribe, send any mail to=20 > "freebsd-questions-unsubscribe@freebsd.org" >=20 >=20