Centos – selinux password-less login

centosselinux

os: centos 6

currently i have selinux linux enabled (enforcing) , disabling it makes ssh passwordless login work.

i have set setsebool for ssh the following settings

[root@server]# /usr/sbin/getsebool -a | grep ssh
allow_ssh_keysign --> on
sftpd_write_ssh_home --> off
ssh_sysadm_login --> on

and also set the users home directory to

chcon system_u:object_r:ssh_home_t:s0 .ssh/

but the ssh passwordless login does not work..

any ideas..

Best Answer

Restore the default SELinux contexts for ~/.ssh folder:

restorecon -R -v /path/to/.ssh

and try again.

Related Topic