Re: cannot ssh to localhost: Permission denied (publickey,gssapi-keyex,gssapi-with-mic)

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tue, 20 Jun 2017 20:36:22 +0200
Frédéric Bron <frederic.bron@xxxxxxx> wrote:

> >> -rw-------. 1 egreshko egreshko
> >> unconfined_u:object_r:ssh_home_t:s0  398 Jun 21 01:35
> >> authorized_keys  
> >
> > Interesting, I have home_root instead of ssh_home. What does that
> > mean? Does it mean that I created the .ssh directory as root, then
> > chown it which is possible?
> > I am totally unaware about selinux. Each time I hear about it, it is
> > because I have a problem. I guess when it is useful, I do not see
> > it.
> >
> > -r--------. 1 fred fred unconfined_u:object_r:home_root_t:s0  386
> > 2017-06-20 17:59 authorized_keys  
> 
> 
> that was the problem:
> I removed .ssh, I let it be created by the system while try to ssh
> localhost, then I created all the files again inside.
> They now have unconfined_u:object_r:ssh_home_t:s0 context and I can
> ssh.
> 
> Could you explain me what was the issue and how I could change it
> without having to recreate everything?

Another way, to change just a single file, or a few, you can use the
command chcon. It has a man page, but the command you would have used
in this case is
chcon -t home_t [file name]

If you ever suspect that selinux might be the issue, you can issue the
following command as root,
setenforce 0
and it will put selinux in permissive mode, warning about errors,
instead of aborting the process.
To return to enforcing mode, 
setenforce 1
_______________________________________________
users mailing list -- users@xxxxxxxxxxxxxxxxxxxxxxx
To unsubscribe send an email to users-leave@xxxxxxxxxxxxxxxxxxxxxxx



[Index of Archives]     [Older Fedora Users]     [Fedora Announce]     [Fedora Package Announce]     [EPEL Announce]     [EPEL Devel]     [Fedora Magazine]     [Fedora Summer Coding]     [Fedora Laptop]     [Fedora Cloud]     [Fedora Advisory Board]     [Fedora Education]     [Fedora Security]     [Fedora Scitech]     [Fedora Robotics]     [Fedora Infrastructure]     [Fedora Websites]     [Anaconda Devel]     [Fedora Devel Java]     [Fedora Desktop]     [Fedora Fonts]     [Fedora Marketing]     [Fedora Management Tools]     [Fedora Mentors]     [Fedora Package Review]     [Fedora R Devel]     [Fedora PHP Devel]     [Kickstart]     [Fedora Music]     [Fedora Packaging]     [Fedora SELinux]     [Fedora Legal]     [Fedora Kernel]     [Fedora OCaml]     [Coolkey]     [Virtualization Tools]     [ET Management Tools]     [Yum Users]     [Yosemite News]     [Gnome Users]     [KDE Users]     [Fedora Art]     [Fedora Docs]     [Fedora Sparc]     [Libvirt Users]     [Fedora ARM]

  Powered by Linux