funkdaddy_31014
Jan 06, 2011Nimbostratus
Can't remove Pragma header
Having some content caching issues with a client and I'd like to remove the Pragma header in the event that it's messing things up. I have tried the following:
when HTTP_RESPONSE {
log local0. "BEFORE HEADER: Pragma: [HTTP::header Pragma]"
HTTP::header remove "Pragma"
log local0. "AFTER HEADER: Pragma: [HTTP::header Pragma]"
}
But this always ends up with "Pragma: no-cache"
Jan 6 14:14:07 tmm tmm[2083]: Rule pragma_test : BEFORE HEADER: Pragma: no-cache
Jan 6 14:14:07 tmm tmm[2083]: Rule pragma_test : AFTER HEADER: Pragma: no-cache
Replacing the Pragma header works:
when HTTP_RESPONSE {
log local0. "BEFORE HEADER: Pragma: [HTTP::header Pragma]"
HTTP::header replace "Pragma" "foo"
log local0. "AFTER HEADER: Pragma: [HTTP::header Pragma]"
}
Ends up with "Pragma: foo" in the Response Headers.
Jan 6 14:28:10 tmm tmm[2083]: Rule pragma_test : BEFORE HEADER: Pragma: no-cache
Jan 6 14:28:10 tmm tmm[2083]: Rule pragma_test : AFTER HEADER: Pragma: foo
Any ideas?