Solo para leer y verificar. No puedes copiar, usar, modificar ni redistribuir este código. Aviso completo en la página principal.
contracts/schemas/node-assertion-claims.schema.json
| 1 | { |
| 2 | "$schema": "https://json-schema.org/draft/2020-12/schema", |
| 3 | "$id": "https://all-mcp.fyi/contracts/v2/node-assertion-claims.schema.json", |
| 4 | "title": "Claims of the node's assertion (header x-all-node-assertion, JWS typ node-assertion, kid of the node's own Ed25519 key). It authenticates one request of a node to /v1/tunnel/*: bound to the method, the URL and the SHA-256 of the exact body bytes, 60 s, one use (jti). bh of an empty body is the hash of the empty string. sub is the node id that the registered key belongs to. Unknown extra claims are ignored (a token is not a closed shape), the listed ones are not optional unless the schema says so.", |
| 5 | "type": "object", |
| 6 | "required": ["typ", "ver", "sub", "aud", "htm", "htu", "iat", "exp", "jti", "bh"], |
| 7 | "properties": { |
| 8 | "typ": {"const": "node-assertion"}, |
| 9 | "ver": {"const": 1}, |
| 10 | "sub": {"$ref": "common.schema.json#/$defs/node_id"}, |
| 11 | "aud": {"const": "all-tunnel-control"}, |
| 12 | "htm": {"type": "string", "enum": ["GET", "POST"]}, |
| 13 | "htu": { |
| 14 | "type": "string", |
| 15 | "maxLength": 2048, |
| 16 | "pattern": "^https://[a-z0-9.-]{1,253}(?::[0-9]{1,5})?/v1/tunnel/[a-z]{1,32}(?:\\?[A-Za-z0-9=&_-]{0,64})?$" |
| 17 | }, |
| 18 | "iat": {"$ref": "common.schema.json#/$defs/epoch_s"}, |
| 19 | "exp": {"$ref": "common.schema.json#/$defs/epoch_s"}, |
| 20 | "jti": {"$ref": "common.schema.json#/$defs/jti"}, |
| 21 | "bh": {"$ref": "common.schema.json#/$defs/sha256_b64url"} |
| 22 | } |
| 23 | } |