SSH authorized_keys permissions

adcurtin

Dabbler
Joined
Feb 23, 2019
Messages
13
I can no longer passwordless ssh in to my freenas. I got an email saying the permissions were wrong on .ssh and on the authorized keys file.

can someone do an ls -la .ssh and show me what the correct owner, group, and permissions should be, for both the .ssh directory, and the authorized_keys file?
 

Heracles

Wizard
Joined
Feb 2, 2018
Messages
1,401
Hi curtin,

Here, in the root's home directory, .ssh is 755 and authorized_keys is 644 and password-less SSH is working perfectly.

Owner is root,wheel on everything.

Good luck fixing your config,
 

adcurtin

Dabbler
Joined
Feb 23, 2019
Messages
13
thanks. I changed both of those files, it still didn't work. then looking in auth.log, it was now complaining about my homedir (where the .ssh folder is, which isn't for root). I made that 755 also, and now it's working again.


it was 775. it looks like my whole volume is 775.

I'm happy it's working now, but wondering, what broke? did permissions get hosed on the volume with an update (I also did a pool upgrade from maybe 11.0? to 11.2-U2), or is freenas 11.2-U2's sshd now more strict with enforcing correct permissions?
 
Top