免费注册 查看新帖 |

Chinaunix

  平台 论坛 博客 文库
最近访问板块 发新帖
查看: 3409 | 回复: 5
打印 上一主题 下一主题

solaris11中如何设置密码长度为两位的? [复制链接]

论坛徽章:
0
跳转到指定楼层
1 [收藏(0)] [报告]
发表于 2012-06-20 16:06 |只看该作者 |倒序浏览
当用passwd命令修改密码为两位的时候提示:
root@SE-T2-06:/# passwd ab
New Password:
passwd: The first 256 characters of the old and new passwords must differ by at least 3 positions.

Please try again

以上问题在solaris9或者solaris10上没有发生。

这不是密码长度过短的问题,我已经按照http://bbs.chinaunix.net/thread-991376-1-1.html里说的使密码支持了任意长度了。
/etc/default/passwd的内容:
  1. #ident  "%Z%%M% %I%     %E% SMI"
  2. #
  3. # Copyright 2005 Sun Microsystems, Inc.  All rights reserved.
  4. # Use is subject to license terms.
  5. #
  6. MAXWEEKS=
  7. MINWEEKS=
  8. PASSLENGTH=0

  9. # NAMECHECK enables/disables login name checking.
  10. # The default is to do login name checking.
  11. # Specifying a value of "NO" will disable login name checking.
  12. #
  13. NAMECHECK=NO

  14. # HISTORY sets the number of prior password changes to keep and
  15. # check for a user when changing passwords.  Setting the HISTORY
  16. # value to zero (0), or removing/commenting out the flag will
  17. # cause all users' prior password history to be discarded at the
  18. # next password change by any user.  No password history will
  19. # be checked if the flag is not present or has zero value.
  20. # The maximum value of HISTORY is 26.
  21. #
  22. # This flag is only enforced for user accounts defined in the
  23. # local passwd(4)/shadow(4) files.
  24. #
  25. HISTORY=0
  26. #
  27. # Password complexity tunables.  The values listed are the defaults
  28. # which are compatible with previous releases of passwd.
  29. # See passwd(1) and pam_authtok_check(5) for use warnings and
  30. # discussion of the use of these options.
  31. #
  32. #MINDIFF=0
  33. #MINALPHA=0
  34. MINNONALPHA=0
  35. #MINUPPER=0
  36. #MINLOWER=0
  37. #MAXREPEATS=0
  38. #MINSPECIAL=0
  39. #MINDIGIT=0
  40. #WHITESPACE=YES
  41. #
  42. #
  43. # passwd performs dictionary lookups if DICTIONLIST or DICTIONDBDIR
  44. # is defined. If the password database does not yet exist, it is
  45. # created by passwd. See passwd(1), pam_authtok_check(5) and
  46. # mkpwdict(1M) for more information.
  47. #
  48. #DICTIONLIST=
  49. #DICTIONDBDIR=/var/passwd
复制代码
大神们,这个问题该怎么解决啊??

论坛徽章:
1
操作系统版块每日发帖之星
日期:2015-10-08 06:20:00
2 [报告]
发表于 2012-06-20 16:56 |只看该作者
回复 1# sysdzw

"前256个字符的旧密码和新密码必须至少3个位置的不同。",所以試試完全不同的密碼。
   

论坛徽章:
0
3 [报告]
发表于 2012-06-21 08:53 |只看该作者
回复 2# roger1402001


    可是我必须只能设置两个字母的密码啊,怎么凑也凑不到3个位置不同啊。

论坛徽章:
0
4 [报告]
发表于 2012-06-24 20:56 |只看该作者
不明白为什么有这样的需求,不符合密码复杂度策略

论坛徽章:
20
申猴
日期:2013-09-12 19:39:05狮子座
日期:2014-07-20 21:19:51寅虎
日期:2014-08-16 18:37:47水瓶座
日期:2014-10-15 18:58:25天蝎座
日期:2015-01-22 18:19:15NBA常规赛纪念章
日期:2015-05-04 22:32:032015亚冠之胡齐斯坦钢铁
日期:2015-06-03 11:28:502015亚冠之吉达阿赫利
日期:2015-09-19 12:41:47午马
日期:2013-09-18 14:36:40戌狗
日期:2013-09-18 14:44:39处女座
日期:2013-09-24 17:46:41CU十二周年纪念徽章
日期:2013-10-24 15:41:34
5 [报告]
发表于 2012-06-26 11:36 |只看该作者
密码相似度太高了。

论坛徽章:
0
6 [报告]
发表于 2012-06-28 10:18 |只看该作者
本帖最后由 sysdzw 于 2012-06-28 10:20 编辑
killer911 发表于 2012-06-24 20:56
不明白为什么有这样的需求,不符合密码复杂度策略

因为是在一个自动化测试集中以前的版本就是设置两位的密码的,现在要改成3位以上改动太多所以想使得他支持,现在这个问题已经解决了。

【环境】
OS: Sol11

【问题现象】
设置rt用户的密码为rt的时候提示如下错误:
root@SE-T2-06:/# passwd rt
New Password:
passwd: The first 256 characters of the old and new passwords must differ by at least 3 positions.

Please try again

以上问题在solaris9或者solaris10上没有发生。

【解决方法】
1.先将rt用户密码改为3位的,比如xyz
2.然后用rt用户登陆
3.输入passwd,不带任何参数
4.输入两遍rt即可成功设置


看起来好像是sol11的一个bug,要不能改就都不能改。
您需要登录后才可以回帖 登录 | 注册

本版积分规则 发表回复

  

北京盛拓优讯信息技术有限公司. 版权所有 京ICP备16024965号-6 北京市公安局海淀分局网监中心备案编号:11010802020122 niuxiaotong@pcpop.com 17352615567
未成年举报专区
中国互联网协会会员  联系我们:huangweiwei@itpub.net
感谢所有关心和支持过ChinaUnix的朋友们 转载本站内容请注明原作者名及出处

清除 Cookies - ChinaUnix - Archiver - WAP - TOP