Questions tagged [cryptography]

Discipline or techniques employed in protecting integrity or secrecy of electronic messages by converting them into unreadable (cipher text) form.

Filter by
Sorted by
Tagged with
4
votes
2answers
4k views

How Ethereum confirm the transaction?

Am I right, that Ethereum do it the same way as Bitcoin (Bitcoin dev guide), and the only difference is that the Ethereum use it's own OP_CODES? UPD I mean, what is the Ethereum's alternative for &...
5
votes
1answer
468 views

Generate key in Ruby, import in Geth

I'm a Ruby newbie and I need to implement a Geth-compatible key import/export in Ruby. I was looking at the Geth implementation in Go, as well as keythereum. For generating the key, I am using the ...
4
votes
1answer
263 views

Does a greater number of hashing rounds in aes-128-ctr scrypt key generation mean stronger encryption?

Consider the following Ethereum account I created at MyEtherWallet: { version: 3, id: '4447b704-e28c-4e93-8b1d-32f519b46692', address: '115312fc0ab77a0fb15a66baf51f58baefcee1dd', Crypto: { ...
5
votes
1answer
1k views

Ethereum Authentication/Authorization

Lately I've been thinking about how to integrate Ethereum with other non-Ethereum systems. Would it be a bad idea to import and Ethereum keypair into an external (mobile/desktop) application, which ...
4
votes
2answers
382 views

What if a dishonest node execute a different program on EVM?

I want to create a program (on the Ethereum Virtual Machine), that can access some data under certains condition (only if authorized). So the program checks the authorization, and then (eventually) ...
3
votes
2answers
211 views

Confidential value transfers

Is there currently any way to do confidential transactions with Ethereum for a custom token? If not, is there any work/research being done on how this might be possible?
3
votes
1answer
713 views

Unable to verify signature returned by JSON-RPC `eth_sign` method

I am attempting to verify a signature returned by the eth_sign JSON-RPC method. https://github.com/ethereum/wiki/wiki/JSON-RPC#eth_sign The verification is done using the following python code and ...
5
votes
1answer
153 views

How can one use the tokens provided by a crowdfunding platform?

I was reading about Weifund crowdfunding. In it, some custom crypto-tokens are provided to investors in exchange for an invested amount. I just want to know how will that investor use that token so ...
19
votes
3answers
4k views

Account uniqueness guaranteed?

When we create an account in the Ethereum main network, how does the protocol guarantee the unique address of an account? Since even if we are not connected to the network we can create an account, is ...
2
votes
1answer
121 views

Why Ethereum can't talk to other blockchains?

I've heard that Ethereum can't talk to other blockchains (if I understand it correctly). What does it mean and what is the reason behind this?
13
votes
1answer
4k views

arguments of the sha256 function in Solidity

In Solidity, I find that the sha256 function can be used like this a = sha256(uint b, string c, bool d, ......) (the arguments can be a combination of different types, and the other types can also be ...
109
votes
4answers
73k views

How are ethereum addresses generated?

What criteria does a valid ethereum address need to fulfil? Is it just a random number in hexadecimal? Or does it need to be derived in a specific way, according to some cryptographic algorithm? What ...
7
votes
2answers
702 views

Store encrypted private keys on-chain

How secure is it to store encrypted private keys on chain ? Are the assets in the example below easer to brute-force than the master-key that encrypts them ? contract MyPrivateKeys { struct ...
14
votes
1answer
654 views

Does Ethereum Suffer From Transaction Malleability?

Does Ethereum in its current form (Homestead, specifically Geth v1.3.6) have transaction malleability issues similar to Bitcoin? If so, is there a standard method for deriving a normalized hash for ...
7
votes
2answers
565 views

How does the system enforce correct execution of smart contracts?

If I understand correctly, the smart contracts are run by the miners. What incentive do the miners have to execute the smart contracts correctly? What stops a malicious miner from changing the result, ...
27
votes
2answers
9k views

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 ...
11
votes
1answer
6k views

How can I verify a signature with the web3 javascript API?

Using the javascript web3 API I can create a signature like this: > web3.eth.sign(eth.coinbase, "0xdeadbeef") "...
11
votes
2answers
1k views

Secure paper wallet creation for ETH using JS

I am about to start the process of transferring my ETH to paper wallets for safe keeping. Currently the funds are stored on an online exchange. History shows that this is a very bad idea. It is not ...
18
votes
1answer
640 views

Out of Gas invoking precompiled contracts on private blockchains

Why do precompiled contracts lead to Out of Gas on private blockchains? Some tidbits are provided in the Solidity docs but can it be explained more? It might be that you run into Out-of-Gas for ...
4
votes
1answer
366 views

Why doesn't Ethereum do double hashing like Bitcoin?

Why doesn't Ethereum do double hashing like Bitcoin? What are the facts or theories on the security of single Keccak-256 hashing like Ethereum, as compared to Bitcoin's double hashing with SHA2-256? ...
16
votes
2answers
4k views

Is it safe to reuse Ether addresses?

I believe it's viewed as unsafe in Bitcoin because of the way transactions are signed. Is this also true for Ether addresses?
23
votes
1answer
8k views

How can I verify a cryptographic signature that was produced by an Ethereum address key pair

If I have a cryptographic signature from an Ethereum address key pair, how can I verify that signature?
27
votes
5answers
9k views

How can I sign a piece of data with the private key of an Ethereum address?

I would like to use the key pair of one of my Ethereum accounts to sign a piece of data. How can this be done?
20
votes
2answers
6k views

Why aren't Solidity sha3 hashes not matching what other sha3 libraries produce?

Solidity has a function named sha3 and I tested it with an empty string input. It is not matching what other sha3 libraries produce. I see contracts written by others using the same sha3 function ...
9
votes
1answer
432 views

Are there any plans to switch Ethereum's primary hash algorithm from Keccak-256 to SHA3?

The Ethereum project was started before the SHA3 standard was finalised, and currently uses an earlier version of Keccak-256 which does not precisely match the FIPS-202 standard for SHA. Are there ...
87
votes
2answers
49k views

Which cryptographic hash function does Ethereum use?

Many sources refer to the use of the "SHA3" cryptographic hash function within Ethereum, but the Ethereum project began before the SHA3 standard was finalised, and there was some confusion/controversy ...
35
votes
2answers
3k views

What's a precompiled contract and how are they different from native opcodes?

The Yellow Paper states: These are four so-called ‘precompiled’ contracts, meant as a preliminary piece of architecture that may later become native extensions. The four contracts in addresses ...
25
votes
1answer
4k views

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). ...
16
votes
3answers
1k views

What are effective and secure ways of shuffling a deck of cards in a contract?

We want to write a card game in Ethereum. What are effective and secure ways of shuffling a deck of cards in a contract, and dealing them to players? It needs to be done in a way so that no one can ...
25
votes
3answers
3k views

Is Ethereum secure against an attack by quantum computers?

Does Ethereum implement Post-quantum cryptography? Or will the network break once a malicious actor gains control of an effective quantum computer?
20
votes
3answers
5k views

How does Oraclize handle the TLSnotary secret?

Oraclize claims to offer a provably honest secure retrieval of a webpage by taking advantage of TLSnotary (a service that allows an auditor to verify if a specific web page was accurately retrieved) ...