Subject: Re: increasing UT_HOSTSIZE for IPv6?
To: None <,>
From: Bill Sommerfeld <>
List: tech-userlevel
Date: 07/26/1999 07:05:03
I'll weigh in here since revving utmp is one of the last things left
to finish long user-name support.  

As others have stated, utmpx is just utmp with bigger field lengths.
This is the Wrong Answer.

Something closer to the right answer involves defining a new API for
reading utmp/wtmp, and revving the existing utmp-updating API
(-lutil's login/logout/logwtmp) to keep the old files up to date so we
don't really need a "/dev/utmp" to hallucinate the old file.  

There's existing prior art for this (there's the getut*/putut* calls
in solaris), but unfortunately they just use the existing "struct utmp"
with its fixed-length fields.

If I were building something from scratch:

 - for network logins, both the hostname and the sockaddr should be
logged, since the address<->host binding varies over time, and logging
the client port number and, for V6, the interface index is also

 - I'd use db for the utmp and lastlog replacement (utmp keyed by
"line", while lastlog keyed by either uid or login name), and a plain
text file for the wtmp replacement.

 - I'd probably also extend lastlog to record unsuccessful login info
as well.

					- Bill