1

I'm reading through the JSON RPC Doc now on Github here: https://github.com/ethereum/wiki/wiki/JSON-RPC#net_version

I assumed that this is the default communication protocol between any two nodes, and between a node and a client (such as web3).

But then it mentioned how to start geth and the c++ node in "RPC mode". So is RPC not the default communication mode?

  • If not, how else does node-to-node communication happen?
  • If so, what are use cases for starting a node NOT in rpc mode?
3

The connection between ethereum nodes is using the ÐΞVp2p Wire Protocol.

Disabling the RPC interface for your ethereum node is a security consideration, especially if you have an internet facing node. This case is just one of many cases where people had their ETH stolen through the RPC interface. The RPC interface is for user interaction, not for p2p.

1

I can partially answer, especially since you ask about c++ node and connecting to client.

When you start eth, the default communication with client (e.g., mist or geth console) is through ipc (inter-process communication), not rpc. To enable rpc you need to start eth with -j flag. By default rpc is disabled in cpp-ethereum node. I think its for security reasons.

Conections with other nodes is using p2p and boost/asio. I dont know too much about it, but i think its totally different type of communication than just rpc.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.