This is a question that I am asked often by developers who assume that a contract has a private key of its own to sign any transactions that it makes.
Ethereum Stack Exchange is a question and answer site for users of Ethereum, the crypto value and blockchain-based consensus network. It's 100% free, no registration required.
Sign up
Sign up
Here's how it works:
- Anybody can ask a question
- Anybody can answer
- The best answers are voted up and rise to the top
|
Contracts do not possess private keys in the same way that your ether wallet does. Instead, they have programming code written in the language of the Ethereum Virtual Machine. To determine what a contract "does", all members of the Ethereum network simply run the relevant portion of code every time a transaction or other contract uses the contract's function. Because the code and EVM are carefully defined, everyone will always agree on what the outcome of the operation was. This includes whether or not the contract sent a transaction to any other contract. Because everyone can agree on the origin of the message, no further degree of verification (such as that provided by a signature) is necessary. |
|||
|
|