This is a discussion on Problems with HTTP POST request via cache_peer - squid ; Hi I'm behind the Great F*cking Wall of Mainland China, and tor is the right way for me to bypass the GFW. So I add the support of tor and privoxy to my existing squid box to annoymous the request ...
I'm behind the Great F*cking Wall of Mainland China, and tor is the
right way for me to bypass the GFW.
So I add the support of tor and privoxy to my existing squid box to
annoymous the request to web sites such as google. Everything goes just
fine except the HTTP POST request, and below is part of my
------ cut here
acl POST method POST
acl TO_WIKI dstdomain -i "/etc/squid/filters/wiki.filter"
acl TO_GOOGLE dstdom_regex -i "/etc/squid/filters/google.filter"
acl TO_GCACHE url_regex search\?q=cache
acl TO_MISSING dstdomain -i "/etc/squid/filters/missing.filter"
cache_peer localhost parent 8118 7 no-query default
always_direct deny TO_GOOGLE
always_direct deny TO_GCACHE
always_direct deny TO_WIKI
always_direct deny TO_MISSING
always_direct deny POST
always_direct allow all
The configuration above goes fine, the normal requests go through the
squid box directly and requests towards the defined ACL rules are
redirected to the privoxy listening locally, but with the POST request
to these restricted sites, the access_log show lines like
------ cut here
172.16.0.100 - - [18/Jan/2007:02:11:14 +0800] "POST
http://www.somesite.com/logging.php? HTTP/1.1" 504 1446 TCP_MISSIRECT
It turns out to be a http error 504, If I have the configuration line
"never_direct allow all" uncommented, all the request could be
redirected to the local privoxy, but traffic'll be rather slow in this
Howto fix this up, Any clue's welcomed, thank you