Bug 449197 - pam_mount fails to unmount encrypted home on log off with GDM
Summary: pam_mount fails to unmount encrypted home on log off with GDM
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Fedora
Classification: Fedora
Component: pam_mount
Version: 9
Hardware: All
OS: Linux
low
low
Target Milestone: ---
Assignee: Till Maas
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2008-05-31 05:08 UTC by Yousif Al Saif
Modified: 2008-11-02 11:34 UTC (History)
2 users (show)

Fixed In Version: pam_mount-0.49-1.fc9
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2008-11-02 11:34:36 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)
relevant /log/var/secure messages (6.25 KB, text/plain)
2008-05-31 05:08 UTC, Yousif Al Saif
no flags Details
relevant /log/var/messages messages (5.14 KB, text/plain)
2008-05-31 05:09 UTC, Yousif Al Saif
no flags Details

Description Yousif Al Saif 2008-05-31 05:08:30 UTC
Description of problem:


pam_mount fails to unmount and unmap the encrypted home directory partitions
when logging off using GDM. I Tried logging off using the shell/ssh and
pam_mount succeeded so it is probably an issue related to the combination of GDM
and pam_mount.


How reproducible:


Steps to Reproduce:
1. Follow steps to encrypt home directory partition and attach pam_mount
(from http://tredosoft.com/encrypt_home_directory_fedora_9)
2. log in with the user owning an encrypted home partition using GDM
3. log off immediately
4. As root you can still access the encrypted home directory
  
Actual results:
pam_mount fails to unmount the encrypted home directory and unmap the encrypted
device.

Expected results:
pam_mount (forces?) unmounting the encrypted home directory and unmaps the
encrypted partition


Additional info:


SELinux is currently in permissive mode . Luks is used for encrypting the home
directory. 

On very rare occasions, manually unmounting the encrypted device shows a "device
busy" error. lsof returns with an \n !


Workaround:


as root unmount the encrypted partition after logging off by

umount /home/guest1 && cryptsetup luksClose _dev_sdc3

If a "device busy" error was encountered unmount by

umount -l /home/guest1 && cryptsetup luksClose _dev_sdc3

Comment 1 Yousif Al Saif 2008-05-31 05:08:30 UTC
Created attachment 307263 [details]
relevant /log/var/secure messages

Comment 2 Yousif Al Saif 2008-05-31 05:09:35 UTC
Created attachment 307264 [details]
relevant /log/var/messages messages

Comment 3 Jan Engelhardt 2008-10-17 16:06:53 UTC
Blame GDM for not having made sure that its subprograms have terminated before calling umount. This does not just concern GDM (but predominantly Gnome and KDE), it actually applies to all programs running in the background and which are not a strict child of <your login program of preference, be it getty,gdm,kdm...> in the process hierarchy.

You can use pam_mount >= 0.44 to force killing processes that block unmounting.

Comment 4 Till Maas 2008-11-02 11:34:36 UTC
pam_mount 0.49 is available for Fedora 9, so you should not have any problems anymore. In case you still have, please leave a comment.


Note You need to log in before you can comment on or make changes to this bug.