Bug 167200
| Summary: | finger reports "never logged in" if run as non-root | ||
|---|---|---|---|
| Product: | [Fedora] Fedora | Reporter: | Wayne Pollock <pollock> |
| Component: | finger | Assignee: | Radek Vokál <rvokal> |
| Status: | CLOSED ERRATA | QA Contact: | Mike McLean <mikem> |
| Severity: | medium | Docs Contact: | |
| Priority: | medium | ||
| Version: | 4 | CC: | kzak, notting |
| Target Milestone: | --- | ||
| Target Release: | --- | ||
| Hardware: | i686 | ||
| OS: | Linux | ||
| Whiteboard: | |||
| Fixed In Version: | Doc Type: | Bug Fix | |
| Doc Text: | Story Points: | --- | |
| Clone Of: | Environment: | ||
| Last Closed: | 2005-09-07 01:38:03 UTC | Type: | --- |
| Regression: | --- | Mount Type: | --- |
| Documentation: | --- | CRM: | |
| Verified Versions: | Category: | --- | |
| oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |
| Cloudforms Team: | --- | Target Upstream Version: | |
| Embargoed: | |||
|
Description
Wayne Pollock
2005-08-31 14:53:59 UTC
Finger gets information about last login from /var/log/lastlog which is not user readable. That's why user can't see any information. On the other hand, `last` uses /var/log/wtmp which is word readable. I'm not quite sure why the permissions on these two files differ. Not only are the permissions wrong (since at least FC2), but the file is
never rotated! Like wtmp it isn't owned by any package, although this is
interesting:
# rpm -qf /var/log/lastlog
setup-2.5.33-1
shadow-utils-4.0.3-55
# rpm -qf /var/log/wtmp
initscripts-7.55.2-1
I have made the following fixes, I suggest they be adopted:
(1) chmod a+r /var/log/lastlog
(2) Added the following to the end of /etc/logrotate.conf:
/var/log/lastlog {
size 10M
create 0644 root root
}
(3) Fix the finger man page to show this file in the FILES section, and add the
"lastlog" command to the "SEE ALSO" section.
lastlog shouldn't be rotated! It's not a log file as such. ??? Then what stops this file from growing to fill the disk? wtmp isn't a log file either, but it does get rotated, so I figure what's good enough for wtmp should be good enough for lastlog! And, did you notice it appears to be "owned" by two different packages? I meant to suggest fixing that too, as (4). lastlog will never grow beyond a fixed size, which is relative to the highest user id on the system. (And, it's a sparse file, so it normally doesn't take up significant space anyway. From User-Agent: XML-RPC util-linux-2.12p-9.9 setup-2.5.44-1.1 has been pushed for FC4, which should resolve this issue. If these problems are still present in this version, then please make note of it in this bug report. |