PASSLEN(S) UNIX System V PASSLEN(S)
Name
passlen - determine minimum password length
Syntax
#include <sys/types.h>
#include <sys/security.h>
#include <sys/audit.h>
#include <prot.h>
int passlen(life_dur, login_delay, alphabet_size)
time_t life_dur;
time_t login_delay;
int alphabet_size;
Description
The passlen routine takes the password lifetime duration
life_dur for an account and the login_delay between login
attempts, both values in seconds, and the alphabet_size of
distinct characters, and returns the minimum password length
according to the algorithm in the DoD Password Management
Guideline (Green Book). Two other parameters used by the
Guideline are fixed, namely the size of the alphabet (26
characters) and the probability of guessing a password (1
chance in a million).
The formula is:
/
| login delay * life dur
| ln ------------------------
| prob guess
min_pass_len = ceil| ----------------------------
| ln alphabet_size
\
Notes
If the lifetime or guess parameters change in the Protected
Password database for this account (or for the system
default if those values are used in an account), it is a
good idea to invalidate the password in case the new
parameters require a longer minimum password length.
See Also
passwd(C), randomword(S), exp(S), floor(S)
DoD Password Management Guideline (Green Book),
CSC-STD-002-85, 12 April 1985.
Value Added
passlen is an extension of AT&T System V provided by the
Santa Cruz Operation.
(printed 6/20/89)