[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]

Weird problem with pam_pwdb (but not pam_unix_*) in KDE: advice needed!



Hi, 

I am trying to fix PAM support in the KDE display manager
(kdm).  (I am not the maintainer)
If you have any ideas, please let me know
(even if you are on the other side of the gnome vs KDE polemic!)


kdm is based on xdm from an older XFree86, hacked a bit supposedly to
make it "64 bit clean", so its not immediately possible to upgrade it
to the latest xdm.

Its been  crashing X (with an "Unknown session" message from WaitForChild() )
because of 3 PAM problems. I've fixed 2 of them, but the last one has me beat.
The 2 I fixed were due to broken session support, but I saw that in xdm from
XFree86-3.3.1, the author of xdm has given up on session support, and now
closes the pam handle with pam_end(pamh,PAM_SUCCESS) after a successful login
in verify.c.  Doing this in kdm, and stripping out the PAM stuff
(pam_open_session, etc) from session.c cured two of the kdm problems.


The remaining problem is when an INCORRECT pasword is given by the 
pam_conversation function to pam_authenticate  (in verify.c), and 
pam_end(pamh,0)
gets called to clean things up and close the pam handle before the next
attempt to login.

pam_end() calls the libpam function _pam_free_data in pam_data.c, which
may call *cleanup() depending on which module was used.


If pam_pwdb is used, *cleanup gets called, but does not return, and X crashes.
But with what seems to be functionally identical code (as far as PAM is
concerned), xdm from the RedHat 5.0 rpms, calls *cleanup and returns just fine.

Does anyone have any guess as to how this might be happening, where to look,
etc?.  I couldnt yet identify what actually happens after *cleanup is
called, because the true name of the cleanup function is (i think) hidden
in the data stored in the pam handle pamh.

The workaround is that if pam_unix_auth is used for authentication,
cleanup() never gets called, and kdm works.  The PAM is 0.59 (RedHat5.0).
But I'd like to get the pwdb module working.

Could this be a pam bug? (but then how come the RedHat xdm works fine, it
must be a kdm bug?)  Both call pam_end(pamh,0).
All suggestions welcome!
duncan.








----------------------------------
E-Mail: f.d.m.haldane@MCI2000.com
Date: 07-Mar-98
Time: 00:45:09

This message was sent by XFMail
----------------------------------



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index] []