Skip to content

Commit 6d71cf0

Browse files
authored
Merge branch 'main' into ipns-v2-only
2 parents 47bbbfb + c3be8c1 commit 6d71cf0

File tree

7 files changed

+964
-43
lines changed

7 files changed

+964
-43
lines changed

IPIP/0000-template.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
Moved to [../ipip-template.md].
1+
Moved to [`../ipip-template.md`](../ipip-template.md).

ipip-template.md

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -36,13 +36,6 @@ interoperable implementations.
3636
When modifying an existing specification file, this section should provide a
3737
summary of changes. When adding new specification files, list all of them.
3838

39-
## Test fixtures
40-
41-
List relevant CIDs. Describe how implementations can use them to determine
42-
specification compliance. This section can be skipped if IPIP does not deal
43-
with the way IPFS handles content-addressed data, or the modified specification
44-
file already includes this information.
45-
4639
## Design rationale
4740

4841
The rationale fleshes out the specification by describing what motivated
@@ -67,6 +60,13 @@ Explain the security implications/considerations relevant to the proposed change
6760

6861
Describe alternate designs that were considered and related work.
6962

63+
## Test fixtures
64+
65+
List relevant CIDs. Describe how implementations can use them to determine
66+
specification compliance. This section can be skipped if IPIP does not deal
67+
with the way IPFS handles content-addressed data, or the modified specification
68+
file already includes this information.
69+
7070
### Copyright
7171

7272
Copyright and related rights waived via [CC0](https://creativecommons.org/publicdomain/zero/1.0/).

src/http-gateways/path-gateway.md

Lines changed: 22 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,9 @@ editors:
2121
url: https://hacdias.com/
2222
xref:
2323
- url
24+
- trustless-gateway
25+
- ipip-0402
26+
- ipip-0412
2427
tags: ['httpGateways', 'lowLevelHttpGateways']
2528
order: 0
2629
---
@@ -142,15 +145,22 @@ For example:
142145

143146
### `Range` (request header)
144147

145-
`Range` can be used for requesting specific byte ranges of UnixFS files and raw
148+
`Range` can be used for requesting specific byte range of UnixFS files and raw
146149
blocks.
147150

148151
Gateway implementations SHOULD be smart enough to require only the minimal DAG subset
149152
necessary for handling the range request.
150153

151-
NOTE: for more advanced use cases such as partial DAG/CAR streaming, or
152-
non-UnixFS data structures, see the `selector` query parameter
153-
[proposal](https://github.com/ipfs/go-ipfs/issues/8769).
154+
Gateways SHOULD support single range requests. The support of more than one
155+
range is optional: implementation MAY decide to not support more than one range.
156+
157+
:::note
158+
159+
For more advanced use cases such as partial DAG/CAR streaming, or non-UnixFS
160+
data structures, see `dag-scope` and `entity-bytes` from :cite[ipip-0402] and
161+
ordered CARs from :cite[ipip-0412].
162+
163+
:::
154164

155165
### `Service-Worker` (request header)
156166

@@ -214,11 +224,13 @@ These are the equivalents:
214224
- `format=cbor``Accept: application/cbor`
215225
- `format=ipns-record``Accept: application/vnd.ipfs.ipns-record`
216226

217-
<!-- TODO Planned: https://github.com/ipfs/go-ipfs/issues/8769
218-
- `selector=<cid>` can be used for passing a CID with [IPLD selector](https://ipld.io/specs/selectors)
219-
- Selector should be in dag-json or dag-cbor format
220-
- This is a powerful primitive that allows for fetching subsets of data in specific order, either as raw bytes, or a CAR stream. Think “HTTP range requests”, but for IPLD, and more powerful.
221-
-->
227+
### `dag-scope` (request query parameter)
228+
229+
Only used on CAR requests, same as :ref[dag-scope] from :cite[trustless-gateway].
230+
231+
### `entity-bytes` (request query parameter)
232+
233+
Only used on CAR requests, same as :ref[entity-bytes] from :cite[trustless-gateway].
222234

223235
# HTTP Response
224236

@@ -592,7 +604,7 @@ The following response types require an explicit opt-in, can only be requested w
592604
- Raw Block (`?format=raw`)
593605
- Opaque bytes, see [application/vnd.ipld.raw](https://www.iana.org/assignments/media-types/application/vnd.ipld.raw).
594606
- CAR (`?format=car`)
595-
- Arbitrary DAG as a verifiable CAR file or a stream, see [application/vnd.ipld.car](https://www.iana.org/assignments/media-types/application/vnd.ipld.car).
607+
- A CAR file or a stream that contains all blocks required to trustlessly verify the requested content path query, see [application/vnd.ipld.car](https://www.iana.org/assignments/media-types/application/vnd.ipld.car) and Section 5 (CAR Responses) at :cite[trustless-gateway].
596608
- TAR (`?format=tar`)
597609
- Deserialized UnixFS files and directories as a TAR file or a stream, see :cite[ipip-0288].
598610
- IPNS Record

0 commit comments

Comments
 (0)