Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add HTTP Gateway Specs #283

Merged
merged 26 commits into from Jul 1, 2022
Merged
Changes from 1 commit
Commits
Show all changes
26 commits
Select commit Hold shift + click to select a range
a28d1de
feat: initial HTTP gateway specs
lidel Jun 2, 2022
6e24eb0
gateway: add Content-Range
lidel Jun 3, 2022
2e4374f
gateway: registerProtocolHandler uri router
lidel Jun 3, 2022
101fa5e
CODEOWNERS: add lidel for ./http-gateways
lidel Jun 3, 2022
7be0611
gateway: resolving an advanced DNSLink chain
lidel Jun 8, 2022
6a0e2fc
gateway: only-if-cached HEAD behavior
lidel Jun 8, 2022
13f53a8
gateway: suggestions from reviewers
lidel Jun 8, 2022
a414411
gateway: include CIDv1 node in summary
lidel Jun 8, 2022
af0363e
gateway: reorder URI router section
lidel Jun 8, 2022
4156b43
gateway: add Denylists section
lidel Jun 8, 2022
5435910
gateway: switch only-if-cached miss to 412
lidel Jun 9, 2022
176133a
gateway: apply suggestions from review
lidel Jun 9, 2022
cad7046
gateway: apply suggestions from Cloudflare
lidel Jun 15, 2022
04111e6
gateway: add X-Content-Type-Options
lidel Jun 15, 2022
ce193e6
gateway: simplify dnslink summary
lidel Jun 23, 2022
ffe8af9
gateway: document 412 Precondition Failed
lidel Jun 23, 2022
7e65a76
gateway: link to ipld codecs explainer
lidel Jun 23, 2022
e3637e5
gateway: stub about handling traversal errors
lidel Jun 23, 2022
2c731d3
gateway: expand HTTP caching considerations
lidel Jun 23, 2022
6787fd8
gateway: editorial fixes
lidel Jun 23, 2022
25497a4
gateway: expand on Host header parsing
lidel Jun 23, 2022
4b57971
gateway: editorial fixes
lidel Jun 23, 2022
75543c3
gateway: X-Forwarded-Proto and X-Forwarded-Host
lidel Jun 24, 2022
849a7e3
gateway: editorial fixes
lidel Jun 24, 2022
e06249f
gateway: X-Trace-Id
lidel Jun 24, 2022
9fc9a9c
gateway: Generated HTML with directory index
lidel Jun 28, 2022
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
8 changes: 8 additions & 0 deletions http-gateways/PATH_GATEWAY.md
Expand Up @@ -72,6 +72,7 @@ where client prefers to perform all validation locally.
- [`X-Ipfs-Path` (response header)](#x-ipfs-path-response-header)
- [`X-Ipfs-Roots` (response header)](#x-ipfs-roots-response-header)
- [`X-Content-Type-Options` (response header)](#x-content-type-options-response-header)
- [`X-Trace-Id` (response header)](#x-trace-id-response-header)
- [Response Payload](#response-payload)
- [Appendix: notes for implementers](#appendix-notes-for-implementers)
- [Content resolution](#content-resolution)
Expand Down Expand Up @@ -563,6 +564,13 @@ Optional, present in certain response types:
non-executable binary response types are not used in `<script>` and `<style>`
HTML tags.

### `X-Trace-Id` (response header)

Optional. Implementations are free to use this header to return a globally
unique identifier to help in debugging errors and performance issues.

A good practice is to always return it with HTTP error [status codes](#response-status-codes) >=`400`.

lidel marked this conversation as resolved.
Show resolved Hide resolved
## Response Payload

Data sent with HTTP response depends on the type of requested IPFS resource:
Expand Down