SOLVED openVPN with (S)FTP Client

itskando

Contributor
Joined
Apr 30, 2018
Messages
172
I have successfully gotten openVPN to connect to my server.

When connected on a LAN without the use of openVPN,
I am able to connect to the SFTP using the Transmit app client via <servername>.local.

When connected via openVPN in a remote location, however,
I am unable to connect to any FTP using the mac OS client or the Transmit app client, even though
I am able to connect to ssh (via terminal) and to the freeNAS GUI (via web browser).

When connected via openVPN in a remote location, I have:
• verified that FTP is enabled in the freeNAS GUI.
• tried connecting via:
<servername>.local
<servername>.nas.<domainName>.com
<domainIPaddress>
• tried connecting via FTP and SFTP.
• tried to connect via a user in the FTP group and (briefly) via root user.
• tried setting Services --> FTP --> Masquerade Address to hostname <servername>.nas.<domainName>.com

.

Service --> FTP --> Configure:
Code:
Port                       : 21

Clients                    : 5
Connections                : 10
Login Attempts             : 1
Timeout                    : 600

Allow root       login     : Yes [Temporarily]
Allow anonymous  login     : No
Allow local user login     : Yes
Display Login              : <blank>

Allow Transfer Resumption  : Yes
Always Chroot              : Yes

Perform Reverse DNS Lookups: No
Masquerade Address         : <blank>
Certificate                : <blank>
TLS No Certificate Required: No

In all cases, the server is not found. Any suggestions?

I have found similar issues in the following threads,
which appear to discuss port forwarding as the solution, but
are old, locked, vague, and do not specify whether this solution bypasses openVPN:
 
Last edited:

itskando

Contributor
Joined
Apr 30, 2018
Messages
172
I assume SFTP connected so easily on my home network since it's a local network.
I assume if I actually wanted to use SFTP I would need to setup certificates in services?
 

itskando

Contributor
Joined
Apr 30, 2018
Messages
172
Actually, from memory, are there certain services which should not be simultaneously enabled?
Can FTP, SMART, SMB, SSH be active together?

[Edit]: I think so, I'm probably thinking of the rule to avoid enabling combinations of SMB, AFP, and NFS together.
 
Last edited:

itskando

Contributor
Joined
Apr 30, 2018
Messages
172
Is there any form of port forwarding I would have had to set up for FTP?
(My only port forwards are those of the VPN on the server side.)

(I've read that some people suggest using a different port for ssh and then port forwarding to the intended 22;
is that true — are there any guides for that or at least lists of ports to avoid using, and if it is true, does that apply to FTP's port 21 also?)
 
Last edited:

itskando

Contributor
Joined
Apr 30, 2018
Messages
172
Solved: I was attempting my public IP address, but I should have been attempting to connect to my local IP address via the openVPN connection.
I still don't understand why hostname <servername>.local wouldn't work through the VPN.
 
Top