Questions tagged [hash]

This tag should be used for questions related to hashes. A hash is the output of a hash function, a function which .is a mathematically reproducible but irreversible process that takes in an arbitrary length input and produces a fixed length output. The same input will always result in the same output. Hashing is central to Bitcoin mining as well as the generation of Bitcoin addresses.

Filter by
Sorted by
Tagged with
0
votes
1answer
946 views

Bitcoin mining difficulty and hash rate

On blockchain.info there is the charts that shows the mining difficulty over time and the hash rate over time. See: Hash: https://blockchain.info/nl/charts/hash-rate Mining difficulty: https://www....
0
votes
2answers
83 views

How two transactions with the same hash can cause double-spending

Let's consider following situation: Vendor owns address X. Adversary sends transaction T1 to X with hash Y and receives product from vendor. Adversary sends transaction T2 to address which he owns ...
0
votes
3answers
1k views

Why is it impossible to modify a transaction in the blockchain?

Many pages (including Wikipedia) say that it is impossible to modify a transaction which is already in the blockchain included. But why is it so difficult?
0
votes
1answer
137 views

Is pre-image attack useful for mining?

I know that SHA256d is strong enough and it's not likely that will be broken soon but let's say someone knows how to find pre-image. The adversary chooses random hash starting with n zeroes (less than ...
0
votes
1answer
158 views

getrawtransaction asm returns with [ALL], should it be?

.\bitcoin-cli.exe getrawtransaction af66f73a42d33a446e52f1c8e82a99fcd9d788a0ec5c70de6f633 213a7546cdb true "scriptSig": {"asm": "30460221009c8...acc0a2a [ALL] the same transaction on blockchain ...
0
votes
1answer
45 views

Post Pow hash verification

I am unable to understand how a PoW(Proof of work ) activity takes extensive computation but the corresponding hash message verification of the final result is quick and easy. What process and flow ...
0
votes
1answer
54 views

When computing the hash, do you need anything after the number of difficulty bits?

I'm going to screw up a lot of the terminology here. I'm trying to understand the Bitcoin algortihm and wanted to use this JS miner -- https://github.com/howardchung/jsminer . Specifically, I'm ...
0
votes
1answer
51 views

What are the hashes that miners need to do to create a block? [duplicate]

I’m bit stuck in the concept of mining. What are the hashes that need to be created in each block and the chain? Let’s say that we have block A - B - C forming a chain. One source said that we need ...
0
votes
2answers
146 views

How is a transaction formated/signed?

Every transaction takes unspent outputs as inputs and creates new outputs. The creator of the transaction uses his private key to sign the transaction and nodes validate that transaction by using the ...
0
votes
2answers
128 views

Why is this script invalid, and how can I generate valid public key/digital signature pairs?

Why does the default P2PKH transaction at http://bitcoin-script-debugger.visvirial.com/ return NULL rather than true? I haven't tried to swallow the gory details of OP_CHECKSIG yet, but everything ...
2
votes
1answer
459 views

Is the hash of the coinbase transaction needed for the merkle root?

first time posting here. I was interested on how mining software works down to the bytes. I came across this well written article right here: http://www.righto.com/2014/02/bitcoin-mining-hard-way-...
2
votes
2answers
3k views

Generate private key from a bip-39 seed phrase?

I'm able to generate a new private key and associated public addresses using bitcoin-core, but what I really want to do is generate a new private key from a 24 word seed phrase. I'm not sure how to go ...
5
votes
1answer
542 views

How do I generate the Bitcoin Cash hash preimage?

I am attempting to manually generate a signed transaction which is to be sent from my address 1GiJZtN7wjUuL4V5i7ZYYDAvFtqi5AhCDr which is bitcoincash:qzk9nxh6qpd9yt3hvv6vvun78s834f3escdhu2vdjp in the ...
2
votes
1answer
184 views

Probability of block rewards

Assume that there are only three mining pools, all with the same hashing power, mining for bitcoins in the bitcoin network. Which mining pool is most likely to get the block reward? Do you all think ...
-1
votes
1answer
217 views

GPU Mining Speed

I am a bit new to the whole mining thing and just have a economical issue when it comes to selecting GPUs. Sorry if the title is in appropriate. Let's just say in mining Ethereum, a 1070 ti (costs $...
1
vote
2answers
57 views

What roles has the TIME information play in the bitcoin header?

What role does the time play in the bitcoin header? Is it ok to set it to 1 sec after the last block and never change it while calculating? Will the block be rejected when the gap is to large? If 2 ...
0
votes
1answer
57 views

hash locked multisig, can one cosigner sign without the pre-image?

Consider Alice and Bob created the following native segwit script: hash SHA256 defined as H | Alice PubKey | Bob Pubkey Only Bob has the pre-image (plain text that hashes [sha256] to H). Can Alice ...
0
votes
1answer
38 views

Bits target, Increase/Decrease in ease of mine

I am currently studying Block Chain technology and at this moment studying the contents of blocks. To my understanding; A block has to be mined every 10 Minutes. If the Bit Target sees that Blocks ...
0
votes
2answers
285 views

Attacking Blochcain/Bitcoin by hash

Assuming that SHA-256 is not save anymore. How could the Bitcoin blockchain get attacked? Ok I could get the input value for the hash function but could I now easily add my own blocks to the chain? I'...
1
vote
1answer
509 views

How do you verify a block manually?

From my understanding, you simply need to use a SHA256 function to hash the block's header (Block hash and merkle root) then add the nonce at the end like this article explains. However, I can't ...
3
votes
3answers
447 views

Why you need to rehash each block after a changed block when changing data in a blockchain?

Maybe my question is stupid, but, why you need to rehash each block after a changed block when changing data in a blockchain? Each block contains a hash of its data and hash of previous block. If I ...
0
votes
1answer
73 views

Source of entropy for PoW hash

How does bitcoin do it to generate an (upredictable) hash in each new block with sufficient randomness so that no one can precompute it?
0
votes
2answers
221 views

Unclear on double-hashing previous Transaction when creating a new Transaction

I'm having trouble performing the double-sha256 hash of the previous transaction, Step 3 in this explanation. The previous transaction is: ...
0
votes
1answer
556 views

Bitcoin hash calculation [duplicate]

Best regards I have been doing a lot of research about bitcoin and blockchain. A lot of informacion across the Internet can be found where many people explains the basics of bitcoin an it´s ...
1
vote
1answer
102 views

What dead simple algoritm can be used for generating checksums by pen and pencil?

I'm holding a course on Bitcoin and blockchain technology. On my agenda I have an exercise where I'm going to let the attendees create their own blockchain on the wall using post-its. I'm in search ...
0
votes
1answer
500 views

BIP32 HD Wallets: HMAC vs. “just” Hashing the Seed

In A. Antonopoulus' Mastering Bitcoin (2nd edition) on page 106, there is a nice illustration showing how the basis for a BIP32 HD Wallet is generated: So here is the one thing I don't understand ...
0
votes
1answer
102 views

How do you mathematically add and subtract hash power?

My question was how do you mathematically add and subtract hash power. I recently purchased four Antminer D3s.They all run at the average rate of 19-20 MH/s but when I go to my stats in the pool that ...
1
vote
1answer
151 views

Why do we inverse the hash of the blockheader?

Let's pick this example blockheader-hashing in Python: from hashlib import sha256 import hashlib header = "...
1
vote
1answer
884 views

Why the nonce is difficult to find in Bitcoin?

I read many articles explain the Bitcoin POW, but every article seems copy form each other. they just indicate find a nonce start from 1, but I still confused why find a nonce number is so difficult? ...
3
votes
1answer
345 views

Why max target is not (2^256 - 1)?

I'm reading https://en.bitcoin.it/wiki/Difficulty And I don't get why max target is not (2^256 - 1) which is 0xFFFFFFFFFFFF... but 0x00000000FFFF...?
3
votes
2answers
693 views

Checking the Merkle Root for Block #100000

The below text is copied from the Bitcoin Developer Reference at bitcoin.org: If a block has three or more transactions, intermediate merkle tree rows are formed. The TXIDs are placed in order and ...
2
votes
1answer
430 views

Using the Merkle Root to prove the integrity of a block's transactions

I understand that a Merkle Root is the hash of hashes of hashes (etc.) of transaction pairings within a block that ultimately results in one 'Root' hash. Changing anything about any of the original ...
1
vote
2answers
1k views

Two addresses with same hash160?

It seems that two addresses have same hash160 69665e2c4fac771e340f8c6f91c719b0c37a6a8f: here 0 BTC: https://blockchain.info/address/1AcJanbHGrBFwS3KJMDW8kEZMtHiJhatzE here 0.00720407 BTC: https://...
0
votes
2answers
358 views

Understanding the Hash Function

Can someone please explain in detail the components of the final hash that determines the winner of the block? My understanding is that the miners are taking The Merkle Root, The time stamp, The ...
3
votes
1answer
100 views

Understanding what is being run through Sha256

When I am running through an example for Sha256 I am not understanding how to arrive at the right answer. If I use the following Hex string: ...
2
votes
0answers
78 views

Blake-256 genesis block generation helpint

I'm making my own coin and get problem to generate genesis for my fork. Genesis need to be blake-256. I was found this git https://github.com/lhartikk/GenesisH0 and tryed to use this script, i also ...
2
votes
2answers
103 views

Why we must reference the entire txid for each output we want to spend?

Suppose I want to spend from 3 unspent outputs. I must reference the txid of these unspent outputs. Suppose they are: eb36eca9a06fbe68278ad3e7d16d10ed02e22ad891ed59ef2b84ed4a49e8a6d2 ...
0
votes
3answers
300 views

how does solving hashes and building blockchain help the human race?

I guess I am naive about what miner really does to benefit the human race. What kind of problems does miner's computer solve? The hash just looks like a whole string of numbers and letters to me. ...
4
votes
1answer
383 views

Which is the smallest hash that has ever been hashed?

Let's assume, the hash 00000000000000000024c0bdbec66a889778c00bc69be0a96cbbd98b75c3ce09 of block #499644 is smaller than 0000000000000000002d429f39afec70c938e888c3417d690bbc85e83529991c of block #...
0
votes
2answers
67 views

Assumed, I hash the next bitcoin block. Whom do I tell if it's decentralized?

The bitcoin network is decentralized, right? Assumed, I do hash a little bit and get a hash that starts with 20 Zeros.. What do I do than? I need to send the block to someone but who is that? It's ...
2
votes
2answers
900 views

How can I check the hash of a bitcoin block?

Let's pick an example bitcoin block: #499583 This is the block: https://insight.bitpay.com/api/rawblock/000000000000000000677c4077da7c9f01dde5f332ba2fbff962ee699714d5da It starts with ...
3
votes
2answers
491 views

Verifying that a transaction is in the blockchain

Let me first start off by saying im just learning about blockchain and the technical aspects. From my understanding, each transaction is cryptographically hashed, the hashes are paired and hashed ...
1
vote
1answer
83 views

General Bitcoin questions [closed]

At the moment I'm trying to get a look inside Bitcoin and the Blockchain, but I'm having some general unanswered questions. How does a wallet know how much Bitcoins belongs to a specific address? I ...
0
votes
2answers
288 views

Block hashing algorithm

The block header contains a number of things, among them the Merkle root hash. Wouldn't this mean that every time a new transaction is added to the block (before its mined), that all nonces previously ...
0
votes
2answers
61 views

What is #Hash in bitcoin from a layman's perspective?

I am currently reading through the paper on bitcoin and being from a non IT background, I am unable to understand the use/function of hash
0
votes
1answer
85 views

Several clients confirmed transactions with the same hash

We generate a personal bitcoin-address for a payment for each customer. For these purposes, we use the Blockchain.Info API. Today it was discovered that in callback sent by the Blockchain.Info we ...
1
vote
1answer
584 views

Bitcoin - Is the <pubKeyHash> in scriptPubKey already hashed?

In Bitcoin protocol, to set the output of a transaction you need a scriptPubKey which is in the following format. scriptPubKey = OP_DUP OP_HASH160 <pubKeyHash> OP_EQUALVERIFY OP_CHECKSIG Is &...
2
votes
1answer
286 views

What causes quadratic hash problem?

I read ScriptSig content during signature (quadratic hashing) discussing quadratic hash problem. Quadratic hash problem is the issue that signing (or verifying) transaction time grows with the square ...
0
votes
1answer
793 views

BTC Hash-Rate API

I'd like to get hash-rate of BTC from OKcoin' API(GET /api/v1/charts/:type) here is OKCoin's API web site. How can I get information from here is OKCoin's API web site. python gets = requests.get("...
1
vote
1answer
201 views

Who decides what the next, correct Nonce is?

As I understand finding the correct Nonce is the basis when hashing transactions for Proof of Work. How and where is this decided in the ecosystem what the next Nonce is? In my limited understanding ...