Path: utzoo!utgpu!news-server.csri.toronto.edu!rpi!zaphod.mps.ohio-state.edu!cis.ohio-state.edu!tut.cis.ohio-state.edu!ucbvax!agate!darkstar!saturn.ucsc.edu!hugo From: hugo@saturn.ucsc.edu (Hugo Calendar) Newsgroups: comp.unix.aix Subject: Re: How can I set passwords from script/file? Message-ID: <15770@darkstar.ucsc.edu> Date: 14 May 91 13:18:47 GMT References: <1991May13.155155.258@vax1.cc.lehigh.edu> Sender: usenet@darkstar.ucsc.edu Organization: University of California, Santa Cruz Lines: 12 In article <1991May13.155155.258@vax1.cc.lehigh.edu> lusgr@vax1.cc.lehigh.edu (Steve Roseman) writes: >Does anyone have a good way of setting user passwords from a file, script, >etc.? Running "passwd username message. I need this capability for administrative mass password setting, and >changing the user interface for passwd (not my idea.) You could try writing some C code to alter the /etc/passwd file, or use some C in conjunction with awk or something. Use the "crypt()" function to generate password encryptions, (see man crypt). If you don't get my drift, mail me, and I'll send you something workable. Hugo