patch for Apache2.4.x with mod_proxy_fcgi to handle the changed PATH_INFO correctly
Original Reporter info from Mantis: bobo
-
Reporter name: Attila Borka
Original Reporter info from Mantis: bobo
- Reporter name: Attila Borka
Description:
Apache2.4.x "mod_proxy_fcgi" changes the way PATH_INFO is returned.
This patch fixes one of the issues.
http://bugs.freepascal.org/view.php?id=23386 needs to be fixed also, in order to fully make "mod_proxy_fcgi" work with fpc.
Steps to reproduce:
Apache 2.4.x
apache config:
===========
LoadModule proxy_module modules/mod_proxy.so
LoadModule proxy_fcgi_module modules/mod_proxy_fcgi.so
<IfModule mod_proxy_fcgi.c>
#No PATH_INFO with mod_proxy_fcgi unless this is set
SetEnvIf Request_URI . proxy-fcgi-pathinfo=1
#Alias for the long FCGI executable path and program name
Alias /something "..path_to_fcgi_application../fcgiapp_executable"
#mod_proxy_fcgi to call our FCGI executable already listening (like FastCgiExternalServer for mod_fastcgi) on port 2015
ProxyPass "/something" fcgi://127.0.0.1:2015/ [^] connectiontimeout=5 timeout=15
</IfModule>
============
As with FastCgiExternalServer, the FCGI application must be running and listening on the given port in order to receive the requests from the web server.
Additional information:
Without the SetEnvIf , apache does not even send PATH_INFO (see more info at
http://httpd.apache.org/docs/2.4/mod/mod_proxy_fcgi.html
Environment Variables section.
)
File /packages/fcl-web/src/base/custfcgi.pp needs to be updated with the attached patch in order to handle the PATH_INFO properly in fcl-web (it does not break the earlier methods, merely adds the fix for mod_proxy_fcgi).
Mantis conversion info:
- Mantis ID: 23387
- OS: All
- OS Build: All
- Build: All
- Platform: All
- Version: 2.7.1
- Fixed in version: 3.0.0
- Fixed in revision: 23210 (#3f111164)
- Monitored by: » luizamerico (Luiz Americo)
- Target version: 2.6.2