Path: utzoo!utgpu!news-server.csri.toronto.edu!bonnie.concordia.ca!thunder.mcrcim.mcgill.edu!snorkelwacker.mit.edu!bloom-picayune.mit.edu!athena.mit.edu!jik From: jik@athena.mit.edu (Jonathan I. Kamens) Newsgroups: comp.unix.admin Subject: Re: Changing passwords in Scripts Keywords: Passowrds Message-ID: <1991Feb19.201534.28396@athena.mit.edu> Date: 19 Feb 91 20:15:34 GMT References: <39@cheops.UUCP> Sender: news@athena.mit.edu (News system) Organization: Massachusetts Institute of Technology Lines: 15 In article <39@cheops.UUCP>, logier@cheops.UUCP (Rob Logie) writes: |> RE: Changing passwords from within a shell/c program Get Dan Bernstein's "pty" package (available from the comp.sources.unix archive in volume 23). Then, you can run "pty passwd" instead of just "passwd" and pipe the username and password into it. I suspect you can also do this with Don Libes' "expect" program (available in /pub/expect.shar.Z on uunet.uu.net, and in other locations as well). -- Jonathan Kamens USnail: MIT Project Athena 11 Ashford Terrace jik@Athena.MIT.EDU Allston, MA 02134 Office: 617-253-8085 Home: 617-782-0710