First, a bit of background:
I've set up an OpenSSH server on my local media center (htpc, running Ubuntu 16.04 LTS) and I then connect to that externally, via SSH, by using the VX Connectbot app on my Android device - using this guide: https://thepcspy.com/read/remote-str...ess-xbmc-kodi/
In VX Connectbot I've also configured local port forwards for the "htpc" ssh connection, enabling me to reach a kodi instance and a transmission daemon, through the ssh tunnel. This is working quite well, and therefore I expected to be able to use the same technique for reaching the vsftpd server on the very same machine.
That, however, hasn't been the case, as I've been unable to connect the ftp server, in spite of having configured a local port forward for this exact purpose.
These are the port forwards currently configured for the htpc ssh connection in VX Connectbot:
Name: transmission http Type: local Source port: 9091 Destination: localhost:80 Name: kodi http Type: local Source port: 8080 Destination: localhost:8080 Name: ftp Type: local Source port: 21212 Destination: localhost:21
As already mentioned, the first two port forwards above work as expected, but the third one, for ftp, does not.
In the ftp client app (currently using Solid explorer, but have tried a few others), I have created a ftp connection with the following settings:
Name: htpc (remote) Remote host name: localhost Port number: 21212
(Path and username/password left out).
Just to be clear, I do have another ftp connection configured in the same app for connecting to the ftp server while on the home network, and this works without issues.
When I try to connect to the ftp server externally, I get the error: Connection refused.
It would be tempting to think that I'm simply dealing with a firewall issue here, but I don't believe that to be the case, as I get these lines in /var/log/vsftpd.log, when attempting an FTP connection from my Android device, which tells me that the ftp client actually does reach the ftp server, while still being unable to actually establish a connection:
Sun Jun 30 00:23:41 2019 [pid 31298] CONNECT: Client "::ffff:127.0.0.1" Sun Jun 30 00:23:41 2019 [pid 31297] [soren] OK LOGIN: Client "::ffff:127.0.0.1" Sun Jun 30 00:23:42 2019 [pid 31306] CONNECT: Client "::ffff:127.0.0.1" Sun Jun 30 00:23:42 2019 [pid 31304] [soren] OK LOGIN: Client "::ffff:127.0.0.1"
I did try to allow all traffic on the iptables INPUT chain, effectively disabling packet filtering for incoming network traffic on the ftp server host, but this made no visible difference in that I still got "connection refused" error when trying to connect in Solid Explorer ftp client on my Android device.
So.. I'm at a bit of a loss with this issue and really hope someone is able to help me get this thing working.