Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I have a redirector enabled in my Squid config file as follows:

url_rewrite_program /etc/squid/redirector.php

I need to access the original HTTP request headers from within the redirector. I'm not interested in making any changes to the request headers; I only need to be able to read them.

As far as I can tell, Squid only passes the URL to the redirector, but not the request headers. So how can I access these request headers in my redirector?

Update 1: A related side question, is it possible to access POST data within a Squid redirector? I imagine that if this is possible, the mechanism for doing so would be the same as accessing the headers.

Update 2: I believe this is possible using ICAP. I'm looking for a solution that does not involve ICAP.

share|improve this question
add comment

1 Answer

up vote 0 down vote accepted

Short answer: it isn't possible.

Long answer: it isn't possible; make use of an ICAP server instead which allows modification of request headers as per the Squid FAQ.

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

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