Bitcoin Forum
December 11, 2016, 12:01:00 PM *
News: Latest stable version of Bitcoin Core: 0.13.1  [Torrent].
 
   Home   Help Search Donate Login Register  
Pages: [1]
  Print  
Author Topic: looking for technical info  (Read 552 times)
CanaryInTheMine
Donator
Legendary
*
Offline Offline

Activity: 1526


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.

| In Default we Trust | Need gold/silver for btc? | Buy bitcoins |
Advertised sites are not endorsed by the Bitcoin Forum. They may be unsafe, untrustworthy, or illegal in your jurisdiction. Advertise here.
1481457660
Hero Member
*
Offline Offline

Posts: 1481457660

View Profile Personal Message (Offline)

Ignore
1481457660
Reply with quote  #2

1481457660
Report to moderator
1481457660
Hero Member
*
Offline Offline

Posts: 1481457660

View Profile Personal Message (Offline)

Ignore
1481457660
Reply with quote  #2

1481457660
Report to moderator
1481457660
Hero Member
*
Offline Offline

Posts: 1481457660

View Profile Personal Message (Offline)

Ignore
1481457660
Reply with quote  #2

1481457660
Report to moderator
jackjack
Hero Member
*****
Offline Offline

Activity: 882


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
Donator
Legendary
*
Offline Offline

Activity: 1526


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

| In Default we Trust | Need gold/silver for btc? | Buy bitcoins |
etotheipi
Legendary
*
expert
Offline Offline

Activity: 1428


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
Jr. Member
*
Offline Offline

Activity: 59



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

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


1APeJ2DiUNdsNizn47MBeAwbjaugEgg4Zn
Pages: [1]
  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!