使用SSH遇到Authentication Refused: Bad Ownership or Modes for Directory
评:
在使用SSH进行git的远程仓库操作时,远端服务器提示要求输入密码.这与之前的使用情况并不
相同.检查了服务器的ssh的日志文件/var/log/secure后,注意到类似下面的信息:
Authenticationrefused:badownershipormodesfordirectory/home/git/.ssh
想来应该是文件夹读写权限的设置问题.在Google之后,找到下面这个web,与所遇问题是类似的:
SSHAuthenticationRefused:BadOwnershiporModesforDirectory
下面转贴来自其中的一段内容:
SSHdoesn’tlikeitifyourhomeor~/.sshdirectorieshavegroupwritepermissions.Yourhomedirectoryshouldbewritableonlybyyou,~/.sshshouldbe700,andauthorized_keysshouldbe600
YoucanalsogetaroundthisbyaddingStrictModesofftoyourssh_configfile,butI’dadviseagainstit-fixingpermissionsisthewaytogo.eagainstit-fixingpermissionsisthewaytogo.
相关推荐
projava 2020-11-14
WanKaShing 2020-11-12
airfish000 2020-09-11
tryfind 2020-09-14
yegen00 2020-09-10
kkaazz 2020-09-03
风语者 2020-09-02
BraveWangDev 2020-08-19
lichuanlong00 2020-08-15
gsl 2020-08-15
pandaphinex 2020-08-09
yhuihon 2020-08-09
CheNorton 2020-08-02
xiangqiao 2020-07-28
hpujsj 2020-07-26
hpujsj 2020-07-26
sshong 2020-07-19
BraveWangDev 2020-07-19
annan 2020-07-18