Skip to content

Commit f314d36

Browse files
committed
Add a bit more about target attribute authority
While "targetSchema" is technically never required to process a response, as the response should indicate its own schema, other target attributes in the LDO, such as the submission schema, cannot be conveyed in any way other than through the LDO. It would seem like we need a provision for determining when the LDO can be constructed, but it's not entirely clear how that should work. Put in a bit about it and a CREF to hopefully attract the attention of someone who can improve the section.
1 parent c0373a3 commit f314d36

File tree

1 file changed

+12
-1
lines changed

1 file changed

+12
-1
lines changed

jsonschema-hyperschema.xml

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2394,7 +2394,18 @@ Link: <https://api.example.com/trees/1/nodes/456> rev=up
23942394
As stated in <xref target="targetAttributes"/>, all LDO keywords describing
23952395
the target resource are advisory and MUST NOT be used in place of
23962396
the authoritative information supplied by the target resource in response
2397-
to an operation.
2397+
to an operation. Target resource responses SHOULD indicate their own
2398+
hyper-schema, which is authoritative.
2399+
</t>
2400+
<t>
2401+
If the hyper-schema in the target response matches (by "$id") the hyper-schema
2402+
in which the current LDO was found, then the target attributes MAY be
2403+
considered authoritative.
2404+
<cref>
2405+
Need to add something about the risks of spoofing by "$id", but given
2406+
that other parts of the specification discourage always re-downloading
2407+
the linked schema, the risk mitigation options are unclear.
2408+
</cref>
23982409
</t>
23992410
<t>
24002411
Clients MUST NOT use the value of "targetSchema" to aid in the interpretation

0 commit comments

Comments
 (0)