This question already has an answer here:
- Explanation of Parity Library Suicide 2 answers
In recent news about the potential loss of 300M USD.
Could someone please explain how it is possible to "kill" a number multi-sig wallets by removing code?
As a programmer I fail to understand how fixing buggy code or even deleting code can affect peoples cryptocurrency wallets? This is particularly cumbersome to understand as the Ethereum is supposed to be a decentralized platform. Isn't that the whole point, that it should protect the system from simple hacks (or programmer "errors")?
Realizing I am not familiar with the jargon in the context of cryptocurrency development programming, I suppose the question may be simplified by instead explaining how the programming code is kept separate from the wallet contents (the addresses affected). How can a program change, affect some random account address? (Are you not testing development code on a non-production system?)
In trying to better grasp whats going on, I read the following that may prove more helpful to others.
With Ethereum, every time a program is used, a network of thousands of computers processes it. Contracts written in a smart contract-specific programming languages are compiled into 'bytecode', which a feature called the
ethereum virtual machine(EVM) can read and execute. All the nodes execute this contract using their EVMs.
Bitcoin miners validate the shift of ownership of bitcoins from one person to another. The EVM executes a contract with whatever rules the developer initially programmed. Actual computation on the EVM is achieved through a stack-based bytecode language (the ones and zeroes that a machine can read), but developers can write smart contracts in high-level languages such as Solidity and Serpent that are easier for humans to read and write.
This is also explained fairly well here:
From a practical standpoint, the EVM can be thought of as a large decentralized computer containing millions of objects, called "accounts", which have the ability to maintain an internal database, execute code and talk to each other.
There are two types of accounts:
- Externally Owned Account (EOA): an account controlled by a private key, and if you own the private key associated with the EOA you have the ability to send ether and messages from it.
- Contract: an account that has its own code, and is controlled by code.
By default, the Ethereum execution environment is lifeless; nothing happens and the state of every account remains the same. However, any user can trigger an action by sending a transaction from an externally owned account, setting Ethereum's wheels in motion. If the destination of the transaction is another EOA, then the transaction may transfer some ether but otherwise does nothing. However, if the destination is a contract, then the contract in turn activates, and automatically runs its code.