|
|
|
|
| How to make Courier-IMAP log to lastlog using pam_lastlog |
|
Problem: I have a ton of accounts on my server, but I have no idea which ones are actually in active use. Courier-IMAP created two files in /etc/pam.d aptly named 'imap' and 'pop3'.
Reading the man page for pam_lastlog and trying to understand how PAM works, I have tried adding 'session required pam_lastlog.so silent' to both files. (The 'silent' keyword is used to suppress the information message typically shown when using ssh or telnet to log in)
auth required pam_nologin.so
auth required pam_stack.so service=system-auth
account required pam_stack.so service=system-auth
session required pam_stack.so service=system-auth
session required pam_lastlog.so silent
Unfortunately, the monster that is PAM refuses to cooperate.... what am I doing wrong?
|
|
Solution: Unfortunately, the current version of Courier-Auth does not seem to call pam_session_start() and pam_session_stop().
|
|
|
|
|
|
This is free technical advice without any warranties.
Use at your own risk. Solutions offered may not apply to your particular problem at all.
Opinions and views expressed in the articles are the authors' personal
and may not necessarily reflect or coincide with those of Ano-Tech Computers.
We take no responsibility if anything bad happens from following any of
the intructions given. If you don't understand and accept this, please
contact us for personal assistance instead.
To read our full disclaimer, go
here.
We welcome anyone who is willing to contribute to this public knowledge base,
contact siteadmin@atc.no
if you have information you would like to share. The idea is not to replace
the commercial support sites, but to publish those hard-to-find
solutions you've found yourself looking for over and over again.
Show all articles