ksh script to change passwd

Hello All,
I am trying to change a user passwd (one time password):
cat /tmp/passwd
mnop1234
mnop1234
#passwd abcd < /tmp/passwd
(for some reason, it is not able to input the password from /tmp/passwd and comes back with "New Password: ")
Is there a work around except using "expect".

thank you.

passwd reads directly from the tty and not standard input which is why your script won't work. Take a look here, though...how to do it in Perl