httpd-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Toomas Aas <toomas....@raad.tartu.ee>
Subject [users@httpd] ProxyPassMatch vs FilesMatch
Date Wed, 19 Mar 2014 05:06:48 GMT
Hello!

I'm setting up a site with Apache 2.4.6 and PHP 5.5.9, using PHP-FPM  
via mod_proxy_fcgi.

In my configuration I have this:

ProxyPassMatch ^/(.*\.php)$ fcgi://127.0.0.1:9000/storage/www/sites/mysite/$1

This seems to work just fine.

The purpose of this site is to authenticate users with client  
certificates using some PHP processing, so in another point of my  
configuration I have this:

SSLOptions +StdEnvVars

This also works as expected - various _SERVER[SSL_*] variables are  
made available and can be used in PHP.

However...

when I enclose the SSLOptions directive in FilesMatch block like this:
<FilesMatch "\.php$">
     SSLOptions +StdEnvVars
</FilesMatch>

... then the SSLOptions directive is not in effect - variables are not  
available in PHP.

This worked in older server with Apache 2.2, where mod_php was used  
instead of PHP-FPM.

It seems that when both ProxyPassMatch and FilesMatch are present then  
ProxyPassMatch somehow "wins" and FilesMatch is not regarded. Is this  
expected behaviour and is there any way to achieve what I'm trying to  
do - change SSLOptions only for requests for .php files, not all files?

Disclaimer: I did see that 2.4.9 was just released, but looks like  
FreeBSD port is not available yet.

Regards,
-- 
Toomas Aas



---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org


Mime
View raw message