How can I enable mod_proxy_http

How can enable and load mod_proxy_http?

I have XAMPP, and I want to enable mod_proxy_http

I can see the module XAMPP/apache/modules/mod_proxy_http.so but I don't see any commanted module directives to uncomment in file XAMPP/apahce/conf/httpd.comf

I have restarted the server and I see the module has not loaded through phpinfo()

How can enable and load mod_proxy_http?


You should have lines similar to this in your httpd.conf:

LoadModule proxy_module modules/mod_proxy.so
LoadModule proxy_balancer_module modules/mod_proxy_balancer.so
LoadModule proxy_ftp_module modules/mod_proxy_ftp.so
LoadModule proxy_http_module modules/mod_proxy_http.so
LoadModule proxy_ajp_module modules/mod_proxy_ajp.so
LoadModule proxy_connect_module modules/mod_proxy_connect.so

Which enable the modules in question. With the module enabled, you'll want to add configuration on how you're wanting to use mod_proxy. There's example configurations located here. Be sure to also follow the recommendations in the security area.

<Proxy *>
  Order Deny,Allow
  Deny from all
  Allow from 192.168.0
</Proxy>

If you're configuring a reverse proxy, it's recommended to implement the paths in the relevant virtual host code blocK.

ProxyPass /foo http://foo.example.com/bar
ProxyPassReverse /foo http://foo.example.com/bar