You need to be root to do this but there is no single command available. From the /etc/security/passwd you get the information when the password for a particular user was set ("lastupdate"). You'd then check the user's attributes to find the intervall for a forced password change. With those two values and the current date you can calculate when the current password will be expired. Thus a script would probably be written around the following commands:
Search the script forum to find how to convert a date into seconds from epoch for easy comparison. You might even find several complete scripts there for accomplishing your aim.
Hi,
Is there any way of sending an email to a number of users indicating that the passwords of user accounts will expire?
Currently we have a test server with a number of oracle test accounts on it. Each of these accounts correspond to an instance of Oracle on the server. These... (2 Replies)
Hi,
Is there any way of sending an email to a number of users indicating that the passwords of user accounts will expire?
Currently we have a test server with a number of oracle test accounts on it. Each of these accounts correspond to an instance of Oracle on the server. These... (2 Replies)
Hi Gurus
I have a few Sol 5.9 servers and i have enabled password less authentication between them for my user ID. Often i have found that when my password has expired,the login fails.
Resetting my password reenables the keys.
Do i need to do something to avoid this scenario or is this... (2 Replies)
Hi All,
I want to write a script that will send the alert when linux server password expiry for user 'x' is less than 12 days.
I have written the below script but this is not working for expiry date 04 july
script;-
P_EXPIRY_DATE=`chage -l msdp| grep 'Password expires' | awk ' {... (2 Replies)
Hi,
I would like to know is there command which will tell me when password will be expire and when last password was changed ?
like on linux chage -l <username? (2 Replies)
Hi,
Here's the version of unix that we are working on.
> uname -a
AIX yyyyyyyy 1 6 00F613E24C00
@:on(cluster303)/iishomea/kmani00->
i have application id: aaabbb
Now i need to check whether the password for the application id set to non expiry type or not.
Moreover, with that unix... (3 Replies)
Discussion started by: kmanivan82
3 Replies
LEARN ABOUT NETBSD
pam_unix
PAM_UNIX(8) BSD System Manager's Manual PAM_UNIX(8)NAME
pam_unix -- UNIX PAM module
SYNOPSIS
[service-name] module-type control-flag pam_unix [options]
DESCRIPTION
The UNIX authentication service module for PAM provides functionality for two PAM categories: authentication and account management. In
terms of the module-type parameter, they are the ``auth'' and ``account'' features. It also provides a null function for session management.
UNIX Authentication Module
The UNIX authentication component provides functions to verify the identity of a user (pam_sm_authenticate()), which obtains the relevant
passwd(5) entry. It prompts the user for a password and verifies that this is correct with crypt(3).
The following options may be passed to the authentication module:
debug syslog(3) debugging information at LOG_DEBUG level.
use_first_pass If the authentication module is not the first in the stack, and a previous module obtained the user's password, that password
is used to authenticate the user. If this fails, the authentication module returns failure without prompting the user for a
password. This option has no effect if the authentication module is the first in the stack, or if no previous modules
obtained the user's password.
try_first_pass This option is similar to the use_first_pass option, except that if the previously obtained password fails, the user is
prompted for another password.
auth_as_self This option will require the user to authenticate himself as the user given by getlogin(2), not as the account they are
attempting to access. This is primarily for services like su(1), where the user's ability to retype their own password might
be deemed sufficient.
nullok If the password database has no password for the entity being authenticated, then this option will forgo password prompting,
and silently allow authentication to succeed.
UNIX Account Management Module
The UNIX account management component provides a function to perform account management, pam_sm_acct_mgmt(). The function verifies that the
authenticated user is allowed to login to the local user account by checking the password expiry date.
The following options may be passed to the management module:
debug syslog(3) debugging information at LOG_DEBUG level.
UNIX Password Management Module
The UNIX password management component provides a function to perform account management, pam_sm_chauthtok(). The function changes the
user's password.
The following options may be passed to the password module:
debug syslog(3) debugging information at LOG_DEBUG level.
no_warn suppress warning messages to the user. These messages include reasons why the user's authentication attempt was declined.
passwd_db=name Change the user's password only the specified password database. Valid password database names are:
files local password file
nis NIS password database
FILES
/etc/master.passwd default UNIX password database.
SEE ALSO passwd(1), getlogin(2), crypt(3), getpwent(3), syslog(3), nsswitch.conf(5), passwd(5), nis(8), pam(8)BSD February 26, 2005 BSD