# Stumped with issue of Nginx passing requests to php-fpm while using SSL

**URL:** <https://www.ruby-forum.com/t/stumped-with-issue-of-nginx-passing-requests-to-php-fpm-while-using-ssl/236706>\
**Category:** NGINX\
**Created:** [September 27, 2013, 12:35am UTC](https://www.ruby-forum.com/t/stumped-with-issue-of-nginx-passing-requests-to-php-fpm-while-using-ssl/236706 "2013-09-27T00:35:41Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![addis\_a](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/a/c4cdca/32.png) [@addis\_a](https://www.ruby-forum.com/u/addis_a)\
**Post date:** [September 27, 2013, 12:35am UTC](https://www.ruby-forum.com/t/stumped-with-issue-of-nginx-passing-requests-to-php-fpm-while-using-ssl/236706/1 "2013-09-27T00:35:41Z")

</div>

* * *

nginx mailing list  
removed\_email\_address@domain.invalid  
[http://mailman.nginx.org/mailman/listinfo/nginx](http://mailman.nginx.org/mailman/listinfo/nginx)

---

<div class="post-metadata">

**Author:** ![Eric\_Tyrer](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/e/b38774/32.png) [@Eric\_Tyrer](https://www.ruby-forum.com/u/Eric_Tyrer)\
**Post date:** [September 27, 2013, 12:46am UTC](https://www.ruby-forum.com/t/stumped-with-issue-of-nginx-passing-requests-to-php-fpm-while-using-ssl/236706/2 "2013-09-27T00:46:12Z")

</div>

OK, the problem is that you’re listening on _http_ on port 443. You need  
to use

listen 443 ssl [default];

for ssl.

As an aside, you can combine the http: and https: configs, using the two  
listen statements, and dropping the ‘ssl on’ in a single block. Makes  
admin simpler… havn’t checked but the two look pretty similar.

hth,

Steve

On Thu, 2013-09-26 at 22:34 +0000, Eric Tyrer wrote:

> built by gcc 4.4.7 20120313 (Red Hat 4.4.7-3) (GCC)  
> –http-fastcgi-temp-path=/var/cache/nginx/fastcgi\_temp  
> –param=ssp-buffer-size=4 -m64 -mtune=generic’
> 
> > \<?php \* @var bool
> 
> and my nginx conf is  
> Associate Director – Web Systems  
> (P) 718-262-2466
> 
> * * *
> 
> nginx mailing list  
> removed\_email\_address@domain.invalid  
> [nginx Info Page](http://mailman.nginx.org/mailman/listinfo/nginx)

–  
Steve H. BSc(Hons) MIITP

> **[Linux & Admin Support Services | "Services provided by people who are...](https://www.greengecko.co.nz/)**
>
> Offers linux support services, systems and database administration, consultancy and the full development lifecycle for open source - based solutions

Linkedin: [http://www.linkedin.com/in/steveholdoway](http://www.linkedin.com/in/steveholdoway)  
Skype: sholdowa

---

<div class="post-metadata">

**Author:** ![Eric\_Tyrer](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/e/b38774/32.png) [@Eric\_Tyrer](https://www.ruby-forum.com/u/Eric_Tyrer)\
**Post date:** [September 27, 2013, 1:36pm UTC](https://www.ruby-forum.com/t/stumped-with-issue-of-nginx-passing-requests-to-php-fpm-while-using-ssl/236706/3 "2013-09-27T13:36:54Z")

</div>

Hello!

On Thu, Sep 26, 2013 at 10:34:46PM +0000, Eric Tyrer wrote:

> Problem i have is that after attempting to login to wordpress over SSL php is  
> not being processed/executed.
> 
> I’ve got a Wordpress 3.5 multi-site using subdirectories.

[…]

> nginx handles requests fine through port 80 images, css, etc are  
> processed normally. however, logging into to a blog results in  
> no php being processed like ….
> 
> > \<?php

[…]

> my host.conf is here [http://pastie.org/private/lmr05yxem5psyemzbwukig](http://pastie.org/private/lmr05yxem5psyemzbwukig)
> 
> and my nginx conf is here [http://pastie.org/private/9gwjgvslwspg17frbus3g](http://pastie.org/private/9gwjgvslwspg17frbus3g)
> 
> i am at my wits end trying to figure it out by myself… It would  
> be great if another pair of eyes could look this over

It looks like you only have \*.php handling configured inside  
“location ~ /wp-(admin|login)” in your ssl server{} block.

–  
Maxim D.  
[http://nginx.org/en/donation.html](http://nginx.org/en/donation.html)

---

<div class="post-metadata">

**Author:** ![Eric\_Tyrer](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/e/b38774/32.png) [@Eric\_Tyrer](https://www.ruby-forum.com/u/Eric_Tyrer)\
**Post date:** [September 27, 2013, 1:41pm UTC](https://www.ruby-forum.com/t/stumped-with-issue-of-nginx-passing-requests-to-php-fpm-while-using-ssl/236706/4 "2013-09-27T13:41:35Z")

</div>

Hello!

On Fri, Sep 27, 2013 at 10:45:34AM +1200, Steve H. wrote:

> OK, the problem is that you’re listening on _http_ on port 443. You need  
> to use
> 
> listen 443 ssl [default];
> 
> for ssl.

The config posted uses “ssl on”, which is a valid way to configure  
ssl on all sockets used in a server{} block, see  
[Module ngx\_http\_ssl\_module](http://nginx.org/r/ssl).

While it is recommended to use “listen … ssl” instead as it  
allows to combine ssl and non-ssl listens in one server{} block,  
it’s not something required.

–  
Maxim D.  
[http://nginx.org/en/donation.html](http://nginx.org/en/donation.html)
