From: "Matías López Bergero" <mlopezb@udesa.edu.ar>
To: Laurent CARON <lcaron@apartia.fr>
Cc: "Adrian C." <drupix@gmail.com>, linux-admin@vger.kernel.org
Subject: Re: can't get lastlogin info wen loging in trough ssh
Date: Fri, 29 Oct 2004 15:47:56 -0300 [thread overview]
Message-ID: <4182905C.8070703@udesa.edu.ar> (raw)
In-Reply-To: <41824F67.9060700@apartia.fr>
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
Hello,
Finally I solved the problem.
This is my /etc/pam.d/sshd file:
#%PAM-1.0
auth required pam_stack.so service=system-auth
auth required pam_nologin.so
account required pam_stack.so service=system-auth
password required pam_stack.so service=system-auth
session required pam_stack.so service=system-auth
session required pam_limits.so
session optional pam_console.so
session optional /lib/security/pam_lastlog.so
I was reading a little bit about pam, and find out that there is a debug
flag to set on a pam module.
So, i set the module pam_lastlog to debug like this:
session optional /lib/security/pam_lastlog.so debug
I add the following line to my syslog.conf to capture all the
authentication procedures:
auth.* /var/log/authlog
And guess what find the the /var/log/atuhlog file???
PAM-lastlog[5890]: unable to open /var/log/lastlog file
Damn...
Problem solved. I chmod to 644 that file.
The option LASTLOG_ENAB in /etc/login.def it's not required to display
the lastlog message.
Many thanks to all for the help!
BR,
Matías
Laurent CARON wrote:
| Matías López Bergero wrote:
|
|> -----BEGIN PGP SIGNED MESSAGE-----
|> Hash: SHA1
|>
|> Adrian C. wrote:
|> | See /etc//login.defs
|> |
|> | LASTLOG_ENAB yes
|
|
| /etc/pam.d/ssh
|
| #%PAM-1.0
| auth required pam_nologin.so
| auth required pam_unix.so
| auth required pam_env.so # [1]
|
| account required pam_unix.so
|
| session required pam_unix.so
| session optional pam_lastlog.so # [1]
| session optional pam_motd.so # [1]
| session optional pam_mail.so standard noenv # [1]
| session required pam_limits.so
|
| password required pam_unix.so
|
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.0.7 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org
iD8DBQFBgpBcRB0HKLRQp/gRAsTRAKC7jzOXkT9xhYQcirC1aJavFWZGrACfXZfL
dT/05ljBoy7TpO9dNLHjUEU=
=h/8P
-----END PGP SIGNATURE-----
-
To unsubscribe from this list: send the line "unsubscribe linux-admin" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
prev parent reply other threads:[~2004-10-29 18:47 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2004-08-31 15:34 can't get lastlogin info wen loging in trough ssh Matías López Bergero
2004-08-31 17:25 ` Laurent CARON
2004-08-31 19:59 ` Matías López Bergero
2004-08-31 20:14 ` Laurent CARON
2004-09-01 16:26 ` Matías López Bergero
2004-10-28 20:55 ` Matías López Bergero
2004-10-28 21:02 ` Adrian C.
2004-10-29 14:05 ` Matías López Bergero
2004-10-29 14:10 ` Laurent CARON
2004-10-29 18:47 ` Matías López Bergero [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=4182905C.8070703@udesa.edu.ar \
--to=mlopezb@udesa.edu.ar \
--cc=drupix@gmail.com \
--cc=lcaron@apartia.fr \
--cc=linux-admin@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).