Most Popular

1500 questions
38
votes
2 answers

How to encrypt a message with the public-key of an Ethereum address

I am writing some code in nodejs/browser. I have successfully created ethereum-addresses with the secp256k1-library. I was also able to sign and verify messages. Now I want to encrypt/decrypt a message with the public and private-key of the…
pubkey
  • 1,157
  • 1
  • 10
  • 15
38
votes
5 answers

Exploring and Analyzing the Ethereum blockchain

I would like to explore the data inside of the Ethereum blockchain. All transactions and contracts of the Ethereum Blockchain are stored there. So it's an interesting open dataset and I'd like to get some insights out of it. But I am not entirely…
wacax
  • 1,388
  • 2
  • 13
  • 29
38
votes
4 answers

What is the ethereum transaction data structure?

I'd like to know the detail of the Ethereum transaction data structure. What data is stored in transaction?
Satoshi Nakanishi
  • 5,749
  • 7
  • 38
  • 57
38
votes
6 answers

How long is the first sync supposed to last?

I've been running Geth (latest version) for around 12 hours and it's still not finished. The command prompt shows this : INFO [05-21|12:05:00] Imported new chain segment blocks=1 txs=9 mgas=0.748 elapsed=40.047ms mgasps=18.687…
J. Doe
  • 383
  • 1
  • 3
  • 5
38
votes
3 answers

How can I view event logs for an ethereum contract?

After reading the this post, it seems like I should be able to access the logs of events that have been called on an Ethereum contract. The section I am interested in is Option 3 which is using event logs as a cheaper form of storage. This Stack…
user1911077
  • 481
  • 1
  • 4
  • 4
38
votes
6 answers

How can a DApp detect a fork or chain reorganization using web3.js or additional libraries?

Take an example of a voting DApp. A user clicks on a vote button, then behind the scenes a transaction gets mined on the blockchain, and finally the DApp tells the user their vote has been recorded. Now for some reason, there is a chain…
eth
  • 85,679
  • 53
  • 285
  • 406
38
votes
4 answers

What is Olympic, Frontier, Morden, Homestead and Ropsten Ethereum blockchain?

I am studying Ethereum and have not been able to figure out the difference between Homestead and Morden. In some docs, it is written that Homestead uses a new algorithm which takes less time. I don't understand this. Is Morden for testing and…
Himanshu sharma
  • 782
  • 7
  • 19
37
votes
4 answers

operator == not compatible with type string storage ref and literal_string

Can someone help out with the stated error, I am trying to run code to check the status of a String variable. While compiling using the online solidity compiler I am getting two errors on customcheck and portcheck. See the code below: contract…
srbamb
  • 463
  • 1
  • 4
  • 5
37
votes
1 answer

When can BLOCKHASH be safely used for a random number? When would it be unsafe?

I've seen more complicated ways for a contract to generate a random number. But the Ethereum Yellow Paper itself suggests a "trivial solution" using the BLOCKHASH opcode (see below, bold is mine). If a contract just needs a couple of random numbers…
eth
  • 85,679
  • 53
  • 285
  • 406
37
votes
4 answers

What is a chainID in Ethereum, how is it different than NetworkID, and how is it used?

Here it's described in Ethereum's go implementation. type ChainConfig struct { ChainId *big.Int `json:"chainId"` // Chain id identifies the current chain and is used for replay protection A few questions: How is it different than networkID? Is…
AlwaysQuestioning
  • 571
  • 1
  • 6
  • 15
37
votes
1 answer

How does Ethereum make use of bloom filters?

As stated in the yellow paper: Transaction Receipt. In order to encode information about a transaction concerning which it may be useful to form a zero-knowledge proof, or index and search, we encode a receipt of each transaction containing…
Henrique Barcelos
  • 2,481
  • 4
  • 20
  • 38
37
votes
4 answers

Store data in mapping vs. array

I see there're some Solidity examples that are using mapping for storing state, and some are using arrays. For example this example is using mapping: struct Campaign { .... } uint numCampaigns; mapping (uint => Campaign) campaigns; and there is…
Igor Artamonov
  • 679
  • 1
  • 6
  • 10
37
votes
1 answer

What's the difference between Accounts and Wallets in Mist?

In Mist, there are some addresses listed as accounts, and some listed as wallets. What's the difference? Which should I use? And why do I need Ether to create a Wallet?
Tjaden Hess
  • 37,046
  • 10
  • 91
  • 118
37
votes
3 answers

Ethereum Merkle Tree Explanation

Here is my basic understanding about how Ethereum stores transactions A hash is generated for each transaction Then pairs are selected and a hash is generated for each pair This way the last remaining hash becomes the root Block header contains…
Susmit
  • 1,804
  • 2
  • 14
  • 29
37
votes
4 answers

How to mine Ether on GNU + Linux?

How do we start mining Ether on a Debian / Ubuntu / GNU+Linux based computer? Are there PPAs or special repositories?
user75798
  • 943
  • 2
  • 11
  • 14