Stunnel says configuration is successful but service does not start

788 Views Asked by At

I am attempting to run stunnel on my Windows 10 machine to connect to a remote server. After installing and setting up the stunnel.conf file, it looks like everything is configured but the service never starts.

My stunnel.conf looks like this:

output = C:/Temp/Logs/stunnel.log

[SAMPLE]
client = yes
debug = 7
verify = 2
CAfile = C:/Program Files (x86)/stunnel/config/roots.pem
cert= C:/Program Files (x86)/stunnel/config/stunnel.pem
accept = 127.0.0.1:11000
connect = destination.com:5001
verifyChain = yes

However, when I run stunnel as an admin, this is all that appears in the logs:

2022.09.07 16:58:30 LOG5[main]: stunnel 5.65 on x64-pc-mingw32-gnu platform
2022.09.07 16:58:30 LOG5[main]: Compiled/running with OpenSSL 3.0.5 5 Jul 2022
2022.09.07 16:58:30 LOG5[main]: Threading:WIN32 Sockets:SELECT,IPv6 TLS:ENGINE,OCSP,PSK,SNI
2022.09.07 16:58:30 LOG5[main]: Reading configuration from file C:\Program Files (x86)\stunnel\config\stunnel.conf
2022.09.07 16:58:30 LOG5[main]: UTF-8 byte order mark detected
2022.09.07 16:58:30 LOG5[main]: FIPS mode disabled
2022.09.07 16:58:31 LOG4[main]: Service [SAMPLE] uses "verifyChain" without subject checks
2022.09.07 16:58:31 LOG4[main]: Use "checkHost" or "checkIP" to restrict trusted certificates
2022.09.07 16:58:31 LOG5[main]: Configuration successful

I have a collegue who has setup their stunnel with an identical stunnel.conf. They get the same lines in the log to start, but afterwards it looks like stunnel spawns a new thread and starts the service. This is what their logs look like:

2022.09.06 11:18:14 LOG5[main]: stunnel 5.65 on x64-pc-mingw32-gnu platform
2022.09.06 11:18:14 LOG5[main]: Compiled/running with OpenSSL 3.0.5 5 Jul 2022
2022.09.06 11:18:14 LOG5[main]: Threading:WIN32 Sockets:SELECT,IPv6 TLS:ENGINE,OCSP,PSK,SNI
2022.09.06 11:18:14 LOG5[main]: Reading configuration from file C:\Program Files (x86)\stunnel\config\stunnel.conf
2022.09.06 11:18:14 LOG5[main]: UTF-8 byte order mark detected
2022.09.06 11:18:14 LOG5[main]: FIPS mode disabled
2022.09.06 11:18:28 LOG4[main]: Service [SAMPLE] uses "verifyChain" without subject checks
2022.09.06 11:18:28 LOG4[main]: Use "checkHost" or "checkIP" to restrict trusted certificates
2022.09.06 11:18:28 LOG5[main]: Configuration successful
2022.09.06 11:18:53 LOG7[0]: Service [SAMPLE] started
2022.09.06 11:18:53 LOG7[0]: Setting local socket options (FD=684)
2022.09.06 11:18:53 LOG7[0]: option TCP_NODELAY set on local socket
2022.09.06 11:18:53 LOG7[0]: Service [SAMPLE] accepted connection from 127.0.0.1:52155
...

So we can't see any errors in the logs, or the event viewer, and we are at a loss at what could be causing the different behavior. Is there any way to know what might be causing this difference, or at least rule things out?

0

There are 0 best solutions below