//! echo-border-control — a tiny CLI wrapper around the deterministic verifier.
//!
//! Reads one JSON document on stdin of the form:
//! { "authority": {...}, "invocation": {...}, "state": {...} }
//! and prints the verdict as JSON:
//! { "decision": "ALLOW" | "DENY", "reason": "OK" | ..., "receipt": "<hex>" | null }
//!
//! Exit code is 0 on ALLOW, 1 on DENY, 2 on malformed input — so it composes in a shell:
//! cat request.json | echo-border-control && do_the_thing
//!
//! It calls `echo_authority_core::evaluate_json`, the exact same entry point the WebAssembly
//! build exposes to the browser. CLI, browser, and any embedder run identical logic.
use evaluate_json;
use Read;