[stunnel-users] behaviour when using in the 'connect' field

Kelly Trinh kelly at trinhonline.com
Tue Mar 10 13:14:22 CET 2020

Hi Jose - thanks; that was the issue

thanks to your clue; I searched around a bit and found I can see what openvpn is listen to with this

netstat -nlp

and turns out editing the server.conf and removing the local line entirely makes openvpn listen on all interfaces and that got things going which was great.

---- On Tue, 10 Mar 2020 19:26:54 +0800 Josealf.rm <josealf at rocketmail.com> wrote ----


Most likely, your OpenVPN server is not listening on (not bound to) your loopback interface. Check your OpenVPN configuration file.

I understand you need to add 


to you openvpn.conf



On Mar 10, 2020, at 12:25 AM, Kelly Trinh <mailto:kelly at trinhonline.com> wrote:

stunnel-users mailing list
mailto:stunnel-users at stunnel.org

Hi all - just want to report a problem I solved recently but wanted to get some insights on what was causing the problem.

About me - learnt some unix at university (20 years ago) but nothing too serious.  Recently (1 month ago) acquired own domain name and now poking around the cloud computing / VPS thing.

Project - hand-rolling my own VPN setup on a Ubuntu 18.04 VPS.  OpenVPN is easy since it is a git-clone thing and then just follow the openvpn-install script.  I wanted to add on the Stunnel wrapper because intended to use the VPN in China and apparently their firewall does deep packet inspection and can recognize (and block) openvpn traffic.

Problem - when I set up my stunnel using as the connect destination; it doesn't seem to work (I can see from openvpn window that things seem to pipe through stunnel but then immediately the connection is terminated).  If I replace the with IP of the box I am using (say for example; everything works!  The FQDN is ok as well; as long as I don't use

Specifically the stunnel.conf:


Accept = 443  # clients connect through 443 to further avoid potential blocking

Connect =   #<- this line won't work; but if I replace with then it will work!

Question - My problem is fixed but I am curious if there is any insights on why this is happening given that and are the same machine?
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.stunnel.org/pipermail/stunnel-users/attachments/20200310/0a1e3851/attachment.htm>

More information about the stunnel-users mailing list