Reverse proxy and SSL redirect

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

 



Hello,

I have Apache 2.4.6 running as reverse proxy for Tomcat  7.0.96, both
running SSL, and a functioning redirect from HTTP to HTTPS for both
Apache and Tomcat.  ( Need to use both these releases due to IT
availability and app requirements )
Prior to enabling SSL on both a Json GET command made to the
application worked. Now after enabling SSL and the Apache redirect,
when the json calls are made to the application with the URL starting
with HTTP:// that should be
redirected to HTTPS:// the following errors occurs.

415 Unsupported media type
                "message": "Unsupported Media Type in Header"

When the same json GET command is issued to the same URL using
HTTPS:// it works. It looks as if communication is breaking down
between Apache and Tomcat. Below are both Apache and Tomcat confs. I
have not been able
to figure out why this is happening, and thus be able to fix it. I’m
asking if the SME’s in this mail list can look at the below configs
and see if I am missing a required directive, or if I have them in an
incorrect order.



Apache

<VirtualHost *:80>
   ServerName http://foo.domain.com
   Redirect / https://foo.domain.com/
</VirtualHost>

<VirtualHost _default_:443>
SSLEngine on
SSLProxyProtocol all
SSLCertificateFile "/auto/some-path/cert.cer"
SSLCertificateChainFile "/auto/some-path/chain.cer"
SSLCertificateKeyFile "/auto/some-path/some.key"
SSLCipherSuite "ALL:!ADH:!SSLv2:!EXPORT40:!EXP:!LOW"
ServerName "foo.domain.com"
TraceEnable Off
ProxyRequests Off
ProxyPreserveHost Off
SSLProxyEngine on
AddDefaultCharset utf-8
AddType 'application/json; charset=UTF-8' .json
ProxyPass               "/app" "https://foo.domain.com:8443/app";
ProxyPassReverse        "/app" "https://foo.domain.com:8443/app";
</VirtualHost>





Tomcat

<Connector port="8110" protocol="HTTP/1.1"
               connectionTimeout="20000"
               redirectPort="443"
               proxyName="foo.domian.com"
               ProxyPort="80"

<Connector
         port="8443"
         scheme="https"
         secure="true"
         protocol="org.apache.coyote.http11.Http11AprProtocol"
         SSLEnabled="true"
         SSLCipherSuite="ALL:!ADH:!SSLv2:!EXPORT40:!EXP:!LOW"
         SSLCertificateFile="/auto/some-path/cert.cer"
         SSLCertificateChainFile="/auto/some-path/chain.cer"
         SSLCertificateKeyFile="/auto/some-path/some.key"
         maxThreads="150"
         clientAuth="false"
         SSLProtocol="TLSv1.2 -SSLv2 -SSLv3 -TLSv1 -TLSv1.1"
         maxHttpHeaderSize="32768"
         URIEncoding="UTF-8"
/>

Appreciate any insight.

Regards
-John

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@xxxxxxxxxxxxxxxx
For additional commands, e-mail: users-help@xxxxxxxxxxxxxxxx





[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