脚本Cent0S 5.4中此命令的问题

| 我在安装脚本中有此命令
Running Command: useradd ftpsecure
Running Command: /etc/init.d/vsftpd restart
Running Command: chkconfig --add vsftpd
Running Command: chkconfig vsftpd on
Running Command: /usr/sbin/groupadd cdms-users
Running Command: /usr/sbin/useradd -g cdms-users -d /ftpUploads/ cdmsUser -p cdms
        [ESC[0;31mFAILEDESC[0m]
似乎在使用最后一条命令时遇到问题。如果有人有什么想法可能是错的。 在此先感谢大家。     
已邀请:
useradd
\'2ѭ标志(用于指定密码)不是用于指定纯文本密码。 这是
useradd
联机帮助页中的描述。
   -p, --password PASSWORD
       The encrypted password, as returned by crypt(3). The default is to disable the
       password.

       Note: This option is not recommended because the password (or encrypted password) will
       be visible by users listing the processes.

       You should make sure the password respects the system\'s password policy.
您将必须为密码生成“ 5”哈希值。 在另一个StackOverflow线程中接受的答案显示了一种实现方法:Usercrypt使用crypt密码生成 尽管在命令行上指定普通密码可能是一个安全漏洞,因为它可能会记录在命令行历史记录中。     

要回复问题请先登录注册