Welcome 微信登录

首页 / 操作系统 / Linux / Linux技巧分享 生成随机字符串

OS:Linux操作系统生成全字符随机的字串:cat /dev/urandom | strings -n C | head -n L生成数字加字母的随机字串:cat /dev/urandom | sed "s/[^a-zA-Z0-9]//g" | strings -n C | head -n L其中C表示字符串的字符数,L表示要生成多少行字符。