Bitcoin Forum
December 03, 2016, 06:52:29 AM *
News: To be able to use the next phase of the beta forum software, please ensure that your email address is correct/functional.
 
   Home   Help Search Donate Login Register  
Pages: « 1 [2]  All
  Print  
Author Topic: Seemingly Inefficient Hashing Question???  (Read 2085 times)
Etlase2
Hero Member
*****
Offline Offline

Activity: 798


View Profile
May 24, 2012, 02:09:10 AM
 #21

SHA-256's way of hashing arbitrarily-sized data allows for trivial "extension attacks". Given only the hash of "password; command", an attacker can trivially produce the hash of "password; command; attacker'sArbitraryData" (ie. he can append any data he wants without knowing what he's appending to).

Isn't this the likely reasoning behind using a hash of the hash?

1480747949
Hero Member
*
Offline Offline

Posts: 1480747949

View Profile Personal Message (Offline)

Ignore
1480747949
Reply with quote  #2

1480747949
Report to moderator
1480747949
Hero Member
*
Offline Offline

Posts: 1480747949

View Profile Personal Message (Offline)

Ignore
1480747949
Reply with quote  #2

1480747949
Report to moderator
Advertised sites are not endorsed by the Bitcoin Forum. They may be unsafe, untrustworthy, or illegal in your jurisdiction. Advertise here.
theymos
Administrator
Legendary
*
expert
Offline Offline

Activity: 2492


View Profile
May 24, 2012, 02:20:17 AM
 #22

Isn't this the likely reasoning behind using a hash of the hash?

I doubt it. Bitcoin doesn't hash anything secret.

1NXYoJ5xU91Jp83XfVMHwwTUyZFK64BoAD
Hawkix
Hero Member
*****
Offline Offline

Activity: 517



View Profile WWW
May 25, 2012, 02:22:10 PM
 #23


....

Code:
Current Target: 00000000000009AE020000000000000000000000000000000000000000000000
Block Hash:     00000000000000001e8d6829a8a21adc5d38d0a473b144b6765798e61f98bd1d

This block hash is smaller than the target so it "solves" the block (if and only if all the inputs are still valid - which they aren't).  
Actually this block hash is really small.  It would be below the target even if difficulty was in the hundred million range.

Umm, that's quite interesting for me, how the hell you did get that hash?Huh

Donations: 1Hawkix7GHym6SM98ii5vSHHShA3FUgpV6
http://btcportal.net/ - All about Bitcoin - coming soon!
DeathAndTaxes
Donator
Legendary
*
Offline Offline

Activity: 1218


Gerald Davis


View Profile
May 25, 2012, 02:47:05 PM
 #24


....

Code:
Current Target: 00000000000009AE020000000000000000000000000000000000000000000000
Block Hash:     00000000000000001e8d6829a8a21adc5d38d0a473b144b6765798e61f98bd1d

This block hash is smaller than the target so it "solves" the block (if and only if all the inputs are still valid - which they aren't).  
Actually this block hash is really small.  It would be below the target even if difficulty was in the hundred million range.

Umm, that's quite interesting for me, how the hell you did get that hash?Huh

Random luck.  Many block hashes are significantly smaller than their target.  The requirement is that they simply be equal to or smaller than the current target. 

Hash values are going to be randomly distributed between

0000000000000000000000000000000000000000000000000000000000000000

and

ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff



etotheipi
Legendary
*
expert
Offline Offline

Activity: 1428


Core Armory Developer


View Profile WWW
May 25, 2012, 09:13:13 PM
 #25

By the way, just for reference the block in the main chain with the lowest difficulty is:

Quote
Block with the lowest difficulty:
   Block Num:        125552
   Block Hash:       00000000000000001e8d6829a8a21adc5d38d0a473b144b6765798e61f98bd1d
   Equiv Difficulty: 35,987,768,035
   Equiv Diff bits:  67.07

That block would've been valid even if the network difficulty was 35,900,000,000  (yes, billion), even though the actual difficulty was 244,000.   

That may seem ludicrous, but it's actually on par with the approximately 2^68 hashes that the network has done up until now.  The last part of it (the 67.07) says that if you were to do 2^67.07 hashes, you'd have a 50% chance of finding a hash just as good...


Founder and CEO of Armory Technologies, Inc.
Armory Bitcoin Wallet: Bringing cold storage to the average user!
Only use Armory software signed by the Armory Offline Signing Key (0x98832223)

Please donate to the Armory project by clicking here!    (or donate directly via 1QBDLYTDFHHZAABYSKGKPWKLSXZWCCJQBX -- yes, it's a real address!)
Sergio_Demian_Lerner
Hero Member
*****
expert
Offline Offline

Activity: 534


View Profile WWW
May 28, 2012, 01:40:24 PM
 #26

There is a use for storing previous hashes and that use is attacking the hash function using the birthday paradox. http://en.wikipedia.org/wiki/Birthday_problem

Nevertheless, the attack is not feasible today for SHA256.


Pages: « 1 [2]  All
  Print  
 
Jump to:  

Sponsored by , a Bitcoin-accepting VPN.
Powered by MySQL Powered by PHP Powered by SMF 1.1.19 | SMF © 2006-2009, Simple Machines Valid XHTML 1.0! Valid CSS!