mod_substitute / mod_sed with Apache 2.4.7 (Ubuntu 14.04)

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi everybody,

I'm having a problem with mod_substitute or mod_sed while using one
apache2 (Ubuntu 14.04) as a proxy and load balancer.

The connection between proxy and backend is not encrypted, therefore the
backend delivers only non-https links with the backend FQDN. Those have
to be replaced by the corresponding proxy FQDN.

On the documentation page
(https://httpd.apache.org/docs/2.4/mod/mod_substitute.htm) is an example
for this specific use case. However it does not work for me and I cannot
find the reason. mod_deflate is not enabled.

For testing purposes I created an index.html with the content "asdf" in
the DocumentRoot. The content is also not replaced. Can anyone give me a
hint on how to further debug this problem? Could this problem be
specific for the Ubuntu package / dependent on a compiling parameter?

### site config ###

<Virtualhost *:443>
        ServerName www.somedomain.tld
        DocumentRoot /var/www/redirect

        SSLEngine On
        SSLCertificateFile /etc/letsencrypt/live/somedomain.tld/cert.pem
        SSLCertificateChainFile
/etc/letsencrypt/live/somedomain.tld/chain.pem
        SSLCertificateKeyFile
/etc/letsencrypt/live/somedomain.tld/privkey.pem

        ProxyPass /wordpress_test/
http://backend.somedomain.tld/wordpress_test/
        ProxyPassReverse /wordpress_test/
http://backend.somedomain.tld/wordpress_test/

        <Location />
                Substitute
"s|http://backend.somedomain.tld/|https://www.somedomain.tld/|i"
                Substitute "s|asdf|jkl|i"
                Substitute
"s|http://backend.somedomain.tld/|https://www.somedomain.tld/|"
        </Location>

</VirtualHost>

### end site config ###

Cheers
Sven


Attachment: signature.asc
Description: OpenPGP digital signature


[Index of Archives]     [Open SSH Users]     [Linux ACPI]     [Linux Kernel]     [Linux Laptop]     [Kernel Newbies]     [Security]     [Netfilter]     [Bugtraq]     [Squid]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Samba]     [Video 4 Linux]     [Device Mapper]

  Powered by Linux