Bitcoin Forum
May 09, 2024, 03:19:41 PM *
News: Latest Bitcoin Core release: 27.0 [Torrent]
 
   Home   Help Search Login Register More  
Pages: [1]
  Print  
Author Topic: looking for technical info  (Read 739 times)
CanaryInTheMine (OP)
Donator
Legendary
*
Offline Offline

Activity: 2352
Merit: 1060


between a rock and a block!


View Profile
August 25, 2011, 11:09:54 PM
 #1

could someone point me to where I can see code /pseudo/code for the calculation of a hash.  step by step would be awesome, but anything would be helpful too.
1715267981
Hero Member
*
Offline Offline

Posts: 1715267981

View Profile Personal Message (Offline)

Ignore
1715267981
Reply with quote  #2

1715267981
Report to moderator
1715267981
Hero Member
*
Offline Offline

Posts: 1715267981

View Profile Personal Message (Offline)

Ignore
1715267981
Reply with quote  #2

1715267981
Report to moderator
Every time a block is mined, a certain amount of BTC (called the subsidy) is created out of thin air and given to the miner. The subsidy halves every four years and will reach 0 in about 130 years.
Advertised sites are not endorsed by the Bitcoin Forum. They may be unsafe, untrustworthy, or illegal in your jurisdiction.
1715267981
Hero Member
*
Offline Offline

Posts: 1715267981

View Profile Personal Message (Offline)

Ignore
1715267981
Reply with quote  #2

1715267981
Report to moderator
1715267981
Hero Member
*
Offline Offline

Posts: 1715267981

View Profile Personal Message (Offline)

Ignore
1715267981
Reply with quote  #2

1715267981
Report to moderator
1715267981
Hero Member
*
Offline Offline

Posts: 1715267981

View Profile Personal Message (Offline)

Ignore
1715267981
Reply with quote  #2

1715267981
Report to moderator
jackjack
Legendary
*
Offline Offline

Activity: 1176
Merit: 1233


May Bitcoin be touched by his Noodly Appendage


View Profile
August 25, 2011, 11:48:54 PM
 #2

could someone point me to where I can see code /pseudo/code for the calculation of a hash.  step by step would be awesome, but anything would be helpful too.
A hash of what?
Block, transaction, address?

Own address: 19QkqAza7BHFTuoz9N8UQkryP4E9jHo4N3 - Pywallet support: 1AQDfx22pKGgXnUZFL1e4UKos3QqvRzNh5 - Bitcointalk++ script support: 1Pxeccscj1ygseTdSV1qUqQCanp2B2NMM2
Pywallet: instructions. Encrypted wallet support, export/import keys/addresses, backup wallets, export/import CSV data from/into wallet, merge wallets, delete/import addresses and transactions, recover altcoins sent to bitcoin addresses, sign/verify messages and files with Bitcoin addresses, recover deleted wallets, etc.
CanaryInTheMine (OP)
Donator
Legendary
*
Offline Offline

Activity: 2352
Merit: 1060


between a rock and a block!


View Profile
August 25, 2011, 11:51:40 PM
 #3

could someone point me to where I can see code /pseudo/code for the calculation of a hash.  step by step would be awesome, but anything would be helpful too.
A hash of what?
Block, transaction?

block
etotheipi
Legendary
*
expert
Offline Offline

Activity: 1428
Merit: 1093


Core Armory Developer


View Profile WWW
August 26, 2011, 04:12:34 AM
 #4

Are you talking about SHA256?  The wiki is always a good place to start for that:  http://en.wikipedia.org/wiki/SHA-2

If you're talking about something more specific to BTC, there are three places that hashes are used that I can think of, off the top of my head:

(1) 80-byte block headers  {sha256(sha256((...)}
(2) Full transactions       {sha256(sha256(...))}
(3) Converting public keys to BTC addresses  {ripemd160(sha256(...))}
 

You can see illustrations of a full Transaction (2) and the conversion from ECDSA public key to BTC address (3) in my post: 
https://bitcointalk.org/index.php?topic=29416.0


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!)
WakiMiko
Newbie
*
Offline Offline

Activity: 59
Merit: 0



View Profile
August 26, 2011, 01:01:33 PM
 #5

blockhashing example in C: https://gist.github.com/1173353

Pages: [1]
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.19 | SMF © 2006-2009, Simple Machines Valid XHTML 1.0! Valid CSS!