Linked Questions
10 questions linked to/from Why does an empty message still invoke the code of the contract?
173
votes
10
answers
107k
views
What is an ABI and why is it needed to interact with contracts?
ABI is referenced in many places including the official Ethereum website. What is an ABI and why is it necessary to use?
12
votes
3
answers
7k
views
How does the EVM find the entry of a called function?
I read the source code of go-ethereum and confused about how does the EVM find the entry of a called function.
As the specification said, the data field in a transaction specifies the function and the ...
19
votes
1
answer
4k
views
How much computation can be done in a fallback function?
Simply sending Ether to a contract, will run the contract's code. In Solidity, this code maps to what it calls the fallback function.
How much work can be done in a fallback function?
7
votes
1
answer
3k
views
When does the fallback function get called?
Is it true to say that if the first four bytes of an Ethereum's transaction does not contain one of the contract's encoded function calls, then the fallback function will be called?
In other words if ...
14
votes
1
answer
2k
views
What does `call.value` mean and how did it allow the attack to The DAO?
I'm trying to get some sense from the hysteria around the attack performed to The DAO smart contract.
I understand the high level explanations, but I'd like to grasp how this attack was performed.
I'...
7
votes
2
answers
2k
views
How was the recursion created that lead to theDAO hack?
I understand that if theDAO contract has a withdrawal function that sends money to contract X - contract X can be malicious and use the fallback function to call the withdrawal function again. However ...
6
votes
1
answer
2k
views
How does a Solidity fallback function work with the raw CALL opcode of the EVM?
Since a fallback function is a Solidity feature, how does it work if the EVM opcode CALL is used?
If msg.data is empty, how can Solidity run the fallback function? Shouldn't the EVM just transfer ...
8
votes
1
answer
2k
views
How does a fallback function rejecting ether work?
A contract in Solidity can have a fallback function like:
// This contract rejects any Ether sent to it. It is good
// practise to include such a function for every contract
// in order not to loose ...
1
vote
1
answer
899
views
Can i write in the data field of a transaction?
I read here Is it possible to insert some custom data in the DATA field of an Ethereum Transaction? that it is not possible to write in the data field of a transaction, even if it is a simple balance ...
1
vote
1
answer
122
views
How do I send funds from a contract to an account using bytecode?
The instruction CREATE will send funds to a new account. Is there another instruction for sending funds to an account that already exists? Or I just have to use CREATE as if the account doesn't exist?