Hi all.I have a Solaris machine running Apache 1.3.14 with mod_proxy, mod_rewrite, and mod_ssl compiled.Each piece is working well (though if anyone can tell me how to proxy https I'd sure appreciate it).
My main question has to do with mod_rewrite.What this apache installation is trying to do is serve as a proxy which will take the URL the user entered and append it to a base URL (actually a servlet on a different machine which takes a URL as it's argument).To that end I have the following sections in httpd.conf:
<IfModule mod_proxy.c>
ProxyRequests On
<Directory proxy:*>
Order deny,allow
Deny from all
Allow from 10.100.
</Directory>
ProxyVia On
ProxyPass / </IfModule>
##
## rewriting code
##
RewriteEngine on
RewriteLog /path/to/proxy_server/apache/logs/rewrite_log
RewriteLogLevel 1
# Don't rewrite local URLs
RewriteCond %{HTTP_HOST}!^proxy\.box\.com
# Only rewrite proxy requests
RewriteRule ^proxy.+)
# Rewrite as servlet URL plus url as arg
RewriteRule ^proxy.+)\ [R]
(Sorry for the weird formatting, the message box is smaller then the resulting post which makes for wacky formatting)
-------------------
This works fine and accomplishes most of what I want.... However:this solution leaves a very long URL in the users browser, such as:
What I want to do is display " in the browser, even though the page has been filtered through our box...
Is this possible??
How?
Much appreciated! I've been struggling with this for a couple days now.
My main question has to do with mod_rewrite.What this apache installation is trying to do is serve as a proxy which will take the URL the user entered and append it to a base URL (actually a servlet on a different machine which takes a URL as it's argument).To that end I have the following sections in httpd.conf:
<IfModule mod_proxy.c>
ProxyRequests On
<Directory proxy:*>
Order deny,allow
Deny from all
Allow from 10.100.
</Directory>
ProxyVia On
ProxyPass / </IfModule>
##
## rewriting code
##
RewriteEngine on
RewriteLog /path/to/proxy_server/apache/logs/rewrite_log
RewriteLogLevel 1
# Don't rewrite local URLs
RewriteCond %{HTTP_HOST}!^proxy\.box\.com
# Only rewrite proxy requests
RewriteRule ^proxy.+)
# Rewrite as servlet URL plus url as arg
RewriteRule ^proxy.+)\ [R]
(Sorry for the weird formatting, the message box is smaller then the resulting post which makes for wacky formatting)
-------------------
This works fine and accomplishes most of what I want.... However:this solution leaves a very long URL in the users browser, such as:
What I want to do is display " in the browser, even though the page has been filtered through our box...
Is this possible??
How?
Much appreciated! I've been struggling with this for a couple days now.