All Questions

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

Validate that an owner contract called another contract's function

I'm testing the challengeOpponent function in my Connect4 contract in remix. The function creates a new Escrow contract instance so that each player in the game has a place to hold their funds until ...
0
votes
1answer
8 views

Should i move my erc20 token from ropsten to main network?

I have just created token in ROPSTEN network, so Im confused now... Can I use my tokens in main ether network (sel, give, etc) or I just van play with them in test network and forget...? Should i ...
0
votes
0answers
12 views

Searching for a value in a dynamic array

I understand that for loops on dynamic arrays are a big no no in Solidity, so I am trying to find an alternative to this problem. Goal: From a dynamic array of numbers, I am trying to extract the ...
2
votes
0answers
13 views

Blocks can't contain more than 81 transactions

I'm building a private blockchain with Parity clients. For performance testing, I'm submitting many identical transactions. One of the nodes has a GPU miner attached. There are 2 issues I cannot ...
0
votes
0answers
8 views

Ethereum, the decentralized application platform and smart contract enabled blockchain?

I am trying to understand ethereum blockchain development process. I am using windows os. I want to code that in visual studio code IDE . 1. If someone can help me explaining how code flows and tools ...
0
votes
0answers
7 views

Deployed contract address is getting undefined after few days on private network

I have a private blockchain where I am able to deploy my smart contracts successfully and then I am getting the address of my smart contract which I am storing on my relational db. In geth console ...
0
votes
0answers
11 views

Geth Providing error on its directory path

I have initilize my node1 with my genesis file which worked fine command is 'geth --datadir node1/ init genesis.json'. But with same geth when I try to run this command geth --datadir node1/ --...
0
votes
1answer
16 views

MITM attack in hosted wallets

i have a question: in the web wallets(hosted wallets)when user want to make a transaction and send the information to the wallet server , can a one change the information(man in the middle attack)?
0
votes
1answer
15 views

Bytecode: Does it Reveal What Language it Was Programmed In?

Does EVM bytecode have some indication to what high-level language it was programmed in?
0
votes
0answers
14 views

need large amount ropsten testnet ether [closed]

I'v develop dapp about private loan but I don't have enough ether for test this dapp and I don't have GPU to mine by myself (CPU mining is sucks) can any send me ropsten ether to this address ...
0
votes
1answer
11 views

What does MetaMask mean by stop injecting web3.js?

MetaMask announced that they will stop injecting web3.js here. I know previously MetaMask will add a global variable in browser window.web3 and this global lowercase web3 variable will be deprecated ...
0
votes
1answer
12 views

using .call(): contradictory recommendations

Solidity documentation: You should avoid using .call() whenever possible when executing another contract function as it bypasses type checking, function existence check, and argument packing. ...
0
votes
1answer
14 views

Setting a value for ERC20 token on private blockchain?

Background: Currently we have an Dapp running on Ropsten. We've created an ERC20 token on Ropsten. Our employees are awarded these tokens over time. We want to use Dappos to allow our employees to ...
0
votes
0answers
13 views

How unique are the event log ids?

I am using log_ids of events to keep track of which events I've processed. Log ids are formed using the word log followed by 8 hexadecimal characters i.e. log_d758eda8 The possible combinations of ...
0
votes
0answers
15 views

“Nonce too low” using contract.methods.myFunction().send()

Using web3 to build a contract from the ABI: contract = new web3.eth.Contract(JSON.parse(abi), '0x17c91A5a6f5e3E4BEaFC478D18C4A44D88833277', { from: '0x0Ad2b5CCe78D677fD000698a7E4Cde866DE189C6', gas: ...
0
votes
1answer
18 views

Lottery Winning number based on blockhash

After reading a lot of Info about this topic in this forum I am asking whether I can just use the formular winningNumber = uint256(blockhash(block.number-1)) % 100; e.g. 10 or 20 blocks after the ...
0
votes
1answer
17 views

Unable to deploy contract on Private Quorum Network

We just built a new 3 node quorum network but we are unable to deploy any contract on it. Please find the below info: Quorum vesrsion: Geth Version: 1.8.18-stable Git Commit: ...
0
votes
1answer
16 views

What is the use of a interface or function without implementation?

Take, for example, this code. The interface contains function without implementation, so how it's useful. pragma solidity ^0.5.0; interface Calculator { function getResult() external view returns(...
0
votes
0answers
16 views

How to get a list of struct that has a mapping as attribute

I have the struct Offer so that it contains already a mapping of assets. I have created a mapping of offers for the struct Offer storage. Now I need to implement the getAll function of Offer. The ...
0
votes
1answer
11 views

Web3.js eth.subscribe: on('changed', function(event){}) doesn't work with Metamask?

I write a demo DApp website with this javascript const web3 = new Web3(ethereum); const contractAddr = "0x0Aa27e4B13D5c08A8767B36a0ACb76ED4549B7EA"; const abi = ...; let inst = new ...
0
votes
0answers
10 views

An unsolved problem related to the Ethereum presale in 2014

I am writing on this forum because I am trying to solve this issue since years, with no success. I have an unsolved problem related to the Ethereum presale in 2014, due to a technical issue of the ...
0
votes
0answers
13 views

App freezes when using any Web3j sendAsync function

I'm developing an app using Web3j and Java Kotlin in Android Studio. However, I'm not sure why anytime I call a web3j function with sendAsync the app freezes. if(preferences.applicationPreferences....
0
votes
0answers
10 views

How much compression do Merkle Patricia Trees actually provide?

I like the idea of a MPT but extra information has to be stored to build them.. so I'm wondering how much they actually compress the data. Is there actually data/statistics somewhere for how much ...
0
votes
0answers
12 views

Calling decodelog with dynamic number of arguments

the number of input arguments is dynamic, how can I decode many log by one? this is all i tried to do for (let n = 0; n <= receipt.logs.length-1; n++) { if(event.code === receipt.logs[n]....
0
votes
1answer
19 views

how to do sales receipt

I have a marketplace. I wanted to make a sales receipt for each item sold. The sales receipt will indicate address_receipt,nameOfGood, amountOfGood,Price, sumPrice,address_transaction. What should I ...
0
votes
0answers
17 views

Getting “ReferenceError: unescape is not defined” when trying to call() a smart contract method from rasberry pi to a private geth network

> var contract1 = eth.contract(abi).at(address) undefined > contract1 { abi: [{.....] transactionHash: null, addRecord: function(), allEvents: function(), getPatientName: function(), ...
0
votes
0answers
8 views

Geographic distribution of keys in Key Management

I'm making key management for a company and there is a question about Geographic distribution of keys. I understand that the keys should be backed up in different locations, but about the geographic ...
0
votes
1answer
22 views

How can I extract a wallet address from event data?

I have a contract that returns event data including the sender's address: event Result( address indexed _walletAddress, string _name, uint256 _amount ) And in my Node.js app I try to ...
0
votes
0answers
27 views

bZx: exploit or attack?

Ethereum-based lending project bZx has been recently in the news due an expensive bug exploit, see here or here. In many articles this event is referred as an "attack". In fact every step performed ...
0
votes
0answers
16 views

Contract not getting deployed and no failed transaction is shown on rinkeby.etherscan.io

I deployed this same contract a week ago and it deployed successfully. Now when I try to deploy it I get a message in the console telling me 'Attempting to deploy contract from (my account)' but then ...
0
votes
1answer
18 views

Cross Origin Blocked? Setting up Infura provider

useEffect(() => { const loadWeb3 = async () => { const web3 = new Web3( new Web3.providers.HttpProvider("https://mainnet.infura.io/censored") ); let n = await web3....
0
votes
0answers
17 views

DIGIX tokens mapped with physcial gold ids?

If digix tokens are linked to Physical gold, what will happen to this linkage, if user transfers his tokens to other users.
1
vote
1answer
16 views

Information Regarding LASER and Ethereum

I was reading this article https://diligence.consensys.net/files/D1T2%20-%20Bernhard%20Mueller%20-%20Smashing%20Ethereum%20Smart%20Contracts%20for%20Fun%20and%20ACTUAL%20Profit.pdf and came across ...
0
votes
1answer
17 views

What happens when i redeploy my contract on truffle?

I am very confused by the term 'Contracts are immutable' does it mean when I deploy my contracts, I can't update my code again, and what actually happens when I redeploy my smart contracts after and ...
0
votes
1answer
13 views

Only 1 .SOL contract file is compiled in truffle project

I am having a very annoying problem but hopefully very simple to solve! I have a truffle project. In my contracts directory I have 2 files: > 1_Migrations.sol > 2_Factoring.SOL When I ...
0
votes
0answers
16 views

Integration of (closed) cloud solution with Ethereum

I'm trying to invoke a smart contract function from a cloud solution Unfortunately I can only use REST web services and I cannot - install node.js - install any custom module Also, I can only use a ...
0
votes
0answers
10 views

Can I send JSON RPC request to Parity not from intranet? (e.g. from another external IP address)

Can I send JSON-RPC request not from a local network(192.168.xxx) ? so that I can re-use my existing ETH nodes. thanks
0
votes
0answers
13 views

how to calculate Ethereum inflation per each block?

I've run Ethereum node so I can access blockchain info via rpc api provided from the node. What I want to do is calculate Ether inflation per each block. For that, I've read many documents and I want ...
0
votes
1answer
24 views

What is the core difference between send and transfer method of address payable in solidity? [duplicate]

I'm learning solidity I got two methods for transferring ether <address payable>.send(1 ether) <address payable>.transfer(1 ether) Both are used to transferring ether to the recipient ...
-1
votes
0answers
20 views

Store patient health record in solidity [closed]

I am new to solidity, I need to store patient record and details in solidity process.Patients may have multiple data like ambulance booking,doctor appointment of this user, my query is how to achieve ...
2
votes
2answers
32 views

How do Proxy Upgraded Logic Contracts Share Data

I have been looking at how to make my contracts upgradeable and looking through the Zeppelin docs and source code to try to wrap my head around this. One thing I cannot work out is: How do new logic ...
1
vote
1answer
12 views

What is the max number of Blocks which can be created in Quorum

I have nodes running from past few days, with almost 4100+ transactions successfully completed. When i try to interact with the contracts again to add/modify details it shows error Error when ...
0
votes
1answer
22 views

Does new approve call overrides previous approved tokens?

Let's say I asked a user to approve the X Dai amount today for Smart invoice asking price. daiContract.methods.approve(cAddress, X.toString()).send({ from: ethereum.selectedAddress }); But, he ...
2
votes
1answer
45 views
+50

Whats the cheapest/most gas efficient way of converting bytes32 to uint24?

I have an array of bytes32 with various pieces of information at various byte positions in it, and 2nd 3 bytes are a number, which I convert to uint24 like so (where currentData is of type bytes32): ...
0
votes
0answers
14 views

How to create blockchain nodes locally

For educational purposes I am implementing a blockchain from scratch without the use of any frameworks. How would I go about testing my blockchain using multiple nodes when I only have access to one ...
0
votes
2answers
28 views

Order of transactions in the same block

I am writing a Medium blog post about front-running and can't seem to find information about the order of the transactions in the same block. I have executed two trades, one with the lower fee, call ...
0
votes
0answers
11 views

web3.js - Subscribe multiple addresses and new coming address

I build ETH wallet app by using web3.js. My concept is the new ETH address will generate when user is registered on my app and when they send ETH from other address on another app or whatever to the ...
1
vote
0answers
20 views

exponential function with fractional numbers

With solidity, we cannot directly calculate 0.1 or 0.001. We usually use decimal multiplier and divisor integer to calculate those numbers like this 0.01 = 1 / 100 When the number is more than 1, it ...
0
votes
0answers
10 views

Unable to render inside (callback function) using react for web3.eth.subscribe

import React from 'react'; import ReactDOM from 'react-dom'; import Web3 from 'web3'; class App extends React.Component { componentWillMount() { this.loadBlockchainData() } ...
0
votes
1answer
11 views

PoA network confusion resolving using geth

I am planning to move from PoW to PoA consensus (clique) using geth. But I am confused of some of the topics - 1) Empty blocks are created periodically? What is the size of an empty block? 2) Is it ...

15 30 50 per page
1 2 3 4 5 560