Nginx terminate SSL for wordpress

Posted by Mike on Server Fault See other posts from Server Fault or by Mike
Published on 2010-07-12T13:47:27Z Indexed on 2012/09/22 21:40 UTC
Read the original article Hit count: 235

Filed under:
|

I have a bit of a problem. We run a wordpress blog behind a ngnix proxy and looking to terminate the ssl on the nginx side. Our current nginx config is

upstream admin_nossl {
    server 192.168.100.36:80;
}


   server {
        listen       192.168.71.178:443;
        server_name  host.domain.com;

        ssl                  on;
        ssl_certificate      /etc/nginx/wild.domain.com.crt;
        ssl_certificate_key  /etc/nginx/wild.domain.com.key;
        ssl_session_timeout  5m;
        ssl_protocols  SSLv2 SSLv3 TLSv1;
        ssl_prefer_server_ciphers   on;
        ssl_session_cache  shared:SSL:10m;
        ssl_ciphers RC4+RSA:+HIGH:+MEDIUM:+LOW:+SSLv2:+EXP;

        location / {
           proxy_read_timeout 2000;
           proxy_next_upstream error;
           proxy_set_header X-Real-IP $remote_addr;
           proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
           proxy_set_header Host $http_host;
           proxy_redirect off;
           proxy_max_temp_file_size 0;
           proxy_pass http://admin_nossl;
           break;

It just does not seem to work. If I can hit https://host.domain.com but it quickly switches back to non-secured from what I can see.

Any pointers?

© Server Fault or respective owner

Related posts about ssl

Related posts about nginx