utreexo / utreexod

A fully validating Bitcoin node with Utreexo support
ISC License
86 stars 19 forks source link

Protocol negotiation failed during connection #185

Open yyforyongyu opened 1 month ago

yyforyongyu commented 1 month ago

It looks like a CSN cannot connect to a bridge node in regtest environment, and the negotiation fails at due to this wanted service, https://github.com/utreexo/utreexod/blob/593dd81ed692b92d8de55bdf98efd0b9dca35bac/server.go#L466

Steps to Reproduce

Run a mining node, which is also a bridge node,

./utreexod --debuglevel=debug --regtest --rpcuser=yy --rpcpass=yy --miningaddr=bcrt1pnmrmugapastum8ztvgwcn8hvq2avmcwh2j4ssru7rtyygkpqq98q4wyd6s --rpclisten=127.0.0.1:18335 --listen=127.0.0.1:28335 --utreexoproofindex --nobanning

Run a utreexo node,

./utreexod --debuglevel=debug --regtest --rpcuser=yy --rpcpass=yy --rpclisten=127.0.0.1:18334 --listen=127.0.0.1:28334 --nobanning

Connect the utreexo node to the bridge,

./utreexoctl --regtest --rpcserver=127.0.0.1:18335 --rpcpass=yy --rpcuser=yy addnode "127.0.0.1:28334" add

Got the following error log,

2024-05-19 08:59:25.797 [DBG] SRVR: Rejecting peer 127.0.0.1:28334 (outbound) with services SFNodeNetworkLimited|SFNodeBloom|SFNodeWitness|SFNodeUtreexo due to not providing desired services SFNodeNetwork
2024-05-19 08:59:25.797 [DBG] PEER: Sending reject (cmd version, code REJECT_NONSTANDARD, reason required services 0x1 not offered) to 127.0.0.1:28334 (outbound)