Skip to content
This repository has been archived by the owner on Jul 13, 2021. It is now read-only.

Age is mistakenly generated for newly obtained responses #80

Open
vfaronov opened this issue Jan 30, 2016 · 0 comments
Open

Age is mistakenly generated for newly obtained responses #80

vfaronov opened this issue Jan 30, 2016 · 0 comments

Comments

@vfaronov
Copy link
Contributor

RFC 7234 § 5.1:

The presence of an Age header field implies that the response was not generated or validated by the origin server for this request.

However, Polipo generates an Age header even for responses that were just obtained from the origin server, if the delays accumulate to at least 1 second. For example:

$ curl -si --proxy http://localhost:8123 httpbin.org/delay/5 | head
HTTP/1.1 200 OK
Content-Length: 262
Date: Sat, 30 Jan 2016 13:09:00 GMT
Via: 1.1 polipo
Server: nginx
Content-Type: application/json
Access-Control-Allow-Origin: *
Access-Control-Allow-Credentials: true
Age: 5
Connection: keep-alive

Fixing this would probably make the spurious Warning headers easy to fix as well.

vfaronov added a commit to vfaronov/httpolice that referenced this issue Apr 25, 2016
Polipo is wrong here, and it's not the only place where it is wrong
(jech/polipo#80).
Pandering to wrong implementations is counter to the idea.
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant