title: Apache reverse proxy for wss protocol
body: <p>My application uses SockJS with Spring Framework. I have a reverse proxy on my server to redirect https requests to tomcat container. Configuration : </p>
  
  <pre><code>&lt;VirtualHost *:443&gt;
      ProxyPreserveHost On
  
      ProxyPass /boot http://127.0.0.1:8080/boot/
      ProxyPassReverse /boot http://127.0.0.1:8080/boot/
  
          ServerName MY_DOMAIN.com
  
          SSLEngine on
          SSLProtocol all
          SSLCertificateFile /etc/apache2/ssl/muhamo.crt
          SSLCertificateKeyFile /etc/apache2/ssl/muhamo.key
          SSLCACertificateFile /etc/apache2/ssl/bundl.crt
  &lt;/VirtualHost&gt;
  </code></pre>
  
  <p>How can I configure my virtual host to forward wss requests to my application? I get the error messages like : </p>
  
  <pre><code>Opening Web Socket...
  sockjs.js:1213 WebSocket connection to 'wss://MY_DOMAIN.com/boot/tracking/557/jcf7btih/websocket' failed: Error during WebSocket handshake: Unexpected response code: 403
  
  sockjs.js:807 POST https://MY_DOMAIN.com/boot/tracking/557/7cl9qov2/xhr_streaming 403 (Forbidden)
  
  sockjs.js:807 POST https://MY_DOMAIN.com/boot/tracking/557/cvl8ti6k/xhr 403 (Forbidden)
  </code></pre>