Is there a standard module library function to access /etc/passwd or /etc/group

Robin Cull robin.cull at pace.co.uk
Wed Jul 30 18:58:38 EDT 2003


Heather Coppersmith <me at privacy.net> wrote in message news:<m2vftkw5um.fsf at host200-null.null.bellsouth.net>...
> On 30 Jul 2003 05:16:43 -0700,
> robin.cull at pace.co.uk (Robin Cull) wrote:
> 
> > ...  Something that gives access to the C standard libarary
> > functions get[pw|group]ent(), for example ...
> 
> Right out of the table of contents of Python's Library Reference:
> 
>     8.2 pwd -- The password database
>     8.3 grp -- The group database

Those'll be the ones! :)

> 
> When all else fails, read the manual....  ;-)

I assure you I did, in fact it baffles me that I missed "pwd" in the
global module index when I was scanning for "passwd".  Then I went off
on a complete tangent and started looking through "os" and "posix" for
some reason.  A case of "can't see the wood for the trees" I think!

I'll look harder next time ;)

Cheers, 

Robin




More information about the Python-list mailing list