Re: changing passwords with shell scripts

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



> is there a way to change ones password through shell scripts?
> with the password username command, you are prompted for a new password.
> is there a possibility that the shell-script supply the input(new 
> password twice) from a file/text rather than the STDIN?


Hi,
Yes this is possible.
try chpasswd

chpasswd <text_file

cat text_file
user:passwd

if you use chpasswd without -e option passwd expected to be in cleartext,
but if you use with -e passwd expected to be in encrypted form.

man chpasswd

                                   
                                                          MURAT KOC  

-
: send the line "unsubscribe linux-net" in
the body of a message to majordomo@vger.rutgers.edu


[Index of Archives]     [Netdev]     [Ethernet Bridging]     [Linux 802.1Q VLAN]     [Linux Wireless]     [Kernel Newbies]     [Security]     [Linux for Hams]     [Netfilter]     [Git]     [Bugtraq]     [Yosemite News and Information]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux PCI]     [Linux Admin]     [Samba]

  Powered by Linux