ecryptfs and sshd …

I just made a discovery on the Ubuntu box I run. After being unable to log into it using SSH and my public key which it refused with a laconic Permission denied (publickey), I tried to dig deeper. So obviously I logged into the machine, stopped sshd, ran it as
/usr/sbin/sshd -d -D
and observed the unbelievable. It worked. I hadn’t fixed anything, but it worked.

So since I recalled that I had rebooted the box last time before it stopped functioning, I did so again. So the whole thing stopped working again. Until I figured out that being logged into the account is the key to the mysterious behavior. So I thought a little and remembered that the only logical reason can be that the home folder of the account that is using ecryptfs ever since the box was set up, contains the .ssh folder and the list of authorized keys … too bad it isn’t mounted unless someone is logged on interactively. So now I need to figure out how to work around ecryptfs and make the .ssh visible before having it mounted and after – preferably from the same location.

// Oliver

This entry was posted in EN, Linux, Unix and unixoid and tagged , , , . Bookmark the permalink.

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.