[users@httpd] Unescaping proxied URLs (httpd 1.3)

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

 



Hi everyone,

We're running Apache HTTPD 1.3.33 on a Debian-stable server (although we
do have a server on 2.0.54 if that will make things easier), and I'm
attempting to set up a reverse proxy but keep running into trouble with
URL escapes.

A server on a nearby subnet is causing big problems for users on dialup
because it returns massive pages (250+ Kb), and several clients keep
timing out. It's not an Apache server, and I've been led to
believe that most of the code for it was written in 1998.

In order to alleviate this, I'm trying to set up a reverse proxy with
mod_gzip to compress the large pages down to a more manageable size
(initial tests indicate that they can be reduced by as much as 70%).

However, I'm running into a problem: the target server is broken in
several ways, one of which is not handling escaped URLs. When you log in,
you get dumped into a /server/~username/ directory, which Apache appears
to be calling as /server/%7Eusername/ - this returns the target server's
idea of a 404 ("There is nothing to see at this location.").

I've looked at mod_rewrite's unescape function, but I'm afraid I really
don't understand how it works.

Short of hacking the source and commenting out all the unescaping
functions, is there a way to get Apache to proxy the requests verbatim?

The relevant parts of my httpd.conf are below.

Thanks for any assistance,

David Adam
zanchey@xxxxxxxxxxxxxxxxx

---
<VirtualHost fish.ucc.asn.au>
# [DAA] <zanchey@> owns this block of code. If it's still here in 2006,
# bug him about it.
    ServerName fish.ucc.asn.au
    ServerAlias fish.ucc.gu.uwa.edu.au
    ProxyPass / http://www.target.edu.au/
    ProxyPassReverse / http://www.target.edu.au/
<IfModule mod_gzip.c>
 mod_gzip_on Yes
 mod_gzip_can_negotiate Yes
 mod_gzip_add_header_count Yes
 mod_gzip_minimum_file_size 400
 mod_gzip_maximum_file_size 0
 mod_gzip_temp_dir /tmp
 mod_gzip_keep_workfiles No
 mod_gzip_maximum_inmem_size 100000
 mod_gzip_dechunk Yes

 mod_gzip_item_include mime ^text/*
 mod_gzip_item_include mime httpd/unix-directory
 mod_gzip_item_include file \.htm$
 mod_gzip_item_include file \.html$
 mod_gzip_item_include handler proxy-server
 mod_gzip_item_include handler cgi-script

 mod_gzip_item_exclude rspheader Content-Type:image/*
 mod_gzip_item_exclude mime text/css
 mod_gzip_item_exclude file \.css$
 mod_gzip_item_exclude file \.js$
 mod_gzip_command_version '/mod_gzip_status'
</IfModule>
</VirtualHost>



---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@xxxxxxxxxxxxxxxx
   "   from the digest: users-digest-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