Cache-Control headers for mutable resources are wrong
Closed this issue · 1 comments
2color commented
Summary
When requesting resources with the ipns://
prefix, verifiedFetch returns the wrong Cache-Control
header (specifically 'public, max-age=29030400, immutable'
) in the response object according to the specs.
This happens for both IPNS names and DNSLink
Suggestion
Set the Cache-Control
headers according to the specs.
SgtPooki commented
we should also update https://github.com/ipfs/helia-verified-fetch/blob/4e6775cc8978e34fd9fa3b58a7bef90d64419906/packages/verified-fetch/src/utils/parse-url-string.ts#L113C31-L117
we will likely be updating resolveDNSLink
to return TTL in addition to the string
related: ipfs/boxo#329 (comment)