Solo para leer y verificar. No puedes copiar, usar, modificar ni redistribuir este código. Aviso completo en la página principal.
tunnel/policy.json
| 1 | { |
| 2 | "$comment": "ALL 2.0 policy table: the ONE place where a number, a window or a limit of the end-to-end path is written down (plan section 0 and 7.1). The tunnel node (Go), the control plane (TypeScript) and the device (Python) read it; nobody copies a value into code (the contract generator lint fails the suite when one does). Units are in the key suffix: _s seconds, _bytes, _days, _pct percent. Keys listed in `provisional` are the plan's initial values: they are retuned after G0 and G1 and ONLY here. This is the node projection (the `copies` of the contract lint table): only the sections that runtime reads.", |
| 3 | "version": 1, |
| 4 | "provisional": [ |
| 5 | "timing.stream_idle_s", |
| 6 | "timing.stream_max_age_s", |
| 7 | "timing.ping_interval_s", |
| 8 | "timing.dead_peer_s", |
| 9 | "node_limits.per_ip_concurrent", |
| 10 | "node_limits.per_ip_new_per_s", |
| 11 | "node_limits.label_streams_max", |
| 12 | "node_limits.label_anon_slice", |
| 13 | "node_limits.label_hint_slice", |
| 14 | "node_limits.global_streams_max", |
| 15 | "node_limits.openai_reserved_pct", |
| 16 | "node_limits.openai_per_ip_factor", |
| 17 | "node_limits.device_per_ip_factor", |
| 18 | "node_limits.ip_table_max", |
| 19 | "node_limits.unknown_sni_per_ip", |
| 20 | "node_limits.unknown_sni_window_s", |
| 21 | "node_limits.unknown_sni_ban_s", |
| 22 | "node_limits.label_new_per_s", |
| 23 | "node_limits.label_new_burst", |
| 24 | "node_limits.hint_addresses_per_label" |
| 25 | ], |
| 26 | "protocol": { |
| 27 | "version": 2, |
| 28 | "alpn": "all-tunnel/2", |
| 29 | "line_max_bytes": 8192, |
| 30 | "open_line_max_bytes": 192, |
| 31 | "statement_line_max_bytes": 65552, |
| 32 | "jwt_max_bytes": 4096, |
| 33 | "first_line_timeout_s": 10, |
| 34 | "attach_timeout_s": 10, |
| 35 | "stream_id_bytes": 16, |
| 36 | "attach_secret_bytes": 32, |
| 37 | "nonce_bytes": 16, |
| 38 | "hint_max_addresses": 16, |
| 39 | "proof_htm": "GET", |
| 40 | "proof_htu_path": "/all-tunnel/2", |
| 41 | "node_assertion_header": "x-all-node-assertion", |
| 42 | "source_classes": [ |
| 43 | "openai", |
| 44 | "hint", |
| 45 | "anon" |
| 46 | ], |
| 47 | "close_reasons": [ |
| 48 | "replaced", |
| 49 | "revoked", |
| 50 | "expired", |
| 51 | "released", |
| 52 | "killed", |
| 53 | "paused", |
| 54 | "drain", |
| 55 | "idle", |
| 56 | "protocol", |
| 57 | "shutdown" |
| 58 | ], |
| 59 | "error_codes": [ |
| 60 | "bad_hello", |
| 61 | "bad_command", |
| 62 | "unsupported_version", |
| 63 | "bad_proof", |
| 64 | "auth", |
| 65 | "clock_skew", |
| 66 | "unknown_stream", |
| 67 | "bad_attach", |
| 68 | "license_inactive", |
| 69 | "device_revoked", |
| 70 | "paused", |
| 71 | "busy", |
| 72 | "control_unavailable", |
| 73 | "line_too_long" |
| 74 | ] |
| 75 | }, |
| 76 | "timing": { |
| 77 | "ping_interval_s": 20, |
| 78 | "dead_peer_s": 45, |
| 79 | "stream_idle_s": 1800, |
| 80 | "stream_max_age_s": 14400, |
| 81 | "half_close_s": 30, |
| 82 | "backoff_min_s": 1, |
| 83 | "backoff_max_s": 60, |
| 84 | "renew_before_valid_until_s": 300, |
| 85 | "drain_quiet_s": 1200, |
| 86 | "feed_poll_s": 15, |
| 87 | "feed_apply_deadline_s": 20, |
| 88 | "reconnect_after_wake_s": 5 |
| 89 | }, |
| 90 | "authorization": { |
| 91 | "valid_until_paid_s": 14400, |
| 92 | "valid_until_trial_s": 900, |
| 93 | "valid_until_gated_s": 900, |
| 94 | "grace_paid_s": 900, |
| 95 | "authorize_max_concurrent": 50, |
| 96 | "session_ttl_s": 300, |
| 97 | "proof_ttl_s": 60, |
| 98 | "node_assertion_ttl_s": 60, |
| 99 | "node_skew_s": 5, |
| 100 | "node_skew_max_s": 30, |
| 101 | "access_ttl_paid_s": 14400, |
| 102 | "access_ttl_trial_s": 600, |
| 103 | "access_ttl_paywall_s": 600, |
| 104 | "access_future_slack_s": 60, |
| 105 | "stripe_status_cache_s": 120, |
| 106 | "last_seen_write_interval_s": 300 |
| 107 | }, |
| 108 | "gated": { |
| 109 | "bytes_per_day": 10485760, |
| 110 | "streams_per_day": 200 |
| 111 | }, |
| 112 | "identity": { |
| 113 | "issuer": "https://api.all-mcp.fyi", |
| 114 | "aud_tunnel": "all-tunnel", |
| 115 | "aud_access": "all-device-access", |
| 116 | "aud_node_assertion": "all-tunnel-control", |
| 117 | "label_length": 20, |
| 118 | "label_alphabet": "abcdefghijklmnopqrstuvwxyz234567", |
| 119 | "label_regex": "^[a-z2-7]{20}$", |
| 120 | "fqdn_regex": "^[a-z2-7]{20}\\.(?:[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?\\.)+[a-z]{2,63}$", |
| 121 | "fqdn_max_length": 253, |
| 122 | "tombstone_idle_months": 12, |
| 123 | "device_id_regex": "^[a-f0-9]{32}$", |
| 124 | "stream_id_regex": "^[0-9a-f]{32}$", |
| 125 | "attach_secret_regex": "^[A-Za-z0-9_-]{43}$", |
| 126 | "nonce_regex": "^[A-Za-z0-9_-]{22,64}$", |
| 127 | "jti_regex": "^[A-Za-z0-9_-]{16,128}$", |
| 128 | "kid_regex": "^[A-Za-z0-9._-]{1,128}$" |
| 129 | }, |
| 130 | "jwks": { |
| 131 | "cache_s": 300, |
| 132 | "max_keys": 16, |
| 133 | "stale_fail_closed_s": 1800 |
| 134 | }, |
| 135 | "node_limits": { |
| 136 | "client_hello_deadline_s": 5, |
| 137 | "per_ip_concurrent": 16, |
| 138 | "per_ip_new_per_s": 10, |
| 139 | "ipv6_prefix_bits": 64, |
| 140 | "label_streams_max": 64, |
| 141 | "label_anon_slice": 16, |
| 142 | "label_hint_slice": 48, |
| 143 | "hint_ttl_s": 900, |
| 144 | "global_streams_max": 2048, |
| 145 | "openai_reserved_pct": 25, |
| 146 | "openai_prefix_refresh_s": 86400, |
| 147 | "openai_prefix_max": 2048, |
| 148 | "openai_prefix_min_v4_bits": 16, |
| 149 | "openai_prefix_min_v6_bits": 32, |
| 150 | "openai_prefix_body_max_bytes": 1048576, |
| 151 | "openai_per_ip_factor": 8, |
| 152 | "device_per_ip_factor": 8, |
| 153 | "ip_table_max": 65536, |
| 154 | "unknown_sni_per_ip": 20, |
| 155 | "unknown_sni_window_s": 60, |
| 156 | "unknown_sni_ban_s": 600, |
| 157 | "label_new_per_s": 20, |
| 158 | "label_new_burst": 32, |
| 159 | "hint_addresses_per_label": 64, |
| 160 | "tcp_keepalive_s": 30, |
| 161 | "max_unauthenticated_control": 256 |
| 162 | }, |
| 163 | "enums": { |
| 164 | "authorize_status": [ |
| 165 | "active", |
| 166 | "gated", |
| 167 | "paused" |
| 168 | ], |
| 169 | "statement_mode": [ |
| 170 | "active", |
| 171 | "paywall" |
| 172 | ], |
| 173 | "budget_class": [ |
| 174 | "paid", |
| 175 | "trial", |
| 176 | "flex" |
| 177 | ], |
| 178 | "acme_purpose": [ |
| 179 | "first", |
| 180 | "renewal" |
| 181 | ], |
| 182 | "reserve_status": [ |
| 183 | "granted", |
| 184 | "deferred" |
| 185 | ], |
| 186 | "feed_event_type": [ |
| 187 | "revoke", |
| 188 | "pause", |
| 189 | "resume", |
| 190 | "license_end", |
| 191 | "release", |
| 192 | "kill", |
| 193 | "kill_clear" |
| 194 | ], |
| 195 | "e2e_state": [ |
| 196 | "off", |
| 197 | "unenrolled", |
| 198 | "waiting", |
| 199 | "issuing", |
| 200 | "connecting", |
| 201 | "ready", |
| 202 | "degraded", |
| 203 | "clock_skew", |
| 204 | "compat_only", |
| 205 | "killed" |
| 206 | ], |
| 207 | "e2e_cohort": [ |
| 208 | "paid", |
| 209 | "trial", |
| 210 | "flex", |
| 211 | "legacy" |
| 212 | ], |
| 213 | "ineligible_reason": [ |
| 214 | "update_not_in_plan", |
| 215 | "legacy_credential", |
| 216 | "unsupported_version" |
| 217 | ], |
| 218 | "selfcheck_reason": [ |
| 219 | "chain", |
| 220 | "expired", |
| 221 | "spki", |
| 222 | "name", |
| 223 | "tls_version", |
| 224 | "healthz", |
| 225 | "unreachable", |
| 226 | "timeout" |
| 227 | ] |
| 228 | } |
| 229 | } |