不能
passwd 是用用户名加password 一起做的md5.所以, 不同用户,相同密码的md5是不同的.
I don't think so.
I have copied a lot of passwords in such a way. (Solaris 8/RH Linux + DES encryption).
And, I did another test on my Linux box: MD5 password can be copied. It's nothing to do with a user name. 原帖由 lmix 于 2005-12-5 14:30 发表
root用户修改自己的passwd居然提示Permission denied,没天理阿,哪位大侠遇到过这种问题?
it could be due to /etc/passwd or /etc/shadow corrupted.
wc -l /etc/passwd /etc/shadow
if their line numbers are different, fix it.
if the same, compare their account names:
# awk -F:'{print $1}' /etc/passwd | sort > /tmp/tmp1
# awk -F:'{print $1}' /etc/shadow | sort > /tmp/tmp2
# diff /tmp/tmp1 /tmp/tmp2
if different, fix it.
Be reminded that,the permission of /etc/passwd should be "444", and the one of /etc/shadow should be 400. 12楼如果说的是正确的话,只要执行一下pwconv就可以了
不过我觉得还是用了NIS的可能性大,
ps -aef |grep yp
看一下有没有在用NIS 原帖由 doni 于 2006-1-23 11:51 发表
12楼如果说的是正确的话,只要执行一下pwconv就可以了
不过我觉得还是用了NIS的可能性大,
ps -aef |grep yp
看一下有没有在用NIS
if so, then do
# ps -ef | egrep "yp|nis|ldap"
if either of NIS, NIS+, LDAP is configured, then do
# passwd -r files root
to change local root's password.
passwd不能用,应该是相关文件配置错误
我开始也碰到这个问题了,后来看了一些,是/etc/nsswitch.conf里面有点问题,可以将相关行中(主要是user、group)的nis去掉,或者将其顺序调到最后。 应该是使用了nis验证吧?Dec6 10:47:51 sv1 passwd: passwdutil.so: can't get domain
如果不是的话。那我以前也碰到过..好像是文件被设置了sticky属性了.
ls -l /etc/passwd
帖出来看看. 遇到类似问题,发现/usr/lib/netsvc/yp/ypbind 没有运行。用ROOT执行一下后好了 不能
passwd 是用用户名加password 一起做的md5.所以, 不同用户,相同密码的md5是不同的.
q1208c 发表于 2005-12-05 19:45 http://bbs.chinaunix.net/images/common/back.gif
这么老的贴子了....
这说法绝对是错的,password跟用户名无关,solaris是默认是des算法加密的,为密码和salt加密而成.只要有权修改shadow文件,把别的用户的密文借过去,密码一样可以用. 这坟挖的有水平。 回复 18# 非凡公子
我是说错了. 你说的对.
谢谢提醒.