0

Maybe this is a noob question but usually I dont have to deal with that stuff. I just installed apache with mod_proxy and I want to use it as a forward http proxy. What i want to do is, if a request of a certain format is executed by a web client, then the request will be send to another destination url without the client noticeing it.

No matter what domain, when the url contains 'mysign' directly after the domain name it should be send to destination I specify in my config. For e.g. all following request should be send to 'http://localhost/mysign/' instead of there ordinary destination:

http://www.gooogle.com/mysign
http://www.another.com/mysign
http://web.dev.us/mysigne/total?p=2

following request should not be tunneld:

http://mysign.not.com/test
http://wwww.ende.com/do/not/mysign

how can I configure that?

Update: I dont want to send a redirect to the client. The client browser shouldn't notice that the response is sent by another endpoint than expcected.

2 Answers 2

1

I'm not sure this'll work, but you could try it:

<ProxyMatch http://[^/]+/.*mysign>
    Allow from All
    Order Allow,Deny
    RewriteEngine on
    RewriteRule . http://localhost/mysign/ [P]
</ProxyMatch>

If the http://localhost/mysign/ URL is being served by the same server which is acting as the proxy, then you could try replacing the RewriteRule line with this:

    RewriteRule ^.*$ /mysign
1

Check ProxyPass* directives. What you want is probably:

ProxyPass /mysign http://localhost/mysign/
ProxyPassReverse /mysign http://localhost/mysign/
2
  • ProxyPass and ProxyPassReverse are for reverse proxying arrangements. They don't apply to the question at hand.
    – Kenster
    Sep 7, 2009 at 12:51
  • It's exactly what he asks from what I understand "following request should be send to 'localhost/mysign' instead of there ordinary destination"
    – radius
    Sep 7, 2009 at 13:37

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .