From owner-freebsd-isp@FreeBSD.ORG Fri Jun 18 13:43:41 2004 Return-Path: Delivered-To: freebsd-isp@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 8896716A4CE for ; Fri, 18 Jun 2004 13:43:41 +0000 (GMT) Received: from sianna.shopkeeper.de (sianna.shopkeeper.de [217.17.196.5]) by mx1.FreeBSD.org (Postfix) with ESMTP id 5AA8B43D54 for ; Fri, 18 Jun 2004 13:43:40 +0000 (GMT) (envelope-from sklauder@trimind.de) Received: from avalon.dobu.local (p5090B8F5.dip.t-dialin.net [80.144.184.245]) (authenticated bits=128) by sianna.shopkeeper.de (8.12.9/8.12.6) with ESMTP id i5IDh9nT019664; Fri, 18 Jun 2004 15:43:10 +0200 (CEST) (envelope-from sklauder@trimind.de) Received: from avalon.dobu.local (localhost.dobu.local [127.0.0.1]) by avalon.dobu.local (8.12.10/8.12.5) with ESMTP id i5IDgpAr057047; Fri, 18 Jun 2004 15:42:56 +0200 (CEST) (envelope-from sklauder@avalon.dobu.local) Received: (from sklauder@localhost) by avalon.dobu.local (8.12.10/8.12.10/Submit) id i5IDgpEd057046; Fri, 18 Jun 2004 15:42:51 +0200 (CEST) (envelope-from sklauder) Date: Fri, 18 Jun 2004 15:42:51 +0200 From: Sascha Klauder To: Andrew Nelson Message-ID: <20040618134251.GA56959@trimind.de> References: Mime-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: User-Agent: Mutt/1.4.1i cc: freebsd-isp@freebsd.org Subject: Re: monitoring shell commands (recording username/cmd/time) X-BeenThere: freebsd-isp@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Internet Services Providers List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 18 Jun 2004 13:43:41 -0000 On Fri, Jun 18, 2004 at 01:22:50PM +1000, Andrew Nelson wrote: > I'm wondering if there is a version of bash or tcsh that logs all commands > to a file with username and time? I've tried Sudo, but it's not all that > practical for my purpose (I'm not that interested in restricting access, Leaving the security considerations aside (a user can just compile his own shell, use another etc), you could use the bash-bofh-patch (http://www.ccitt5.net/archives/) >From the README: »What this patch does is basically to log commands run from bash to syslog under the USER facility...« I've used it myself some time ago on a shell server and it works pretty well. Cheers, -sascha