Museum

Home

Lab Overview

Retrotechnology Articles

Online Manuals

⇒ passwd(5) — HP-UX 5.00

Media Vault

Software Library

Restoration Projects

Artifacts Sought

Related Articles

login(1)

passwd(1)

a64l(3C)

crypt(3C)

getpwent(3C)

group(5)

PASSWD(5)

NAME

passwd − password file, pwd.h

HP-UX COMPATIBILITY

Level: Multi-user - HP-UX/STANDARD

Origin: System V

DESCRIPTION

Passwd contains for each user the following information:

login name
encrypted password
numerical user ID
numerical group ID
reserved field which will be used for identification
initial working directory
program to use as shell

This is an ASCII file.  Each field within each user’s entry is separated from the next by a colon.  Each user is separated from the next by a new-line.  If the password field is null, no password is demanded.  If the shell field is null, /bin/sh is used. 

This file resides in directory /etc.  Because of the encrypted passwords, it can and does have general read permission and can be used, for example, to map numerical user IDs to names. 

The encrypted password consists of 13 characters chosen from a 64-character set of "digits" described below, except when the password is null, in which case the encrypted password is also null.  Login can be prevented by entering in the password field a character that is not part of the set of digits(e.g.  ∗). 

The characters used to represent "digits" are .  for 0, / for 1, 0 through 9 for 2−11, A through Z for 12−37, and a through z for 38−63. 

The super-user can set up "password aging" for a user by inserting a comma and a string of characters after the user’s encrypted password.  The first character in the string is the maximum number of weeks a password can remain valid; after that number of weeks elapses, the user will be required to choose a new password upon logging in.  The second character is the minimum number of weeks that must elapse before the user can change passwords again.  The rest of the characters tell in which week the password was last changed (weeks are counted from the beginning of 1970).  A null string is the same as zero.  If both the first and second characters are zero (i.e. both "."), the user must change passwords upon his or her next login; the "age" will then disappear from the password file altogether.  For example, if the super-user inserts ",.." after a user’s encrypted password, the user will have to change passwords upon logging in; when that happens, the ",.." will disappear.  The comma is required. 

If the second character has a greater decimal equivalent than the first (such as ",./"), only the super-user will be able to change the password. 

Pwd.h designates the broken out password file as obtained by getpwent(3C):

struct passwd {
char∗pw_name;
char∗pw_passwd;
unsigned int∗pw_uid;
unsigned int∗pw_gid;
char∗pw_age;
char∗pw_comment;
char∗pw_gecos;
char∗pw_dir;
char∗pw_shell;
};

It is suggested that the range 0-99 not be used for user and group ID’s (pw_uid and pw_gid in the above structure) so that IDs which may be assigned for system software do not conflict. 

HARDWARE DEPENDENCIES

Series 200/500:
The following fields have character limitations as noted:

the login name field can be no longer than 8 characters;

the initial working directory field can be no longer than 63 characters;

the program field can be no longer than 44 characters. 

The results are unpredictable if these fields are longer than the limits specified above. 

The reserved field, called pw_gcos in the data structures used by getpwent(3C), is reserved for future use. It currently may be used to contain any information the system manager desires, but such use may conflict with the use of future HP features. The correct operation of the system will never depend on this field, but some optional feature may specify its format and content.

FILES

/etc/passwd

SEE ALSO

login(1), passwd(1), a64l(3C), crypt(3C), getpwent(3C), group(5). 

Hewlett-Packard  —  last mod. May 11, 2021

Typewritten Software • bear@typewritten.org • Edmonds, WA 98026