|
1540 | 1540 | </t>
|
1541 | 1541 | </section>
|
1542 | 1542 |
|
| 1543 | + <section title="References to Possible Non-Schemas"> |
| 1544 | + <t> |
| 1545 | + Subschema objects (or booleans) are recognized by their use with known |
| 1546 | + applicator keywords. These keywords may be the standard applicators |
| 1547 | + from this document, or extension keywords from a known vocabulary, or |
| 1548 | + implementation-specific custom keywords. |
| 1549 | + </t> |
| 1550 | + <t> |
| 1551 | + Multi-level structures of unknown keywords are capable of introducing |
| 1552 | + nested subschemas, which would be subject to the processing rules for |
| 1553 | + "$id". Therefore, having a reference target in such an unrecognized |
| 1554 | + structure cannot be reliably implemented, and the resulting behavior |
| 1555 | + is undefined. Similarly, a reference target under a known keyword, |
| 1556 | + for which the value is known not to be a schema, results in undefined |
| 1557 | + behavior in order to avoid burdening implementations with the need |
| 1558 | + to detect such targets. |
| 1559 | + <cref> |
| 1560 | + These scenarios are analogous to fetching a schema over HTTP |
| 1561 | + but receiving a response with a Content-Type other than |
| 1562 | + application/schema+json. An implementation can certainly |
| 1563 | + try to interpret it as a schema, but the origin server |
| 1564 | + offered no guarantee that it actually is any such thing. |
| 1565 | + Therefore, interpreting it as such has security implications |
| 1566 | + and may produce unpredictable results. |
| 1567 | + </cref> |
| 1568 | + </t> |
| 1569 | + <t> |
| 1570 | + Note that single-level custom keywords with identical syntax and |
| 1571 | + semantics to "$defs" do not allow for any intervening "$id" keywords, |
| 1572 | + and therefore will behave correctly under implementations that attempt |
| 1573 | + to use any reference target as a schema. However, this behavior is |
| 1574 | + implementation-specific and MUST NOT be relied upon for interoperability. |
| 1575 | + </t> |
| 1576 | + </section> |
| 1577 | + |
1543 | 1578 | <section title="Loading a referenced schema">
|
1544 | 1579 | <t>
|
1545 | 1580 | The use of URIs to identify remote schemas does not necessarily mean anything is downloaded,
|
|
0 commit comments