You can use the 'passwd' command, but you'll need to interact with it. To do that, you'll need perl's Expect module. I don't believe OS X's perl has Expect included, you'll probably have to install it (go to www.cpan.org for help installing Perl modules). To see if you have Expect installed, run...