Skip to main content

All Questions

Filter by
Sorted by
Tagged with
0 votes
0 answers
97 views

Recreate transaction log in solidity code

I have this log and i want to code a solidity contract/function that would do the same. What i understand reading this transaction is that WBNB contract (0xbb4cdb9cbd36b01bd1cbaebf2de08d9173bc095c) is ...
Rémi Baldy's user avatar
3 votes
1 answer
2k views

Find a Function Call Across All Contract Transactions

Is it possible to search for a particular function call across all transactions of a smart contract? I'm doing due diligence on 1inch's smart contract in order to see if renounceOwnership was called ...
AdamHurwitz's user avatar
3 votes
1 answer
532 views

When a contract calls other contracts, is it an atomic operation?

If a contract calls several external methods of other contract(s), is it as a whole one atomic transaction (reverted as a whole if an exception happens)?
porton's user avatar
  • 1,854
1 vote
1 answer
205 views

Can you activate Contract Functions just by receiving Ether alone?

Noob Question here. I have a Dapp that has no actual need of a web interface. What is the best way to activate functions if someone did something as simple as send Ether to an address it controls from ...
Redundant Design's user avatar
1 vote
1 answer
184 views

getEthToTokenInputPrice miner hack?

Plan to use getEthToTokenInputPrice in a Dapp. I was going to just use a larger sample size spread out over a large time period to mitigate flash loan price manipulation. Someone said this was ...
Redundant Design's user avatar
5 votes
2 answers
2k views

Who is msg.sender in a nested call chain?

I read about who is msg.sender when calling a contract from a contract, but who is msg.sender when calling a contract from a contract that calls another contract and so on and so forth?
Paul Razvan Berg's user avatar
1 vote
1 answer
113 views

Where is the position of each paramter in a smart contract function when encoded as inputdata in a transaction

When I reviewed the BEC attack, I found the position of each parameters value in real transaction was not corresponding in to definition of function in smart contract. The exploit transaction is at: ...
Jocelyn's user avatar
  • 71
0 votes
0 answers
43 views

How do i get to return value form one smart contract function into another smart contract on private ethereum network?

Here it is my called function. pragma solidity ^0.4.19; contract Called{ string public name; function set(string _var) { name = _var; } function get() view returns (...
Anand Kumar's user avatar
12 votes
2 answers
7k views

Does view functions cost gas? And how to send transaction in a proper way?

I have a method defined as: getNames() view public , if i call on it contractInstance.getNames.estimatedGas() it returns me a non-zero value, why? I mean, view methods should not consume any gas! On ...
rollotommasi's user avatar
1 vote
0 answers
524 views

How to get transaction hash at time of invoking function?

I have a function as follows: function setEnergy(address dev, uint256 energy) public returns (bool) { require(dev != address(0)); amount[dev].energyValue = amount[dev].energyValue + energy; ...
Questioner's user avatar
  • 2,700
0 votes
1 answer
148 views

Need Solidity software for smart contract, for Multiple Token dispatch [duplicate]

Please I need to distribute tokens to at least 1,500 wallets and can't go through the stress of sending them one by one. What I need is a smart contract to enable multiple dispatches to several ...
solomonsojay's user avatar
2 votes
2 answers
900 views

How do I deploy a contract, then send and retrieve a string from it?

I wish to store strings on-chain. From what I understand so far, I need to set up a contract, then I can send transactions (with a string) to that contract which will be stored. Is this the best way ...
joe's user avatar
  • 269
3 votes
1 answer
275 views

How can I set the gas price of a transaction initiated by a contract?

I am writing a contract that will interact with another contract: contract A will call a function defined by contract B. Is it possible to set the gas price that contract A is willing to pay when ...
troyth's user avatar
  • 63
1 vote
1 answer
126 views

How to be notified with bad transactions when sending to a JSON-RPC server?

With Ubuntu, I've tried Wallet/Mist and MetaMask on Ropsten testnet: they both notify me with bad transactions before inputting my password. I've tried to do the same thing with a JSON-RPC server, in ...
Vincent J. Ruan's user avatar
1 vote
0 answers
115 views

Implementing a reinforced invoice?

I have a question. My contract structure involves 2 user at address A and B respectively: First A trigger the logging method from the contract with B's address as parameter. This will record a ...
lab's user avatar
  • 11
5 votes
2 answers
905 views

return (bytes32,bytes32) , returns actual transaction address instead of the real data

I have attached my contract, which works fine on populus and compiles on geth. It is a simple source code: Test() function appends data into my linkedlist that is defined in my library. And get() ...
alper's user avatar
  • 8,404
4 votes
1 answer
936 views

When a contract calls another contracts, can it return values?

When a contract calls another contract, are values returned ? I've seen things like: function foo() external returns (bool success) { if( ... ) throw; return true; } But have read that calls ...
vera34's user avatar
  • 157
8 votes
3 answers
4k views

Reading values from a contract: When do I need transactions?

Since reading on the Blockchain does not need performance of other nodes, I wonder how I can get values from a Smart Contract without any transactions. I have created a little example contract: ...
Ba5t14n's user avatar
  • 213