简单的Linux用户口令

系统 Linux
由于Linux非常的受欢迎,最近很多朋友都在学习Linux,本文为你讲解Linux用户口令,希望你能学好Linux用户口令。

由于Linux非常的受欢迎,最近很多朋友都在学习Linux,本文为你讲解Linux用户口令,希望你能学好Linux用户口令。以前别人问做USER口令控制时,推荐别人使用/etc/shadow,后来想想,好好别的地方也行,这一翻,发现以下也可以控制。

  1. [root@linux1 init.d]#            more /etc/login.defs   
  2. # *REQUIRED*  
  3. #   Directory where mailboxes reside, _or_ name of file, relative to the  
  4. #   home directory.  If you _do_ define both, MAIL_DIR takes precedence.  
  5. #   QMAIL_DIR is for Qmail  
  6. #  
  7. #QMAIL_DIR      Maildir  
  8. MAIL_DIR        /var/spool/mail  
  9. #MAIL_FILE      .mail  
  10.    
  11. # Password aging controls:  
  12. #  
  13. #       PASS_MAX_DAYS   Maximum number of days a password may be used.  
  14. #       PASS_MIN_DAYS   Minimum number of days allowed between password changes.  
  15. #       PASS_MIN_LEN    Minimum acceptable password length.  
  16. #       PASS_WARN_AGE   Number of days warning given before a password expires.  
  17. #  
  18. PASS_MAX_DAYS   99999  
  19. PASS_MIN_DAYS   0  
  20. PASS_MIN_LEN    5  
  21. PASS_WARN_AGE   7  
  22.    
  23. #  
  24. # Min/max values for automatic uid selection in useradd  
  25. #  
  26. UID_MIN                   500  
  27. UID_MAX                 60000  
  28.    
  29. #  
  30. # Min/max values for automatic gid selection in groupadd  
  31. #  
  32. GID_MIN                   500  
  33. GID_MAX                 60000  
  34.    
  35. #  
  36. # If defined, this command is run when removing a user.  
  37. # It should remove any at/cron/print jobs etc. owned by  
  38. # the user to be removed (passed as the first argument).  
  39. #  
  40. #USERDEL_CMD    /usr/sbin/userdel_local  
  41.    
  42. #  
  43. # If useradd should create home directories for users by default  
  44. # On RH systems, we do. This option is overridden with the -M flag on  
  45. # useradd command line.  
  46. #  
  47. CREATE_HOME     yes  
  48.    
  49. [root@linux1 init.d]#   

这样你就能学会Linux用户口令控制。

责任编辑:小霞 来源: NET130
相关推荐

2010-06-13 09:25:12

MySQL root用

2010-11-29 13:05:00

SYBASE用户口令

2013-06-21 17:09:05

2010-10-29 09:36:18

ORACLE用户

2012-05-22 15:37:10

2009-12-24 15:59:58

Linux hal

2009-10-27 09:31:24

Windows Ser口令策略

2014-06-06 10:01:31

2022-06-06 08:00:59

Kvm虚拟机磁盘

2011-08-25 11:21:18

2023-08-08 08:34:47

漏洞环境获取方法

2023-09-13 07:30:36

ADManager漏洞调试

2017-09-08 10:45:52

Linux排错方案root口令

2010-11-16 16:23:04

Oracle修改用户

2015-06-01 10:17:36

2010-05-06 18:07:33

Unix命令

2012-03-28 13:42:18

金山快盘云存储

2015-08-31 10:59:22

2013-12-16 20:08:09

百会CRM

2016-12-01 17:51:41

海信
点赞
收藏

51CTO技术栈公众号