Linux passwd命令

更新时间: 2019-10-16 12:40

Linux passwd命令用来更改使用者的密码

语法

passwd [-k] [-l] [-u [-f]] [-d] [-S] [username]

必要参数

  • -d 删除密码
  • -f 强制执行
  • -k 更新只能发送在过期之后
  • -l 停止账号使用
  • -S 显示密码信息
  • -u 启用已被停止的账户
  • -x 设置密码的有效期
  • -g 修改群组密码
  • -i 过期后停止用户账号

选择参数

  • --help 显示帮助信息
  • --version 显示版本信息

实例

修改用户密码

# passwd codercto  //设置codercto用户的密码
Enter new UNIX password:  //输入新密码,输入的密码无回显
Retype new UNIX password:  //确认密码
passwd: password updated successfully
# 

显示账号密码信息

# passwd -S codercto
codercto P 05/13/2010 0 99999 7 -1

删除用户密码

# passwd -d lx138 
passwd: password expiry information changed.
The Little Typer

The Little Typer

Daniel P. Friedman、David Thrane Christiansen、Duane Bibby、Robert Harper、Conor Mcbride / MIT Press / 2018-10-16 / GBP 30.00

An introduction to dependent types, demonstrating the most beautiful aspects, one step at a time. A program's type describes its behavior. Dependent types are a first-class part of a language, and are......一起来看看 《The Little Typer》 这本书的介绍吧!

URL 编码/解码

URL 编码/解码

URL 编码/解码

正则表达式在线测试

正则表达式在线测试

正则表达式在线测试

RGB CMYK 转换工具

RGB CMYK 转换工具

RGB CMYK 互转工具