• Skip to main content
  • Skip to primary sidebar

Technipages

Smart phone, gadget and computer tutorials

  • Topics
    • Android
    • Gaming
    • Hardware
    • Internet
    • iOS
    • MacOS
    • Office
    • Software
    • Windows
    • Definitions
  • Product Reviews
  • Downloads
  • About
Linux Passwords: How to Review a User’s Settings

Linux Passwords: How to Review a User’s Settings

Posted on December 1, 2020 by Mel Hawthorne Leave a Comment

If you’re managing a Linux environment, one of the things that you should be aware of is how users’ passwords work on your system. The default settings are generally ideal, but you may have specific requirements in your environment, such as a legal requirement to reset passwords, for example, regularly. Before you make any sweeping changes to one or more user accounts, though, it’s important to review the current settings.

To do so, you need to use the “passwd” command with the “-S” flag. If you just run the command “passwd -S” you’ll see a list of your account password settings. To view other users’ settings, type “passwd -S [their username]” alternatively, if you want to see the password settings for every user, use the “-a” flag.

Analyzing the Output of the Command

The output will look something like “[username] P 09/07/2020 0 99999 7 -1” as seen in this screenshot.

The red boxes cover the username of the queried user account.

The first part is always the username of the account. Next, you have a letter which can be “P,” “L,” or “NP.” “P” means the account has a valid password set, “L” means that the account is locked by the root account and can’t be used to log in, “NP” means that a password has not been set.

The third field is a date; this is when the password was last changed. The fourth field is the “minimum password age,” which denotes the amount of time in days that must pass before users can change their password again. A minimum value of 0 means there is no limit and that the user can change their password as often as they want.

The third to last number is the “maximum password age” in days. Once this age has been reached, the user will be required to change their password the next time they log in. A max-age of 99999 days indicates that the password will never expire.

The second to last number indicates the “change warning period” in days. If a max-age is enforced, the user will start getting warnings to change their password this many days before it expires.

Final Steps

The last number is the “inactivity period” in days. A user can only change their password if they log in to the system; if the user does not log in after their password expires, they cannot change it. This value sets how many days the system will wait to lock the user’s account if they don’t sign in. A value of “-1” can disable this functionality and never to lock the account.

You Might Also Like

  • Linux Passwords: How To Force a User To Reset Their Password
    Linux Passwords: How To Force a User To Reset Their Password
  • Linux Mint: How to Add a New User
    Linux Mint: How to Add a New User
  • Linux: How to Configure the Default Password Aging Settings for New Accounts
    Linux: How to Configure the Default Password Aging…
  • Chrome: How to Delete Stored Passwords
    Chrome: How to Delete Stored Passwords
  • Fix Microsoft Edge Does Not Remember Passwords
    Fix Microsoft Edge Does Not Remember Passwords
  • IE: Enable/Disable Prompt to Remember Passwords
    IE: Enable/Disable Prompt to Remember Passwords
  • Safari: Delete Cookies, History, Passwords, etc.
    Safari: Delete Cookies, History, Passwords, etc.
  • How to Check if Your Passwords Have Been Leaked in a Data Breach
    How to Check if Your Passwords Have Been Leaked in a…
  • How to Transfer Saved Passwords in Google Chrome
    How to Transfer Saved Passwords in Google Chrome

Filed Under: Software

Reader Interactions

Did this help? Let us know! Cancel reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.

Primary Sidebar

Recent Posts

  • How to Group Open Tabs on Chrome
  • Dropbox: How To Review Your Security Settings
  • Teams: Disable All Chat Notifications During Meetings
  • Microsoft Teams: Share to Outlook Not Working
  • Teams: Manage External Access With PowerShell
  • VR Oculus Quest 2: What Is Hand Tracking?
  • Microsoft Teams: How to Enable NDI Streaming
  • Microsoft Teams: Enable Background Effects and Blur

Who’s Behind Technipages?

Baby and Daddy My name is Mitch Bartlett. I've been working in technology for over 20 years in a wide range of tech jobs from Tech Support to Software Testing. I started this site as a technical guide for myself and it has grown into what I hope is a useful reference for all.

Follow me on Twitter, or visit my personal blog.

You May Also Like

  • 8 Best Laser Printers (Review) In 2019
  • Roundup Review: Best Fitbit for Women
  • Linux

© Copyright 2021 Technipages · All Rights Reserved · Privacy