I'm using pam_mount to automount some windows shares whenever a user logs in.
I'm using winbind with "winbind use default domain = true", so users can log in using "user" as user name (in addition to "DOMAIN\user"). However, getgrent returns only "DOMAIN\user" as member names in gr_mem.
The attached patch, which I'm using successfully, adds another method to determine user group membership in user_in_sgrp. Namely, it uses getgrouplist to enumerate the groups a user belongs to. This is the same method id(1) uses to list groups.
Log in to post a comment.