Running stunnel as a service under windows
Giuseppe J. Crisafulli <jcrisafulli[at]xram[dot]com>


Requirements:

First start by copying the aforementioned files from the Microsoft W2K resource kit to a directory of your choice (i.e. c:\my_services).  Go to this newly created directory and type:

C:\my_services> instsrv pop3s c:\my_services\srvany.exe

You should now personalize and import the following .reg file:

Windows Registry Editor Version 5.00

[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\pop3s\Parameters]
"Application"="c:\\my_services\\stunnel.exe"
"AppParameters"="-D 6 -o c:\\my_services\\pop3s_client.log -c -d my.local.ip.address:110 -r my.pop3s.ip.address:995"
"AppDirectory"="c:\\my_services"

Now it is time to test the newly created service:

C:\>net start pop3s

To confirm that everything went OK you can do two things:

  1. Type netstat -nap tcp | find "110"  at the command prompt.  This should "expose" one line with your local ip address colon 110 (i.e. 172.16.0.1:110) to show that there is a socket waiting for a connection on port 110.
  2. Type type c:\my_services\pop3s-client.log at the command prompt.  This will allow you to peruse the newly created service log file.

Copyright © 2001 Giuseppe J. Crisafulli. All rights reserved.
Revised: 02/26/02
.
Hit Counter