How to enable SSL secure communications for the Nagwin web server ?

Nagwin's Nginx web server has a built-in support for SSL communications. Assuming that you have required certificate files located at the etc/nginx/ssl directory, you may follow steps below to enable secure communications:

  • Start a text editor capable of editing a text file with Unix line endings (Wordpad or Notepad++ for example)
  • Edit file <Nagwin installation directory>\etc\nginx\nginx.conf:
server {
       listen         80;
       return         301 https://$server_name$request_uri;
server {
listen 443 ssl;
ssl on;
ssl_certificate /etc/nginx/ssl/;
ssl_certificate_key /etc/nginx/ssl/;
ssl_session_cache shared:SSL:1m;
ssl_session_timeout 5m;
ssl_protocols TLSv1.2;
... rest of the Nagwin related configuration
  • Setup above will automatically redirect http requests to https, making your server communicate securely all the time. 
  • Restart Nagwin_Nginx service
Useful links: