Pluggable Authentication Modules handle authentication tasks of applications or services running on the system.

learn more… | top users | synonyms

2
votes
2answers
55 views

Allow SSH access but restrict root's access to a given set of IPs

I want to allow SSH for all users as normal except that I want to restrict root's access based on a set of IP addresses. So, users peter, paul, lary can login from anywhere, but root may login only ...
0
votes
1answer
17 views

persisting multi-factor user data for custom pam authentication in CentOS 7

I am designing n-factor authentication for CentOS 7 using a custom PAM module. When the user tries to SSH, they will be texted a pin code, and be prompted to enter the pin. Where should I store the ...
3
votes
2answers
45 views

How to stop sudo PAM messages in auth.log for a specific user?

I am using Zabbix for monitoring my environment and zabbix_agentd executes as user zabbix one custom script every 60 seconds; it uses sudo to run this script as root. In /var/log/auth.log I see every ...
8
votes
1answer
104 views

How to add additional steps to login?

What I would like to achieve is an interactive program that runs either before or after asking the user for the password, but won't handle over the access to the computer unless it exited with ...
1
vote
0answers
22 views

Can't setup mount of EncFS on user login

I've tried to setup EncFS to be mounted on user login as described in this guide excluding the Password Utility section, however it works with little success. The EncFS works properly ...
2
votes
1answer
46 views

How can I use different kerberos principals for sudo than for system-auth?

At my organization, we're required to use different kerberos principals when authenticating for sudo than for other types of auth, such as logging in. For instance, my regular (login) principal might ...
2
votes
1answer
33 views

Replacement for php5-auth-pam to authenticate website login against local users

I am working on a login for a PHP-based website where users should be successfully logged in if they enter a valid username and password for a local account on the system. Looking around, it seems ...
2
votes
1answer
67 views

How do you get `pam_succeed_if.so` to recognize `service` user?

I have a Linux system with a user named service. I'm using the pam_succeed_if.so module to match this username. For example: auth required pam_succeed_if.so user = service But it won't ...
1
vote
1answer
41 views

Why root is not constrained by pam

I have the following settings in file /etc/pam.d/common-password. password requisite pam_cracklib.so retry=3 lcredit=-1 ucredit=-1 dcredit=-1 password [success=1 ...
1
vote
0answers
33 views

ConsoleKit reports active/is-local only on the second+ login

Running KDE Frameworks 5, Plasma 5, using sddm as a display manager. ConsoleKit and PAM-linux are both installed. Upon login (using the sddm login screen), ck-list-sessions returns FALSE for both ...
3
votes
0answers
77 views

What SELinux context shall the script have to be ran by pam_exec?

I just installed Fedora 22 on my VPS and tried to make trivial thing -- run my informer script on every ssh login via pam_exec. But I was confronted with unexpected difficulties: pam_exec failed with ...
1
vote
1answer
93 views

What is pam_unix2 / why doesn't it exist on some distributions?

Some documentations, blogs and forums and other examples on the web use pam_unix2 in /etc/pam.d/ configurations. An example taken from pam_winbind manpage: auth required pam_env.so auth ...
2
votes
1answer
61 views

Use multiple PAM login methods at once?

I'm using pam-fprintd as a login method. Currently it works perfectly for logging into the cinnamon screensaver and sudo. Unfortunately you have to fail the fingerprint login a certain number of times ...
0
votes
1answer
95 views

Disable PAM login but keeping landscape-sysinfo y motd

Running Ubuntu Server, I have no need for PAM login, and thus disabled this service in the sshd_config file. However, oddly, there is some login info that is only displayed if you enable PAM logins ...
0
votes
1answer
97 views

PAM timestamp - how to inspecting the /var/run/sudo/<user> file?

The centos documentation stated that: ... In the PAM timestamp scheme, the graphical administrative application prompts the user for the root password when it is launched. When the user has ...
0
votes
0answers
165 views

lightdm: (pam_mount.c:477): warning: could not obtain password interactively either

Ubuntu 14.04 does not mount folders, libpam-pkcs11 with ldap mapper $ sudo tail -f /var/log/auth.log May 7 12:58:06 my-company-ub14 lightdm: pam_unix(lightdm-greeter:session): session closed for ...
0
votes
1answer
148 views

what does pam_env.so really do?

Having the following line: auth required pam_env.so Documentation happily says "This module is required—it must run successfully for authentication to proceed." ...
1
vote
1answer
481 views

CUPS not working correctly after Debian Wheezy -> Jessie upgrade because of a faulty libpam

I just upgraded a Debian Wheezy to Jessie, by changing the /etc/apt/sources.lst. If important: I pinned systemd to stay with sysvinit, and after the upgrade I removed the pin. If I now do apt-get ...
2
votes
0answers
184 views

Force OpenSSH / pam / pam_ldapd to do pam_ldapd(sshd:auth) with public-key authentication

I have working pam_ldap authentication using libpam_ldapd. I'm using slapo-nssov and want to use loginStatus attribute which is added to users ldap entry after opening pam session and deleted when its ...
1
vote
1answer
120 views

Password policy on existing accounts not updated after making changes to login.defs

I have two old accounts that were previously set to defaults (no password expiration). I updated login.defs and /etc/pam.d/system-auth for stricter password policy. New accounts added to the system ...
2
votes
2answers
115 views

check “newness” / “is-read” of /var/spool/mail/$USER like pam_mail for custom motd script

How can I check with bash or python (preferred) if there are some unread mails in /var/spool/mail/$USER like pam_mail does? I'd like to use this for my own custom motd script, motd.dynamic
1
vote
0answers
82 views

Using pam_listfile.so with radius authentication

I have set up radius authentication on my machine (as a client - untested yet). The pam radius conf file has the shared secret etc. The radius authentication can potentially authenticate every single ...
1
vote
1answer
31 views

common-account line read order

My authentication is centralized in a LDAP. I've one login system who is working without any ldap so it's present in my /etc/passwd file. This my common-account file in pam.d directory. account ...
1
vote
0answers
50 views

PAM and fprintd

Occasionally I get an error on the login screen of Ubuntu 14.04 under unity. The problem occurs after waking up from suspend after closing the lid. Essentially instead of asking me first for ...
2
votes
1answer
192 views

dyanamically creating directories with pam_mkhomedir and mysql for vsftpd

I'm a Linux noob, so hopefully someone will be able to help me to get this up and running. I've installed vsftpd using the following instructions ...
0
votes
2answers
150 views

Setting up a script on an AMI box to create directories - vsftpd, pam, mysql

I'd like to first say I'm a noob when it comes to linux, so please excuse my confusion. I'm trying to setup vsftpd on a amazon ami 64 bit box, free tier micro. Following these instructions, ...
1
vote
2answers
423 views

Unable to determine your tty name on Debian Wheezy on ARM

while trying to create my Debian Wheezy image for a FriendlyARM mini210s ARM single board computer, I am bumping into this issue. I have opened a terminal via serial sudo screen /dev/cu.usbserial ...
6
votes
1answer
318 views

When running 'su - username', pam_group doesn't add additional groups from /etc/security/group.conf but sshd login does?

I am having trouble determining why su doesn't behave as the PAM configuration would imply. In short, using su to become another user should load secondary groups according to PAM configuration, but ...
0
votes
1answer
121 views

useradd PAM authentication failed

I needed to customize useradd command so i downloaded shadow-utils source package. Using configure-make i was able to compile the source , binary was generated (configure prefix) at custom location ...
1
vote
0answers
303 views

removing `nullok` from system-auth prevents any root password

[ this is a follow-up on my post on ServerFault : http://serverfault.com/questions/661136/root-accepts-any-password-how-to-change-to-a-real-password ] On an old system the root account accepts any ...
2
votes
0answers
204 views

Debian ignores PAM env variables (while Arch doesn't)

I have a weird issue with my Debian Sid system. I want to set a global environment variable in /etc/environment, which is supposed to be read by the pam_env module. Unfortunately, after having relogin ...
2
votes
2answers
306 views

Warn about password expiration without forcing change

It's pretty simple. I would like to figure out what combination of changes in /etc/login.defs and/or /etc/pam.d/system-auth-ac I would need to perform to allow the following behavior: I want a ...
0
votes
1answer
304 views

Password fail delay is too long - Linux Mint 17

As per the title, the delay after a failed password is very long. In /etc/pam.d/login, FAIL_DELAY is configured as auth optional pam_faildelay.so delay=3000000 however, actual delay is ...
1
vote
0answers
89 views

Configure pam_mount to prompt for password

I have configured my Ubuntu system to mount a cifs share using pam_mount and a credentials file (the credentials to access the cifs share are different to those I use on my Linux machine). I'd like to ...
1
vote
0answers
257 views

With pam_script, how do I pass PAM_AUTHTOK and PAM_USER in all cases?

I need to run a script whenever a user enters a password; the script should be able to reject that password, but shouldn't be sufficient. I placed the script in /etc/pamunlockscript/pam_script_auth ...
2
votes
0answers
116 views

Is there way to print the entered password in PAM?

We are using CentOS 6.5. We have a perl script for our automation testing. One of the script login to the user as non-root user and test "su -" command. This test case passes most of the times but ...
12
votes
2answers
4k views

How do I force a user to change a password at the first time login using ssh?

I'm trying to force a newly created user to change a password at the first time login using ssh. For security reasons I want to give him a secure password until he logs in for the first time. I did ...
0
votes
1answer
142 views

Can't get OpenLDAP and Pam LDAP working at all

Yesterday, I set up an OpenLDAP server and tried to configure it to be useful for SSH. Followed these two guides from DigitalOcean: ...
4
votes
1answer
145 views

Why libpam-systemd run interactively on apt upgrade, even when specified force-confdef/force-confold

I upgrade my packages using aptitude, specifying the apt options --force-confdef and --force-confold. This generally works, but the package libpam-systemd (204-5ubuntu20.8, on Ubuntu 14.04) still ...
2
votes
1answer
161 views

What's the correct way to authenticate a user without PAM?

as my related question doesn't seem to get much love, here another one: What's the proper way to authenticate a user via username/password prompt in Linux nowadays? In principle, I suppose I would ...
1
vote
1answer
438 views

Can't Login to Debian 7.7 with Kerberos/NIS user

I have a Debian 7.7 system I am trying to configure to use Kerberos and NIS, both served from an Active Directory server. I have kerberos set up such that I can kinit a set of credentials from the AD ...
1
vote
1answer
192 views

basic explanation on NSS , LDAP and PAM

can anyone give me a basic explanation on what are NSS , LDAP and PAM and what they used for and what is their relationship/differences ?
6
votes
1answer
534 views

First sudo always slow

The first sudo I enter on my Ubuntu 14.04 server is always slow. The password prompt displays immediately, but after I press enter it takes about 10-15 seconds until the output is printed. All sudo ...
0
votes
0answers
777 views

While trying to ssh, pam_ldap always sends the password “INCORRECT” causing bind to fail

I installed ldap-auth-client nscd ldap-utils on lubuntu 14.04 running on a banana pi. I can successfully bind as the user using ldapwhoami, but I cannot log in via ssh: Auth.log: Oct 21 02:12:05 ...
2
votes
0answers
50 views

Integrate my own PAM module with the passwd command

I know that to integrate my module with the passwd command all I need to do is add the following line to the /etc/pam.d/passwd file: password sufficient mymodule.so My question is I want my module ...
2
votes
1answer
52 views

Externally authenticate user within PAM session/PAM session within PAM session

Is there a way of properly authenticating a user from within a custom PAM session? I am currently writing my own PAM authentication module which allows the user to login via an external token. This ...
1
vote
1answer
359 views

How to disallow usage of an LDAP root account

I am responsible for a couple of servers at my university. All of these machines are configured to talk to the LDAP server of my departement to allow centralised user logins. On this LDAP server there ...
2
votes
1answer
3k views

Expired password and SSH key based login with UsePAM yes

There is a SLES 11 machine. The users logs in via SSH and pubkey (mixed, some user uses password, some use ssh key) The sshd_config has: UsePAM yes PasswordAuthentication yes PubkeyAuthentication ...
1
vote
0answers
214 views

gksu -S ask for password only once even when set to three times in sudo configuration

I have a problem with gksu command. It always ask for password only once even when I set Defaults passwd_tries=3 in /etc/sudoers file. Command: $ gksu -S --debug ls No ask_pass set, using default! ...
0
votes
0answers
137 views

How to fix Module is Unknown error without logging in (PiLFS)

I've built a PiLFS distribution and was running it fine about a month ago. Now, when I turn on the Raspberry pi and attempt to login as root with the proper password, it gives the error Module is ...