Expand description
Transport authentication helpers.
The TCP and HTTP transports are network-exposed and, unlike the stdio
transport, are not implicitly trusted. When an auth token is configured,
every TCP connection and HTTP /rpc request must present it.
Functionsยง
- constant_
time_ eq - Constant-time byte comparison to avoid leaking the token via timing.
- is_
loopback_ host - True if
hostrefers to a loopback interface (orlocalhost). - verify_
token - Verify a presented token against the configured secret in constant time.