5

With chage command we can change password expiry information for a user. Is there anyway to enforce password aging for a group of users?

1 Answer 1

2

I think this might help. You can set default password expiry using the file /etc/login.defs.

Just press Ctrl+Alt+T on your keyboard to open Terminal. When it opens, run the command(s) below:

sudo nano /etc/login.defs

For example, you can setup values as shown below:

PASS_MAX_DAYS 30
PASS_MIN_DAYS 1
PASS_WARN_AGE 7

Once done, just close and save the file.

For more info see login.defs manpage.

1
  • Nice. Did not know of this. Is it possible to apply to certain groups only?
    – don.joey
    Apr 23, 2014 at 12:31

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .