I was running a node on my vps and my coinbase account was hacked. could anyone tell me what would be the default command to start geth on port 8545. Thank you
1 Answer
Do not unlock account on rpc provider node. If you are mining from same node, use separate nodes for mining and rpc. Connect them as peers and they will be safe from such attacks.
How to secure a private chain?
You can run geth on default setting provided you follow the secure procedures.
-
geth --rpc --rpcaddr ('my ip') --rpcport 8545 --rpccorsdomain "*" --rpcapi "admin,db,eth,debug,miner,net,shh,txpool,personal,web3" this should be ok? Thank you– john3meCommented Jun 8, 2018 at 16:36
-
I am trying to launch a smart contract but when i did it last time i unlocked my coinbase account maybe for a few seconds and i got hacked. Maybe i did something wrong last time.– john3meCommented Jun 8, 2018 at 16:37
-
be aware of the apis you are providing. I don't think all of these apis "admin,db,eth,debug,miner,net,shh,txpool,personal,web3" are necessary. It depends on your task but most of the time "eth,net,web3" are sufficient and secure.– biplavoCommented Jun 8, 2018 at 16:42
-
-
Yes. You can also try changing default settings such as port numbers. But it does not absolutely secure your rpc.– biplavoCommented Jun 8, 2018 at 16:48