OpenSSH and PAM

Posted on 2005-04-15
Last Modified: 2013-12-16

Im trying to auth myself over ssh via PAM against an OpenLDAP server! I have added myself in the ldapserver, started up the ldap_cachemgr on my solaris 10 machine and it find my user with getent passwd. Next i have added to my pam.conf the following lines

sshd    auth requisite
sshd    auth required 
sshd    auth sufficient
sshd    auth required  try_first_pass

I run OpenSSH3.9 compiled with --with-pam=yes flag. My sshd_conf contains the line UsePam=Yes. I turn on debug-mode 1 and tries to ssh in to the server. This is what I get from sshd.log (somewhat stripped)

debug1: PAM: initializing for "test"
PAM: setting PAM_RHOST to "clienthost"
PAM: setting PAM_TTY to "ssh"
Failed none for test from clientip port 50784 ssh2
PAM: num PAM env strin gs 0
Accepted keyboard-interactive/pam for linus from clientip port 50784 ssh2
monitor_child_preauth:  test has been authenticated by privileged process
debug1: PAM: reinitializing credentials
[ID 800047 local6.crit]fatal: PAM: pam_setcred(): Failure setting user credentials

So it do authenticate me, but it dies on the pam_setcred().

Go any idea why? How to fix?


Question by:mannie
    LVL 38

    Accepted Solution

    Please have a look at the following doc and fix it:
    LVL 38

    Expert Comment

    You can also download openssh binary package from:
    The binary with PAM support, make sure that you install all the dependencies packages,
    read the details on the download page.

    Featured Post

    IT, Stop Being Called Into Every Meeting

    Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

    Join & Write a Comment

    When you do backups in the Solaris Operating System, the file system must be inactive. Otherwise, the output may be inconsistent. A file system is inactive when it's unmounted or it's write-locked by the operating system. Although the fssnap utility…
    In tuning file systems on the Solaris Operating System, changing some parameters of a file system usually destroys the data on it. For instance, changing the cache segment block size in the volume of a T3 requires that you delete the existing volu…
    Learn how to get help with Linux/Unix bash shell commands. Use help to read help documents for built in bash shell commands.: Use man to interface with the online reference manuals for shell commands.: Use man to search man pages for unknown command…
    Learn how to find files with the shell using the find and locate commands. Use locate to find a needle in a haystack.: With locate, check if the file still exists.: Use find to get the actual location of the file.:

    729 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    21 Experts available now in Live!

    Get 1:1 Help Now