Pam-list Digest, Vol 34, Issue 4

Andreas Schindler schindler at az1.de
Wed Dec 13 07:30:34 UTC 2006


pam-list-request at redhat.com wrote:
> 
> Subject:
> Dropping privs by PAM modules.
> From:
> s_n <jusnet at vp.pl>
> Date:
> Mon, 11 Dec 2006 19:34:14 +0100
> To:
> pam-list at redhat.com
> 
> To:
> pam-list at redhat.com
> 
> 
> Hi,
> 
> I'm just wondering about dropping privilages by pam modules, does it
> make sense to you anyway? How to consider such behaviour, improved
> security or is it just security by obscurity? Anyway, imagine badly
> coded module, which can be circumvented by an attacker and used to
> launch his own code. Will dropping privs mitigate the possible loses
> coused by such malicious code? What are you thinking about it?
> 
> Sincerly,
> Filip (s_n) Palian.
> 
> 

Filip,

IMHO i's good use to drop privileges when you don't need them, just to protect
you against your own coding-quirks. You can regain privileges at any time if
the need arises up to the user's base privilege level. To equip PAM modules
with root privileges there is no other way but using a helper process which
is made SUID. This construct is used by a few PAM modules, namely pam_unix to
cope with shadow password authentication.

Regards, Andreas




More information about the Pam-list mailing list