Linux and UNIX Man Pages

Linux & Unix Commands - Search Man Pages

pam_localuser(8) [linux man page]

PAM_LOCALUSER(8)						 Linux-PAM Manual						  PAM_LOCALUSER(8)

NAME
pam_localuser - require users to be listed in /etc/passwd SYNOPSIS
pam_localuser.so [debug] [file=/path/passwd] DESCRIPTION
pam_localuser is a PAM module to help implementing site-wide login policies, where they typically include a subset of the network's users and a few accounts that are local to a particular workstation. Using pam_localuser and pam_wheel or pam_listfile is an effective way to restrict access to either local users and/or a subset of the network's users. This could also be implemented using pam_listfile.so and a very short awk script invoked by cron, but it's common enough to have been separated out. OPTIONS
debug Print debug information. file=/path/passwd Use a file other than /etc/passwd. MODULE TYPES PROVIDED
All module types (account, auth, password and session) are provided. RETURN VALUES
PAM_SUCCESS The new localuser was set successfully. PAM_SERVICE_ERR No username was given. PAM_USER_UNKNOWN User not known. EXAMPLES
Add the following line to /etc/pam.d/su to allow only local users in group wheel to use su. account sufficient pam_localuser.so account required pam_wheel.so FILES
/etc/passwd Local user account information. SEE ALSO
pam.conf(5), pam.d(5), pam(7) AUTHOR
pam_localuser was written by Nalin Dahyabhai <nalin@redhat.com>. Linux-PAM Manual 06/04/2011 PAM_LOCALUSER(8)

Check Out this Related Man Page

PAM_LOCALUSER(8)						 Linux-PAM Manual						  PAM_LOCALUSER(8)

NAME
pam_localuser - require users to be listed in /etc/passwd SYNOPSIS
pam_localuser.so [debug] [file=/path/passwd] DESCRIPTION
pam_localuser is a PAM module to help implementing site-wide login policies, where they typically include a subset of the network's users and a few accounts that are local to a particular workstation. Using pam_localuser and pam_wheel or pam_listfile is an effective way to restrict access to either local users and/or a subset of the network's users. This could also be implemented using pam_listfile.so and a very short awk script invoked by cron, but it's common enough to have been separated out. OPTIONS
debug Print debug information. file=/path/passwd Use a file other than /etc/passwd. MODULE TYPES PROVIDED
All module types (account, auth, password and session) are provided. RETURN VALUES
PAM_SUCCESS The new localuser was set successfully. PAM_SERVICE_ERR No username was given. PAM_USER_UNKNOWN User not known. EXAMPLES
Add the following line to /etc/pam.d/su to allow only local users in group wheel to use su. account sufficient pam_localuser.so account required pam_wheel.so FILES
/etc/passwd Local user account information. SEE ALSO
pam.conf(5), pam.d(5), pam(7) AUTHOR
pam_localuser was written by Nalin Dahyabhai <nalin@redhat.com>. Linux-PAM Manual 06/04/2011 PAM_LOCALUSER(8)
Man Page

15 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

Filtering text from a string

I'm trying to write a script which prints out the users who are loged in. Printing the output of the "users" command isn't the problem. What I want is to filter out my own username. users | grep -v (username) does not work because the whole line in which username exists is suppressed. If... (5 Replies)
Discussion started by: Cozmic
5 Replies

2. Shell Programming and Scripting

append 3 users in /etc/passwd

I am looking to add 3 lines in /etc/passwd via a script. Can you please give me an idea on how to write a script that can do that? (3 Replies)
Discussion started by: melanie_pfefer
3 Replies

3. Shell Programming and Scripting

Script for updating the comments field on /etc/passwd on redhat linux

Hi there, I have more that 300 servers that I need to updated the comments field on /etc/passwd for users that have a blank comments fields. The users have accounts on different servers. I have created a list of these users on a text file called update_passwd.txt. I need a script that will... (6 Replies)
Discussion started by: Linux Duke
6 Replies

4. UNIX for Dummies Questions & Answers

Which command will be faster? y?

i)wc -c/etc/passwd|awk'{print $1}' ii)ls -al/etc/passwd|awk'{print $5}' (4 Replies)
Discussion started by: karthi_g
4 Replies

5. Shell Programming and Scripting

Number of users in passwd

This command prints out username/users in /etc/passwd: cut -d ':' -f '1,5' /etc/passwd | sort I wonder if I also, after above commands output, can get an output that lists number of users in the group? I need to use uniq to get rid of duplicates. I´ve tried this, but cant get it right, can... (5 Replies)
Discussion started by: oskis
5 Replies

6. AIX

User creation

hi seniors i want to create the users like when the user try to login it should not should not promt for passwd is it possible to create users like this please help me (6 Replies)
Discussion started by: senmak
6 Replies

7. UNIX for Dummies Questions & Answers

Add new User in Unix ?!

Hello Experts, Guide me how to add new users (user id , passwd) in unix/Linux with different privileges like --> 1> It can be accessible by telnet (or where i should check/change to give different privileges like telnet or ssh2 or FTP) 2> can run only 1 command / script (2 Replies)
Discussion started by: darshak
2 Replies

8. Shell Programming and Scripting

A couple issues

Hello, I have a couple questions. First of all, I'm trying to use the wc command on the /etc/passwd file to find out the total amount of users but I am unsuccesful. I figured since users each have their own line in the passwd file that i could have it count the number of lines and then return the... (1 Reply)
Discussion started by: Simonpalmieri
1 Replies

9. UNIX for Dummies Questions & Answers

Local User

How to fetch only local user without duplication from /etc/passwd using scripting?? (4 Replies)
Discussion started by: AhmedLakadkutta
4 Replies

10. Solaris

pam sshd error

Hi I wanted to convert my pam libraries to 64 bit. so recently compiled my pam_banner and pam_wheel to 64 bit. I got the following error... sshd: dlsym failed pam_sm_authenticate:error ld.so.1 : sshd fatal: pam_sm_authenticate: can't find symbol thnaks (8 Replies)
Discussion started by: chinchao
8 Replies

11. Cybersecurity

LDAP and PAM Configurations for Windows 2008 R2 ADS and Cubox Ubuntu client

Please I am having problem to login using Windows 2008 R2 Active Directory Services accounts on a cubox ubuntu (2.6.32.9-dove-5.4.2 #46). "getent passwd" only shows local users, however I can querry ADS users using ldapsearch command. I have 2 systems, one that does not use gdm can login with all... (1 Reply)
Discussion started by: powelltallen
1 Replies

12. Shell Programming and Scripting

awk - printing the passwd file

I've got a number of RHEL systems and I'm trying to use awk to read and format the output of /etc/passwd. But I'd like to display the host name of the system at the beginning of each line of output. I've got it working without the adding the host name in this script: #!/bin/bash ... (3 Replies)
Discussion started by: westmoreland
3 Replies

13. Web Development

Botnet Victims Map

Our site is currently "under abuse" from a botnet which is directing a small subset of internet users (not forum users) to a rarely used full page advertising URL and attempting to redirect the user, via that URL to other web sites. This is a kind of "spam" botnet; using a URL redirection... (16 Replies)
Discussion started by: Neo
16 Replies

14. Ubuntu

Users Access - AD Authentication - User can't log in?

I have a user who's having troubles logging into one of my servers, that is authenticating with AD. After glancing over /etc/passwd, I found the users account is different than mine and others who aren't having any issues. What's the difference between these two accounts? What's the "1 60 14 60" ?... (1 Reply)
Discussion started by: Nvizn
1 Replies

15. UNIX for Beginners Questions & Answers

How to identify users that have su'ed to a different account?

Hello and thanks in advance for anyone that can offer me any help with this! I'm trying to figure out a quick & easy way to see a list of everyone's effective user id... I would have thought 'w' or 'who' would be able to display if someone had switched user accounts... but it's only showing the... (3 Replies)
Discussion started by: bodisha
3 Replies