There are three types of users under Linux:
1. Superuser: Root has all the privileges of the operating system, the UID value is 0 is the super user
2. Normal User: Only has limited operating system permissions, UID is from 500 to 6000 range
3. Pseudo-User: is to facilitate system management, to meet the corresponding system process file owner requirements, can not login, UID is from 1 to 499
passwd because all users have access to the/etc/passwd file, only the account number defined in this file does not define the password.
Each row in the/etc/passwd file represents a user, each line has 6 colons, and a row of records is divided into 7 parts
The first part: the name of the account.
The second part: password. X
Part III: User identifiers (user IDs)
Part IV: Identifier of the group in which the user is located (user group ID)
Part V: Information about the user (comment function)
Part VI: User home directory
Part VII: The user's environment (that is, the user's shell interpretation environment, such as the part is/bin/bash, is to use/bin/bash to explain the user action)
/etc/shadow is a file that holds the user's password, which can only be read by the root user.
Each line has 8 colons, spaced into 9 parts, followed by:
User name
Password (storing encrypted password, MD5 encryption) if the first character of the string is! , it indicates that the user cannot log on
Time Last modified: number of seconds from 1970 to the last modified time
Maximum time interval: 0 can be changed at any time, and if not, it will need to wait until the number of seconds to change.
Minimum time interval: 10 days, for example, indicates that 10 days must be changed. If it is 99999, it means that you can never change
Time of warning: the notification time for the password change. The default is one week
Inactivity Time: If it expires, there is still no change, the time of the delay.
Expiry time: From 1970 onwards
User management under Linux (i)