Accessing FreeNAS through SSH from outside home network

Status
Not open for further replies.

WashirePie

Cadet
Joined
Sep 21, 2017
Messages
1
Hello!
First, I am not a networking specialist. But I am willing to learn.
Here's my situation and intention:

Intention

I wanted to have a shared folder, which I can access trough my home network (which works, as of right now) and also have a friend
connect to it from outside my home network trough SSH using Dynamic DNS. I'm hoping to get the SSH access secure by using Public keys. He should also be able to map my shared folder to a drive on his PC using SFTP Net Drive.

Facts
- All clients use Windows 10 Home Edition.
- As for the Server I use a HP Z200 (old business workstation) with FreeNAS-11.0-U3 (c5dcf4416).
  • MoBo: HP 506285-001
  • CPU: Core i3-540
  • RAM: 8GB DDR3
  • HDD: 1x 4TB Hitachi Deskstar
  • No Drive Controllers
  • Onboard Ethernet
What I've done so far for the initial setup of the server:
- Gave it a static IP in my home network
- Created a single Volume which uses all 4TBs
- Turned on SSH on port 22
- Turned on Dynamic DNS, configured with my No-Ip domain and login
- Created an account which is grouped to "sshd" and has all rights. (No Public key!)

Other notable facts:
- I've forwarded Port 22 to my server
- I've generated a SSH-1 (RSA) key using PuTTygen including a passphrase
- I was able to map the server to a drive using SMTP Net Drive with the local IP and my created account
- I tried putting my public key in the account "SSH Public Key" field and connect trough SFTP Net Drive without luck.

Questions
So, here are my questions:

- I'm still struggeling to access the server trough SFTP Net Drive from outside my home network. Any Ideas?
- How do I set up the Public Keys? Is there something I've missed? I've read about some auth_keys.pbo file. Where is this file located?
- How do I create a folder on my server and set it as my SSH target?

Thanks in advance!
Best regards,
Simon

UPDATE:
Found the authorized keys file in the main directory/.ssh :oops: Turns out it automatically generates it if you set a public key for an account
 
Last edited:

scrappy

Patron
Joined
Mar 16, 2017
Messages
347
It is generally recommended to not remotely access a FreeNAS server. However, using SSH with public key encryption will probably be just fine. Only thing I'd do differently is set the SSH port on your router to something other than 22 and redirect to your server's SSH port to help obscure the fact you have a remotely accessible SSH server running. While the chances of anybody getting lucky enough to guess your encryption key is next to zero, you never know what vulnerabilities may arise in OpenSSH down the road (especially if you don't keep your software updated) which could eventually lead to a bad guy finding another way into your system and by extension, your entire home network.

- Created an account which is grouped to "sshd" and has all rights. (No Public key!)
Just curious what you mean by "has all rights"? Is this account setup with root privileges?
 
Status
Not open for further replies.
Top