From: Daniel Berger Date: 2007-07-23T12:51:29+09:00 Subject: Re: Using expect.rb to change a user's password in UNIX On Jul 22, 6:15 pm, "Victor Reyes" wrote: > Hello World, > > Today, I used a Korn Shell script and the UNIX version of expect to change a > user password remotely. > I would like to use the ruby.rb library to do the same. > For instance, when you type, in UNIX, > > passwd username > It comes back asking to enter the PW. > Once you enter it, it comes back asking you to enter it again. > > How do I do this using the ruby expect.rb library? I just went through this. You can use net-telnet (or net-ssh). See: http://groups.google.com/group/ruby-talk-google/browse_frm/thread/96cabb08c34182c/77c0843d27e95dd3?lnk=gst&q=berger+password&rnum=1#77c0843d27e95dd3 Regards, Dan