Bug 31204

Summary: FreeBSD login will display secure log notices before password is given
Product: Base System Reporter: David Ljung Madison <FreeBSD.org>
Component: miscAssignee: freebsd-bugs (Nobody) <bugs>
Status: Closed FIXED    
Severity: Affects Only Me    
Priority: Normal    
Version: Unspecified   
Hardware: Any   
OS: Any   

Description David Ljung Madison 2001-10-10 20:10:01 UTC
First of all, I should point out that I don't actually run FreeBSD as
my unix flavor, I was working on a friend's machine. If you try to login as root, you can see security warnings that only
root should see before you ever enter your password. An obvious exploit would be to login to the machine, enter "root" at
the login prompt, then sit back and watch security messages, which could
be very useful to an attacker to learn about what kind of security the
system has implemented

Fix: 

Dunno - don't have a FreeBSD system.  Presumably the login exec is doing a
setuid before it actually verifies the password?
How-To-Repeat: Make a bad attempt to login to some account (use the wrong password).  Then
try to login as root - you will see the "bad login" message after you enter
the "login:" prompt but before you type a password.
Comment 1 dwmalone 2001-10-10 21:10:40 UTC
On Wed, Oct 10, 2001 at 12:05:36PM -0700, David Ljung Madison wrote:
> I was working on a friend's machine. If you try to login as root, you can see security warnings that only
> root should see before you ever enter your password. An obvious exploit would be to login to the machine, enter "root" at
> the login prompt, then sit back and watch security messages, which could
> be very useful to an attacker to learn about what kind of security the
> system has implemented

Are you sure you weren't seeing these messages because you were
logging on to the system console? The default syslog.conf logs a
selection of messages to the console, including the one for attempted
root logins. Some of the more sensitive messages shouldn't logged to
the console.

If you weren't logging in at the console, were you using telnet,
ssh or another method to log in?

	David.
Comment 2 Crist J. Clark freebsd_committer freebsd_triage 2001-10-13 02:51:34 UTC
State Changed
From-To: open->feedback

If these login attempts were at the console, this is 
understandable. How syslogd(8) logs to the console is configurable and 
this is not a bug but just a default configuration choice. However, if 
this was _not_ at the console, we need more information. There may 
be a problem.
Comment 3 Crist J. Clark freebsd_committer freebsd_triage 2001-12-17 10:58:35 UTC
State Changed
From-To: feedback->closed

Feedback timeout, over 2 months.