All Questions
32,396
questions
0
votes
1answer
87 views
How to send erc20 token with web3 without smart contract abi?
I created a token in the Ropsten network. It wants abi.json when transferring with Web3. But the token I created did not give it.
My token etherscan link https://ropsten.etherscan.io/address/...
0
votes
0answers
4 views
rafthttp: failed to find member 1 in cluster 1000 -quorum -raft consensus
Firstly, I have created a node in quorum private blockchain and initiated genesis to create blockchain using geth and bootnode . Then, I run the node and it is running blockchain. Later, I tried to ...
0
votes
1answer
17 views
hacked from metamask wallet
yesterday 2.3.2021 at 18:25 i was hacked. they stole all my founds from metamusk wallet from my address 0xeD14989682D3770AC0a9AEB2608Aa2315cF312Df and took everything to this address ...
0
votes
0answers
4 views
Why this delegatecall attack not working?
I am confused by this simple contract. The main purpose is to bypass the OnlyContract() modifier.
Victim contract.
pragma solidity 0.7.6;
contract Victim {
modifier OnlyContract() {
...
0
votes
0answers
5 views
How can I store structure items in a variable
I am learning to code in solidity and stuck with view functions.
I am trying to return values taken dynamically in a structure using view function. Is there a way to do it is solidity? I tried it but ...
1
vote
1answer
218 views
Concatenating byte strings in assembly for call input data
I have the following piece of code in my contract. It's supposed to take in a byte string composed of a uint flag that is followed by a variable list of uint numbers and contruct a call using those ...
2
votes
1answer
90 views
Simple mixer in ethereum
I have found this mixer proposal https://hackmd.io/@HWeNw8hNRimMm2m2GH56Cw/rJj9hEJTN?type=view
I'm is interested in this topic, but from my point of view with a current ethereum state it won't work. ...
15
votes
7answers
14k views
Is there any Ether mixer / tumbler available?
Quick checking around there are exactly two references to an Ether Mixer - this non functioning and here (r/ethereum) 24 days ago.
Unless I am missing something how can I hide the source of an ETH ...
1
vote
1answer
183 views
How to evaluate effectiveness of a Dapp
I am developing a private ethereum-based DApp and writing an academic paper for a final year project. I'm trying to "blockchainify" an existing system that adopts a traditional client-server approach.
...
0
votes
0answers
4 views
clone pancakeswap but it's show error Unhandled Rejection (Error)
I clone pancakeswap-frontend. when run I got above error. But I can't solve this problem.
Unhandled Rejection (Error): invalid address (argument="address", value=undefined, code=...
1
vote
1answer
215 views
INSUFFICIENT_OUTPUT_AMOUNT error when attempting Uniswap swap from a contract
While I'm able to successfully swap ETH for DAI, I'm running into an INSUFFICIENT_OUTPUT_AMOUNT error when trying to swap DAI for ETH using swapExactTokensForETH, even with amountOutMin set to 0. I ...
0
votes
1answer
1k views
read error unexpected EOF
I'm working a evidence application with quorum.I want to store the entire contents of a file on my private blockchain. Although it's not recommended. At first I use a linux command 'split' cut a big ...
0
votes
1answer
11 views
TransactionException: Cannot unmarshal invalid hex string when deploying contract in web3j
I have a java server that uses web3j library with geth as the provider. When I tried to deploy my contract on my private test net. I got this error:
org.web3j.protocol.exceptions.TransactionException: ...
0
votes
1answer
59 views
Could not deploy contract through sendTransaction
I am trying to deploy contract (available at Etherscan.io ). I proceed following steps:
copy its contract creation code and save them in crCode variable. Then i tried to to run following code;
async ...
1
vote
1answer
33 views
How to find out the IP address of a MetaMask wallet's owner?
If an Ethereum wallet address was created using MetaMask, can the IP address of the wallet's owner be logged or uncovered somehow?
If we can't find out the IP address, does the company running ...
0
votes
3answers
758 views
How to get all ethereum addresses?
I am going to get all ehtereum wallet addresses with positive balance.
I tried to get addresses with a method to get transaction.
I have got transaction from blocknumber(0~ Inf).
Using web3 and ...
0
votes
0answers
7 views
What's the difference between Binance ERC20 and Coinbase ERC20 …?
As a newbie I made a mistake whilst transferring btc to from Binance and Coinbase. My mistake was I didn't check the receive address with Coinbase and it defaults to eth and I wanted to send btc to ...
1
vote
1answer
71 views
Transferring files over blockchain from ropsten-test network
I am new to blockchain and working on a university project. I am trying to simply buy and sell music over the blockchain. Currently I am using a string to act as the 'transaction', but learnt this ...
0
votes
1answer
345 views
Web3.js event.get not firing, whereas event.watch gives correct values
I am trying to do a simple test for events.
Following is solidity code.
Values received from chgEvent.watch are always correct.
But in chgEvent.get, results1 is empty. chgEvent.get does not get ...
0
votes
0answers
9 views
How much liquidity to provide to Uniswap?
So you deployed your brand new ERC20 token to Uniswap. I understand you need to provide liquidity for your token pair in Uniswap so people can start buying your token. Now, what I'm trying to wrap my ...
0
votes
2answers
223 views
Web wallet best practices
I'm putting together an ether/erc20 token wallet in a chrome extension but would like to follow best practices with regards to private key security.
I'm using localstorage to handle login and its ...
1
vote
1answer
34 views
Why does this contract cost 1 Eth to deploy?
Truffle is telling me that it costs 1 Eth to deploy. Is that seriously the cost of deploying a simple contract (this is my first Mainnet deploy)? Or is there something else going on?
mainnet: {
...
0
votes
0answers
7 views
How to instantiate a memory-struct and assign it to a storage
I'm trying to understand the following code from the Solidity documentation:
struct Funder {
address addr;
uint amount;
}
contract Crowdfunding {
struct Campaign {
address payable ...
2
votes
2answers
2k views
Transaction dropped and replaced but still shows as pending in etherscan
I canceled a transaction by sending another 0 ETH transaction to myself customizing the nonce in Metamask. Now the canceled transaction shows as "dropped & replaced" in etherscan, but it'...
0
votes
2answers
93 views
Uniswap V2 Router, Factory on Rinkeby testnet
Is it possible to use Uniswap V2 router on rinkeby? What is the contract address of a router? i found only factory contract address ?
0
votes
0answers
6 views
Estimating gas limit using Go-ethereum BoundContract (abigen)
I have a smart contract and it's native bindings generated in go-ethereum (version 1.9.11 if that matters) abigen. Im looking for a way to estimate gas limit before calling method on smart contract.
I ...
1
vote
0answers
11 views
How can i get peers on my ethereum light node?
I'm running a light node on a DigitalOcean VPS in order to use it to query data on the ethereum blockchain, but suddenly it stopped answering to any of my requests and i noticed that i always have 0 ...
2
votes
1answer
23 views
Cannot verify Contract - bytecode has small difference
I forgot to verify the ERC20 token contract after deploying it. Now after 5 months, Im doing it again and completely forget which compiler and if I accidently change anything on the code.
After ...
0
votes
3answers
857 views
Deploy the ethereum contract token and transfer to other address using node js web3
Deploy the ethereum contract token and transfer token from one address to other address using node js web3.Anyone please help me.
23
votes
7answers
34k views
Deploy contract from NodeJS using web3
I'm trying to create and deploy a smart contract through NodeJS using web3, but it is not working as I get a "web3.eth.contract.new is not a function". Here is my code:
var web3 = require('ethereum....
0
votes
0answers
10 views
erc20 staking analytics
I am trying to analyze if/how staking affects the price of an ERC-20. Is there a way to find the total number of a specific ERC20 token staked each day? Does the transaction hash or input provide any ...
1
vote
0answers
22 views
Why is storage cheaper than a memory?
Let's consider the following completely useless code (tested in Remix):
// solium-disable linebreak-style
pragma solidity ^0.8.0;
contract MyContract
{
struct TestVars
{
uint8 a;
...
0
votes
1answer
112 views
Added EOS to MyEtherWwallet as default token
I've added EOS to MyEtherWallet as default token. How do I correct this? It tells me to load tokens but it isn't in the list. The contract is fine and tokens are present, just elusive and misnamed.
0
votes
0answers
7 views
VM Exception while processing transaction - Solved but don't know how
EDIT: I restarted truffle and migrated the contracts once again, and it worked without any errors. But, I don't know how and would love to understand this.
Explanation -
Owner creates an item, which ...
0
votes
0answers
7 views
IPC Connection not work on Node.js (web3)
I have a geth node launch on linux, I want to access it through the IPC connection in a Node.js application.
I am getting this error :
/home/**/node_modules/web3-core-helpers/lib/errors.js:66
...
4
votes
3answers
7k views
Where does metamask store the wallet seed? (file path)
I have a Windows installation that cannot be booted anymore.
I'd like to copy the file containing the Metamask wallet seed to another machine and have that Metamask installation use it.
The same ...
2
votes
1answer
382 views
remix: The method debug_traceTransaction does not exist/is not available
I have followed this answer.
So, you just need to add the --rpcapi "eth,net,web3,debug" command
line option.
The way I run my geth:
geth --datadir /home/user/POA/private --rpcaddr 127.0.0.1 --...
1
vote
2answers
282 views
Can we assume that Ethereum Events (aka Logs) are in-sequence
Lets consider a simple Contract that is to track a variable. A client App needs to access this variable's history to show a graph.
I can create an Array inside the Contract, and push() the value ...
6
votes
2answers
2k views
How to check if a bytes32 represents an empty string?
Why does the require not throw here when I am passing an empty string for the _name param?
function MyContract(bytes32 _name) public {
require(_name.length > 0);
name = _name;
}...
2
votes
1answer
257 views
Reliable way of listening to events on frontend
I make a web application, that needs the events from my contract to initialize it's state. I was using infura websocket provider, but it seems to lag a lot and close the connections unexpectedly ...
0
votes
2answers
46 views
Web3 how to send ether from client Metamask to contract address native receive function?
I wonder how can I natively pop-up the MetaMask window to send specific amount of ether as a donation to already defined SC address and ABI?
Short code intro:
pragma solidity >=0.7.0 <0.8.6;
[......
0
votes
1answer
129 views
How to create contract in geth private blockchain network?
I am able to publish my contract in testrpc , but when i am trying to publish same contract in geth, i am getting below error:
creation of lease errored: Gas required exceeds limit: 3000000. An ...
1
vote
4answers
537 views
Contract methods calls return empty array
I'm quite stuck with this issue. It seems like it must work, but it doesn't :D
Have a contract on rinkeby network which is working perfectly through remix(load by address) and truffle console. ...
0
votes
1answer
17 views
Assertion Error
Solidity file
pragma solidity ^0.5.0;
contract Todo {
struct User {
uint id;
string name;
}
User[] public users;
uint public nextId = 1;
function create(string memory name) public ...
1
vote
0answers
15 views
Event Ordering in Ethereum
I am developing an application using solidity, web3js and eventeum. I am testing it locally using ganache-cli. I use Kafka to store all the events to process them at convenience instead of processing ...
0
votes
3answers
181 views
Infinite gas estimate for almost all the functions. Is it normal?
When I deploy contract test net, it shows an error that gas limit exceeds: 3000000 What's the solution?
Github Link to the smart contract.
And is it normal to have the infinite gas estimate of ...
0
votes
1answer
25 views
Is ownership of tokenized real assets through NFT upheld by law?
Let's say you've tokenized your house as a non-fungible token (NFT) on the Ethereum blockchain.
if an NFT simply represents ownership of a tokenized asset, what actors or agencies currently will ...
0
votes
1answer
262 views
geth: Remove command from console
I'm trying to implement my own version of a SmartContract-driven Discover protocol and in order to get it fully working, I want to remove the admin.addPeer() command from the console.
I know there's ...
0
votes
2answers
118 views
i want to get data from the transaction hash i tried many codes at last i am getting boxes in the output
1) First, I got the input
console.log(web3.eth.getTransaction('0x725fc75264726f409793164e336e7d5ed35df8d2be469a0cc1a3a8cc4756b9b9').then((i) => console.log(i) ));
2) I manually pasted the input ...
1
vote
0answers
34 views
Chainlink - on-chain contract functioning
The on-chain aggregation smart contract for ETH/USD on the mainnet (https://data.chain.link/eth-usd) is at this address https://etherscan.io/address/0x5f4eC3Df9cbd43714FE2740f5E3616155c5b8419#code.
If ...