Skip to content

zaino serve gRPC: bind loopback, not 0.0.0.0 - #56

Open
Giri-Aayush wants to merge 1 commit into
ShieldedLabs:mainfrom
Giri-Aayush:fix/grpc-loopback
Open

zaino serve gRPC: bind loopback, not 0.0.0.0#56
Giri-Aayush wants to merge 1 commit into
ShieldedLabs:mainfrom
Giri-Aayush:fix/grpc-loopback

Conversation

@Giri-Aayush

@Giri-Aayush Giri-Aayush commented Aug 10, 2026

Copy link
Copy Markdown

Found this while auditing which ports a faucet node exposes.

How we found it

Listed the listeners on the box and spotted *:29234 (the zaino serve gRPC, at P+10001) bound to 0.0.0.0, while the JSON-RPC one line above it in the source binds 127.0.0.1. That mismatch is the tell.

The reason it matters: that gRPC serves RequestFaucetDonation, which pays straight out of the mining wallet and skips any operator-side rate limiting. So an all-interfaces bind on that port is a direct wallet-drain path the moment a firewall slips. Right now only ufw is standing in front of it.

Went looking for a config knob to move it to loopback and there isn't one, the address is hardcoded in start.rs. So this is the one-line fix: make the gRPC bind match the JSON-RPC and sit on loopback.

Testing

Deployed on a live feature-net node. ss -lntp now shows 127.0.0.1:29234 and the node runs normally.

The embedded zaino serves its gRPC on 0.0.0.0:P+10001 while the JSON-RPC one
line above binds 127.0.0.1. On a faucet node that gRPC serves
RequestFaucetDonation, a direct path to the mining wallet that bypasses any
operator-side rate limiting, so exposing it on all interfaces is a
wallet-drain risk that only a firewall stands in front of. There is no config
knob for the bind, so this is the one-line fix: match the JSON-RPC and bind
loopback.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant