That's because non-interactive changing of passwords is
a dangerous thing. Don't go there unless you're absolutely
sure what you're going to do. If you mess up, *NOONE* will
be able to log anymore, and you'll need to do some massive
recovery. Do you have your backup tapes ready? Do you know
which steps to take to recover your system? Have to checked
that your backup procedure is actually working? Can you read
from your backup tape?
Here's a hint (I ain't going to spoon feed you on things
changing the passwords, if you need handhelding, you shouldn't
be doing this). /usr/bin/passwd reads directly
from the (pseudo)-terminal, not from STDIN.
Abigail