bitcoinknots / bitcoin

Bitcoin Knots enhanced Bitcoin node/wallet software
MIT License
199 stars 60 forks source link

Broadcast a transaction to specific nodes #50

Open ghost opened 1 year ago

ghost commented 1 year ago

Is your feature request related to a problem? Please describe.

It would be great if users could select a node for broadcasting transaction instead of all nodes. Recently @openoms wanted to do this : https://twitter.com/openoms/status/1573594264730312704

Describe the solution you'd like

A parameter in sendrawtransaction that could be used to select node with node id.

Describe alternatives you've considered

libbtc library: https://twitter.com/1440000bytes/status/1574225052240777216

Additional context

This would improve privacy and requires a new function in src\net_processing.cpp similar to RelayTransaction() or add some lines in the same function.

MoneroArbo commented 1 year ago

I would use something like this to broadcast over tor / i2p while also connected to clearnet nodes, but it would be even more useful if I could set some sort of default instead of having to call sendrawtransaction each time.

Something like broadcast=i2p in the config file.