From owner-freebsd-questions@FreeBSD.ORG Sat Jun 26 01:18:39 2010 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 6920F106566C for ; Sat, 26 Jun 2010 01:18:39 +0000 (UTC) (envelope-from bf1783@googlemail.com) Received: from mail-ww0-f54.google.com (mail-ww0-f54.google.com [74.125.82.54]) by mx1.freebsd.org (Postfix) with ESMTP id F28098FC1A for ; Sat, 26 Jun 2010 01:18:38 +0000 (UTC) Received: by wwb24 with SMTP id 24so3189830wwb.13 for ; Fri, 25 Jun 2010 18:18:37 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=googlemail.com; s=gamma; h=domainkey-signature:mime-version:received:received:reply-to :in-reply-to:references:date:message-id:subject:from:to:cc :content-type; bh=pahorUmki1dot7zC5JMEsb7mVi8nfmyWo4X/kjRGrNA=; b=PBGVLBgV2SrXfK4fpoUys+3NxftYRaswzWUJJPzKBj99KRMwi2cbyFZRMv5o1ONtYl 8K5m3OGdE+j/12wpQUCrZR/K2Q5oLDpRWuIM9s4erObybwKfmUT8FW+AQD7xsnoEUPHt 4Q0o6UlXdUQS7fPi9T+Abw+wlRLOweM0uUzN4= DomainKey-Signature: a=rsa-sha1; c=nofws; d=googlemail.com; s=gamma; h=mime-version:reply-to:in-reply-to:references:date:message-id :subject:from:to:cc:content-type; b=H07cUa2Wle5TMYTPbkZjnkKPN0FN3E8WyqTGozxN2KRGAv+VWuNeHPayRsVJ7BcX5W Ow52QljB2uAJ5IInvjXcXqylloQ3lqSD3HHcTnrfzivNWU5wMH5Tb96NuslAa/9dLn7d So7E+mqpTj1KHNiVb4HU5pAINYUvcrF6ZSy+o= MIME-Version: 1.0 Received: by 10.216.158.147 with SMTP id q19mr5672926wek.64.1277515117631; Fri, 25 Jun 2010 18:18:37 -0700 (PDT) Received: by 10.216.230.71 with HTTP; Fri, 25 Jun 2010 18:18:37 -0700 (PDT) In-Reply-To: References: Date: Fri, 25 Jun 2010 21:18:37 -0400 Message-ID: From: "b. f." To: Martin McCormick Content-Type: text/plain; charset=ISO-8859-1 Cc: freebsd-questions@freebsd.org Subject: Re: Running an Old Kernel X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: bf1783@gmail.com List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 26 Jun 2010 01:18:39 -0000 On 6/25/10, b. f. wrote: > On 6/25/10, b. f. wrote: >> Martin McCormick wrote: >>> I have been attempting to shut off that "last login" message >>> that occurs on some FreeBSD systems every time one runs a sudo >>> command. I decided to bring back the last kernel which was the > ... >> Why on earth are you tinkering with your kernels in order to change >> sudo output? You should instead be editing configuration files >> associated with sudo and related base system utilities, or patching >> sudo. > > I should be more specific: I think you should be able to disable the > message by commenting out the lines that refer to pam_lastlog.so in > /etc/pam.d/system, /etc/pam.d/xdm, and /etc/pam.d/telnetd. But in > doing so, you will lose some of the security and accounting benefits > of last(1) and friends. Is it really worth it, just to silence some > console messages? In any event, don't tinker with your kernel because > of this. It won't help, and it may break your system. Looking at Matthew Seaman's earlier response, I find that his suggestion to make changes to ${PREFIX}/etc/pam.d/sudo is more appropriate than my guess above. But you probably need to look into the details, because judging from the comments in the ${PREFIX}/etc/pam.d/sudo.default file, there seems to be some subtleties involving sudo and pam_lastlog. Look at the pertinent manpages, the sudo docs, and: http://www.freebsd.org/doc/en/articles/pam/index.html b.