返回首页

密码锁随机密码是怎么生成的?

78 2023-09-15 02:03 admin

三种方式生成随机密码

1、使用openssl

openssl rand -base64 14

# 生成14位得随机字符串

2、使用/dev/urandom 设备

< /dev/urandom tr -dc A-Za-z0-9 | head -c 14; echo

# 生成14位得随机字符串

3、使用pwgen命令

yum install pwgen

pwgen 14 1

# 生成1行14位的字符串