SOLVED Issue with SSH & Private / Public Key

PontWapiti

Cadet
Joined
May 8, 2019
Messages
5
Hello everyone,

I'm posting this message today because I'm having trouble setting up properly an SSH connexion for my Freenas server.
The goal of this is to access my server from my PC (Windows 10) in SSH using Putty.
I've done some research and tried several solutions without any success yet.
Let me describe what I've done so far so that you have a more precise idea of what the problem might be.

1- I've created a Dataset and a new user (the one I'll use to SSH) :
Dataset is Unix, owned by the User and has Permissions 700.
The new user has this dataset as Home directory and Permissions 700.
2- I've created a pair of Public/Private key using PuttyGen
3- Saved my private key on my Windows 10 client into my .ssh folder
4- Saved my public key into my new user .ssh folder in a new file named authorized_key

I made sure that permissions were set up as follows :
  • New User Home Directory > Permissions 700
  • .ssh folder for this new user > Owned by this new user and Permissions 700
  • authorized_key file > Permissions 644
  • The private key on my Windows 10 PC > Permissions 600 (I've used Windows right-click to Properties then Security tab to change this and then checked with WinSCP)
Regarding SSH service:
  • I've changed TCP Port to a high number
  • Unabled Login as Root
  • Unable Password Authentification
  • Enabled TCP Port forwarding
However, I keep getting the same error message: No supported authentication methods available (server sent: publickey).
I am probably missing something with permissions but can't find it yet. If you have any idea of what the problem might be, any help would be much appreciated!

Thanks a lot for your time and help!

Cheers,
PontWapiti

PS: Please find below some info regarding my FreeNas system
  • OS Version: FreeNAS-11.2-U6
  • Processor: AMD Athlon(tm) II X3 450
  • Memory: 8 GiB
  • Disks: 2x2TiB in Mirror

 

PontWapiti

Cadet
Joined
May 8, 2019
Messages
5
Well... Nevermind, problem solved. It was a silly thing... I forgot to specify the private key when using Putty.
I did the same process on my Mac and faced no problem setting up private/public key properly so I figured I did something wrong with Putty.

Sorry for the post and I hope this would help others so don't forget to add the private key into Putty when ssh from Windows client.
 
Top