Lab activity

Password Aging Policies

Learn how to configure Linux password aging policies, password expiration, warning periods, inactivity limits, and forced password changes using chage and passwd.

Overview

Password aging policies are important security controls in Linux that help enforce password expiration, account inactivity limits, and password change requirements. In this lab, you will learn how to configure and manage password aging settings for Linux user accounts. You will work with commands such as chage and passwd to configure minimum and maximum password age, warning periods, inactivity settings, forced password changes, and account expiry policies in a Linux environment.

In This Lab, You’ll Learn How To

  • Create and manage test user accounts
  • View password aging settings using chage
  • Configure password expiry policies
  • Set minimum and maximum password age
  • Configure password expiry warning periods
  • Force users to change passwords at next login
  • Manage account inactivity and expiry settings

Key Password Management Commands

  • chage for managing password aging settings
  • passwd -e for forcing password changes
  • passwd -n for minimum password age
  • passwd -x for maximum password age
  • passwd -w for warning periods
  • chage -l for viewing account aging details

Command Examples

View password aging information:

chage -l policyuser

Set maximum password age to 90 days:

chage -M 90 policyuser

Set minimum password age:

chage -m 7 policyuser

Force password change at next login:

passwd -e policyuser

Set password warning period:

passwd -w 7 policyuser

Learning Outcomes

  • Understand Linux password aging mechanisms
  • Configure secure password expiration policies
  • Manage account inactivity and expiry settings
  • Force and verify password changes
  • Develop practical Linux security administration skills

Conclusion

Completing this lab will help you gain practical experience managing password aging policies and account security settings in Linux. You will learn how to enforce password policies and improve authentication security using standard Linux administration tools. These skills are important for Linux system administration, LFCS preparation, and maintaining secure Linux environments.