how can I force ProxyPass / ProxyPassReverse NOT to pass a request if the client provides a certain port?

The following passes EVERY request made to the machine correctly:

<VirtualHost _default_:443>
  SSLProxyEngine on
  ProxyPass / http://a.b.c.d:9000/
  ProxyPassReverse / http://a.b.c.d:9000/

Now I do not want to pass requests coming in for port 8080:

http://a.b.c.d:8080 should not be passed.

Is this possible?

link|improve this question
feedback

1 Answer

Your could try something like a catch all vhost after your :443 vhost declaration:

<VirtualHost _default_:*>
DocumentRoot /www/default
...
</VirtualHost>

Then use AliasMatch or a RewriteRule to rewrite any request that hits this vhost to an information page or whatever you want. Here's a great reference page on vhost matching precedence: http://httpd.apache.org/docs/2.2/vhosts/details.html

link|improve this answer
feedback

Your Answer

 
or
required, but never shown

Not the answer you're looking for? Browse other questions tagged or ask your own question.