GreenLake Administration
- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- Re: Password Aging.
Operating System - HP-UX
1848566
Members
6142
Online
104033
Solutions
Forums
Categories
Company
Local Language
back
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Forums
Discussions
Discussions
Forums
Discussions
back
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Blogs
Information
Community
Resources
Community Language
Language
Forums
Blogs
Topic Options
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-03-2001 06:12 AM
05-03-2001 06:12 AM
Password Aging.
Is there a way that I can script a password expiration time and minimum time between changes? Here is the the situation; we have a user template with those parameters set but I hate having to go through sam everytime I have to set up a new user.
Is there a way I can script this? I was thinking of setting /etc/default/useradd to have the values I need and then just using useradd but I am nore sure of the values I need in useradd to achieve this.
This is a 10.20 untrusted system. Any help would be appreciated. Thanks.
Peter
Is there a way I can script this? I was thinking of setting /etc/default/useradd to have the values I need and then just using useradd but I am nore sure of the values I need in useradd to achieve this.
This is a 10.20 untrusted system. Any help would be appreciated. Thanks.
Peter
2 REPLIES 2
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-03-2001 06:17 AM
05-03-2001 06:17 AM
Re: Password Aging.
from the passwd man page:
-n min Determine the minimum number of days, min, that must transpire before the user can change the password.
-w warn Specify the number of days, warn, prior to the password expiring when the user will be notified that the password needs to be changed. This option is only enabled when the system has been converted to a trusted, secure system. Refer to the Managing Systems and Workgroups manual for how to convert your HP-UX to a trusted, secure system.
-x max Determine the maximum number of days, max, a password can remain unchanged. The user must enter another password after that number of days has transpired, known as the password expiration time.
the useradd just has the option to expire the login account, but not the password.
good luck.
-n min Determine the minimum number of days, min, that must transpire before the user can change the password.
-w warn Specify the number of days, warn, prior to the password expiring when the user will be notified that the password needs to be changed. This option is only enabled when the system has been converted to a trusted, secure system. Refer to the Managing Systems and Workgroups manual for how to convert your HP-UX to a trusted, secure system.
-x max Determine the maximum number of days, max, a password can remain unchanged. The user must enter another password after that number of days has transpired, known as the password expiration time.
the useradd just has the option to expire the login account, but not the password.
good luck.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-03-2001 08:44 AM
05-03-2001 08:44 AM
Re: Password Aging.
Hi Peter:
You can't do it with just useradd but you're on the right track.
The sequence is as follows:
1)useradd (if you want to change anything from the defaults args, do so; you're not trusted so
no -f we will set -e in a moment)
2) passwd username
& enter his password
3) passwd -n min -x max username
The last command will set minumum time between passwd changes to min days (rounded to the week) and the maximum valid passwd age to max days (again rounded to the week).
If you are in an NIS environment you will have to use yppasswd(3) in a c program to do the equivalent and code a replacement for yppasswd(1).
This should get you started, Clay
You can't do it with just useradd but you're on the right track.
The sequence is as follows:
1)useradd (if you want to change anything from the defaults args, do so; you're not trusted so
no -f we will set -e in a moment)
2) passwd username
& enter his password
3) passwd -n min -x max username
The last command will set minumum time between passwd changes to min days (rounded to the week) and the maximum valid passwd age to max days (again rounded to the week).
If you are in an NIS environment you will have to use yppasswd(3) in a c program to do the equivalent and code a replacement for yppasswd(1).
This should get you started, Clay
If it ain't broke, I can fix that.
The opinions expressed above are the personal opinions of the authors, not of Hewlett Packard Enterprise. By using this site, you accept the Terms of Use and Rules of Participation.
Company
Events and news
Customer resources
© Copyright 2026 Hewlett Packard Enterprise Development LP