LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Security
User Name
Password
Linux - Security This forum is for all security related questions.
Questions, tips, system compromises, firewalls, etc. are all included here.

Notices


Reply
  Search this Thread
Old 06-06-2012, 04:04 AM   #1
grail
LQ Guru
 
Registered: Sep 2009
Location: Perth
Distribution: Manjaro
Posts: 10,007

Rep: Reputation: 3191Reputation: 3191Reputation: 3191Reputation: 3191Reputation: 3191Reputation: 3191Reputation: 3191Reputation: 3191Reputation: 3191Reputation: 3191Reputation: 3191
shadow and linux-pam issues


So after almost a day of banging my head on the wall, I come seeking help

On my CLFS based system I recently re-compiled both linux-pam and shadow.
The compilations went without a hitch, until I tried to compile my next program.

It seems I have blown away my ability to su, or for that matter, login at the command prompt

When as root I try to su to a user I receive:
Code:
# su user
su: Error in service module
Now all of my searching has pointed to the fact that I may have a dodgy /etc/pam.d script.

As for logging in at a new tty, the system allows me to enter the user name and password, but then reverts back to the login prompt again.
I can only guess this is a similar issue as I can see no error messages.

I will attach all of my /etc/pam.d scripts to see if anyone can spot an issue, but below are the 3 (I presume) main culprits:
Code:
#
#	The PAM configuration file for system authentication
#

auth		required	pam_env.so
auth		sufficient	pam_unix.so try_first_pass nullok
auth		required	pam_deny.so

account		required	pam_unix.so

password	required	pam_cracklib.so difok=2 minlen=8 dcredit=2 ocredit=2 retry=3
password	sufficient	pam_unix.so try_first_pass use_authtok nullok md5 shadow
password	required	pam_deny.so

session		required	pam_limits.so
session		required	pam_unix.so

#
#   The common PAM configuration file for login
#
auth        required    pam_shells.so
auth        include     system-auth
auth        optional    pam_securetty.so

account     required    pam_nologin.so
account     include     system-auth

password    include     system-auth

session     include     system-auth
session     required    pam_mkhomedir.so skel=/etc/skel/ umask=0022
session     optional    pam_lastlog.so nowtmp
session     optional    pam_mail.so dir=/var/mail standard

#
#   The common PAM configuration file for su
#
auth        sufficient  pam_rootok.so
auth        include     system-auth

account     include     system-auth

password    include     system-auth

session     include     system-auth
session     optional    pam_xauth.so
Any help or a nudge in the right direction would be appreciated
Please also advise if any other information will help?

I have been reluctant to restart the system as not sure if I will be able to login at all??
Attached Files
File Type: txt pam.d.tar.bz2.txt (1.1 KB, 9 views)
 
Old 06-06-2012, 05:32 AM   #2
grail
LQ Guru
 
Registered: Sep 2009
Location: Perth
Distribution: Manjaro
Posts: 10,007

Original Poster
Rep: Reputation: 3191Reputation: 3191Reputation: 3191Reputation: 3191Reputation: 3191Reputation: 3191Reputation: 3191Reputation: 3191Reputation: 3191Reputation: 3191Reputation: 3191
hmmm ... well unfortunately I have no idea why this is SOLVED, but after walking away for a while and then coming back and recompiling both ... all is fixed???

Sorry this won't be much help to anyone else who may get this issue
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] Unix-chkpwd problem with Linux-PAM-1.1-1 trying to run su from shadow-4.1.4.2 hoes Linux - Security 4 04-07-2016 03:25 AM
[SOLVED] Cannot log in after installing shadow/PAM TKH Linux From Scratch 6 08-21-2011 03:21 AM
/etc/shadow + pam.d configs -- Do they hate each other? ddxC Red Hat 2 09-18-2009 01:31 AM
PAM/shadow question: How do I force the password to be changed? clacour Linux - Security 1 03-25-2004 01:31 AM
postfix + smtpauth + pam/shadow dazk Debian 0 07-30-2003 10:41 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Security

All times are GMT -5. The time now is 06:45 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration